- Save X11ForwardContext to Channel.x11_forward_context
- Clone context for later use in data forwarding
- Prepare for actual X11 data forwarding in handle_channel_data
All 182 tests pass.
- Add x11_forward_context field to Channel struct
- Initialize x11_forward_context: None in all Channel creations
- Prepare for actual X11 data forwarding
All 182 tests pass.
- x11_forward.rs module with X11ForwardContext
- parse_display() to parse DISPLAY env variable
- read_xauthority_cookie() to read MIT-MAGIC-COOKIE-1
- X11Connection for socket forwarding
- Unit tests: parse_display/disabled/display_env
All tests pass.
- compression.rs module with CompressionContext
- Compress/Decompress using flate2 (raw deflate, no zlib header)
- enable/disable/is_enabled methods
- compress/decompress with Sync flush
- Unit tests: disabled/enabled/roundtrip/supported
All tests pass.
- Trigger oplock break before read if conflicting opens exist
- Use granted_access from Open struct
- Send notifications via notification_tx channel
- Fix WRITE handler granted_access source (from Tree)
All 229 tests pass.
Phase 3: NotificationQueue
- Add notification_tx to Connection struct
- Modify writer.rs to use tokio::select! for response + notification
- Add write_to_bytes() to OplockBreakNotification
- Support server→client async messages
Phase 5: WRITE Handler oplock break
- Get path/share_access before write
- Trigger OplockManager.break_oplock()
- Send OPLOCK_BREAK_NOTIFICATION to affected clients
- Encode and send via notification channel
All 229 tests pass.
- Add LockManager to oplock.rs:
- LockRange struct for tracking byte-range locks
- acquire() - check conflicts before granting lock
- release() - remove specific lock by offset/length
- clear() - clear all locks when file closed
- ranges_overlap() - helper for conflict detection
- Add LockManager to ServerState
- Update handlers/lock.rs:
- Parse LockRequest and LockElement
- Process each lock element (acquire/release)
- Support FLAG_EXCLUSIVE_LOCK, FLAG_SHARED_LOCK, FLAG_UNLOCK
- Return STATUS_LOCK_NOT_GRANTED on conflict
- Update handlers/close.rs:
- Clear all locks when file closed
- Add STATUS_LOCK_NOT_GRANTED to ntstatus.rs
All 229 tests pass.
Phase 4: CREATE Handler dynamic oplock granting
- Use OplockManager.can_grant() to determine oplock level
- Register OplockEntry if oplock granted
- Support ShareAccess compatibility checking
- Grant Level II if exclusive/batch oplock exists
Phase 6: CLOSE Handler oplock cleanup
- Unregister from OplockManager when file closed
- Only unregister if oplock_level > 0
All 229 tests pass.
- Add banner and banner_file fields to SshSecurityConfig
- Enterprise default: 'MarkBaseSSH - Secure File Transfer Server'
- Support banner_file for reading from /etc/motd
- Send SSH_MSG_USERAUTH_BANNER before USERAUTH_SUCCESS
- Pass security_config to perform_ssh_auth function
All 229 tests pass.
- Add keep_alive_interval and keep_alive_max_count to SshSecurityConfig
- Enterprise default: 15s interval, 3 max failures
- Development default: 30s interval, 5 max failures
- Track last_activity timestamp in service loop
- Send keepalive@openssh.com channel request when idle
- Disconnect after max keepalive failures
- Add build_keepalive_request() and get_first_session_channel()
- Prevents connection timeout on idle SSH sessions
All 229 tests pass.
- Add auth_agent_socket field to Channel struct
- Add handle_auth_agent_request() for auth-agent-req@openssh.com
- Check SSH_AUTH_SOCK environment variable for agent socket
- Respond with SSH_MSG_CHANNEL_SUCCESS if agent available
- Foundation for SSH agent forwarding through jump hosts
All 229 tests pass.
- Add VfsRaidLevel enum:
- Single (no RAID)
- RaidZ1 (single parity, similar to RAID 5)
- RaidZ2 (double parity, similar to RAID 6)
- RaidZ3 (triple parity)
- Add VfsRaidBackend with:
- Stripe-based data distribution across disks
- Galois Field arithmetic for parity (P/Q/R)
- gf_exp, gf_mul for Reed-Solomon coding
- rebuild_disk() for disk recovery
- Add VfsRaidConfig:
- level (RAID level)
- stripe_size (default 64KB)
- disk_paths (storage devices)
- All VfsBackend methods propagate to all disks
- Foundation for ZFS-style software RAID
All 229 tests pass.
- Add file_id and read_chunk_size fields to SmbVfsFile
- Use Tree::open_file() to get file_id for reads
- Issue READ requests on each read() call (64KB chunks)
- Close file handle in Drop
Benefits:
- No memory overhead for large files
- Read-ahead caching possible
- Compatible with SMB2 protocol
All 229 tests pass.
- Add cipher_key_len() helper function
- Store encryption_ctos/stoc in KexExchangeHandler
- Use algorithm name to determine key_len (aes256 → 32, aes128 → 16)
- Remove hardcoded cipher_key_len=32 TODO
All 229 tests pass.
Usage:
smb-start --s3 --s3-endpoint https://s3.example.com --s3-bucket mybucket --s3-access-key AKIA... --s3-secret-key secret...
All SMB operations now work over S3-compatible storage.
All 229 tests pass.
- Add --user CLI argument (repeatable) format: name:password
- Default user 'demo:demo123' if no users specified
- All users get ReadWrite access to the share
- Note: SMB3 encryption not available (smb-server v1 out of scope)
Example:
smb-start --user alice:pass1 --user bob:pass2 --share-name myshare
All 229 tests pass.