unftp-sbe-iso

Crates.iounftp-sbe-iso
lib.rsunftp-sbe-iso
version0.1.2
created_at2025-04-20 21:04:49.665821+00
updated_at2025-05-02 19:48:35.326499+00
descriptionISO file storage backend for libunftp
homepagehttps://github.com/hannesdejager/unftp-sbe-iso
repositoryhttps://github.com/hannesdejager/unftp-sbe-iso
max_upload_size
id1642012
size570,801
Hannes de Jager (hannesdejager)

documentation

README

unftp-sbe-iso

Crate Version API Docs Crate License Follow on Telegram

A libunftp back-end that exposes the contents of ISO 9660 files — such as CD-ROM and DVD images — over FTP or FTPS.

This crate allows FTP clients to connect and browse ISO images as if they were regular FTP file systems. Files can be downloaded, but modification operations (upload, delete, rename, etc.) are intentionally disabled for read-only access.

The ISO files supported conform to the ISO 9660 standard, including common extensions such as Joliet (for Unicode file names) and Rock Ridge (for POSIX-like metadata), where supported by the underlying cdfs crate.

📚 See the documentation for usage and examples.

Features

  • 📀 Read-only FTP access to ISO files
  • ✅ Supports ISO 9660 format — the industry-standard file system for CD-ROM media
  • 🔤 Optional support for Joliet extensions (Windows-style Unicode filenames)
  • 🐧 Optional support for Rock Ridge extensions (UNIX-style metadata and longer filenames)
  • 🔐 Works over both FTP and FTPS via libunftp

🔒 Note: This backend is read-only by design. Operations such as upload, delete, or rename are not permitted.

Usage

Add the libunftp, unftp-sbe-iso and tokio crates to your project's dependencies in Cargo.toml:

[dependencies]
libunftp = "0.21.0"
unftp-sbe-iso = "0.1"
tokio = { version = "1", features = ["full"] }

Then, configure it in your libunftp server:

use libunftp::ServerBuilder;
use unftp_sbe_iso::Storage;

#[tokio::main(flavor = "current_thread")]
async fn main() {
    let addr = "127.0.0.1:2121";

    let server = ServerBuilder::new(Box::new(move || Storage::new("/path/to/your/image.iso")))
        .greeting("Welcome to my ISO over FTP")
        .passive_ports(50000..=65535)
        .build()
        .unwrap();

    println!("Starting FTP server on {}", addr);
    server.listen(addr).await.unwrap();
}

License

Licensed under the Apache License, Version 2.0.

Commit count: 4

cargo fmt