Commit Graph

25 Commits

Author SHA1 Message Date
Warren
f7cfff27c0 Update AGENTS.md: SFTP authentication DataProvider integration
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
2026-06-19 01:16:05 +08:00
Warren
22fcc83535 Update AGENTS.md: S3 VFS + test fixes documentation
Some checks failed
Test / build (push) Has been cancelled
Test / test (push) Has been cancelled
2026-06-19 00:50:39 +08:00
Warren
960ee87ce9 Add S3 VFS backend: VfsBackend impl for S3-compatible storage
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
- S3Vfs with all 15 VfsBackend methods via rusty-s3 + ureq
- S3VfsFile for buffered writes + ranged reads
- AWS Signature V4 pre-signed URLs (rusty-s3)
- ListObjectsV2 for directory listing (prefix + delimiter)
- Path-style URL mapping (/path to bucket/key)
2026-06-18 23:44:52 +08:00
Warren
69efcdf5c5 Update AGENTS.md with public key auth summary
Some checks failed
Test / build (push) Has been cancelled
Test / test (push) Has been cancelled
2026-06-18 23:35:53 +08:00
Warren
f90e4f496c VFS/DataProvider/Config refactoring + SSH public key authentication
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
Phase 1-6 of refactoring plan:
- VFS abstraction (VfsBackend trait + LocalFs + OpenFlags builder)
- DataProvider trait (SqliteProvider + PgProvider, SFTPGo-compatible)
- Config refactoring (AppConfig unified sections, env overrides)
- SSH handlers (sftp/scp/rsync) migrated to VFS + DataProvider
- SSH public key authentication (Ed25519 signature verification)
- SSH stderr → CHANNEL_EXTENDED_DATA support
- Web auth uses DataProvider instead of direct SQL
- User home directory from provider (per-user isolation)
- PostgreSQL auth provider for SFTPGo compatibility
2026-06-18 23:35:18 +08:00
Warren
5344a7c16e Fix rsync: Use real rsync subprocess instead of in-process handler
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
In-process RsyncHandler couldn't match openrsync protocol 29 flow
after version exchange. Changed handle_rsync_exec() to use
handle_interactive_exec() (spawning real rsync --server subprocess),
same approach as SCP handler.

All file sizes (5MB, 20MB, 50MB, 100MB) successfully transferred with
MD5 verification passing. Transfer speed ~712 KB/s limited by
AES-256-CTR encryption overhead.
2026-06-18 06:01:16 +08:00
Warren
60586c9fad Add comprehensive documentation and test records for Phase 15
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
- Update AGENTS.md with Phase 15 complete summary (version 1.11)
- Add SSH_PHASE15_WINDOW_CONTROL_COMPLETE.md: detailed implementation report
- Add data/rsync_test.txt: rsync 100MB transfer test records
- Add data/scp_test.txt: SCP legacy protocol test records
- Document: Window Control fix, sshbuf zero-copy, SCP support
- Verify: All tests passed, OpenSSH compatible, security validated
2026-06-17 14:07:26 +08:00
Warren
0aeafb0396 Update AGENTS.md: SSH Phase 7 SFTP protocol completed
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
2026-06-15 13:17:47 +08:00
Warren
723482f59a Update AGENTS.md: Document SSH Phase 6 completion (v1.9)
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
2026-06-15 10:37:47 +08:00
Warren
2187e78398 Update AGENTS.md: Document SSH Phase 5 completion (v1.8)
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
2026-06-15 09:18:35 +08:00
Warren
b19f85fd3d Update AGENTS.md: Document SSH strict KEX extension fix (v1.7)
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
2026-06-15 04:13:55 +08:00
Warren
81ae052f48 Revert X25519 byte reversal: OpenSSH doesn't reverse bytes
Key findings:
1. RFC 8731 says 'reinterpret as big-endian' = logical interpretation
2. OpenSSH sshbuf_put_bignum2_bytes() uses little-endian bytes directly
3. With reversal: signature verification fails
4. Without reversal: signature accepted, MAC still fails

Conclusion: OpenSSH treats little-endian X25519 output as big-endian mpint directly (no physical byte reversal).

Remaining issue: MAC verification fails despite signature success.
Next: need to compare client vs server key derivation details.
2026-06-14 20:16:46 +08:00
Warren
666391ef86 Update AGENTS.md: document SSH packet capture analysis
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
Add comprehensive packet analysis results:
- Successful packet capture (4.6KB pcap)
- All key derivation values logged
- Packet analysis methods documented
- Next steps: compare with OpenSSH server

Progress: 85% complete (from 80%)
Security: Still 
2026-06-14 16:12:25 +08:00
Warren
fcde6c82ca Update AGENTS.md: document SSH AES-128-CTR encryption fixes
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
Add detailed record of SSH encryption debugging session:
- Major fixes implemented (persistent cipher, MtE mode, MAC key length)
- Remaining issue: 'Corrupted MAC on input' needs packet analysis
- Progress: 80% complete
- Security: Still using RustCrypto libraries ()

Next steps: Wireshark packet capture analysis
2026-06-14 15:07:21 +08:00
Warren
1300a4e223 MarkBase架构升级:Multi-Volume Virtual Tree + Dual-View Management + Git Remote修正
Some checks failed
Test / test (push) Has been cancelled
Test / build (push) Has been cancelled
核心功能:
-  Categories/Series双视图管理(category_view.rs + import_markdown.rs)
-  FUSE Multi-Volume支持(tree_type参数)
-  SSH/SFTP/SCP/rsync协议完整实现(4042行)
-  NFS/SMB Module Phase 1-3完成
-  Archive Module Phase 1-4完成(2916行)
-  Download Center API完整实现
-  S3兼容API实现(560行)

Git配置修正:
-  删除错误origin(gitea.momentry.ddns.net)
-  删除m5max128(指向机器名)
-  设置origin = m5max128gitea.momentry.ddns.net/admin/markbase
-  设置m4minigitea = m4minigitea.momentry.ddns.net/warren/markbase

数据清理:
-  删除38个临时SQLite(保留accusys.sqlite、demo.sqlite)
-  删除.bak、test_*.bin、调试脚本等临时文件
-  删除临时目录(build/、download files/、raid_test/等)
-  更新.gitignore排除临时文件

架构优化:
- 52个文件修改,2434行新增,4739行删除
- Workspace成员整合(16个crate)
- 数据库状态:accusys.sqlite保留(主demo测试)

远程同步:
-  准备推送到m5max128gitea(远程Gitea)
-  准备推送到m4minigitea(本地Gitea)
2026-06-12 12:59:54 +08:00
Warren Lo
14863d323e Session修改:Mutex死锁修复+AGENTS更新 2026-05-18 17:02:30 +08:00
Warren
6b11e8fa41 docs: Add File Scan System documentation
Added complete documentation for scan/hash commands:
- CLI commands usage
- Performance test results (11857 files in 0.89s import)
- Design decisions (UUID strategy, path storage)
- Async hash system architecture
- Database structure examples
- Usage workflows

Performance highlights:
- Fast import: 14243 nodes/sec
- Async hash: 28 files/sec (4 threads)
- Total: 12658 nodes (warren user)

Version: 1.7 (File Scan System)
2026-05-17 03:21:25 +08:00
Warren
e3901b55d3 feat: Add UI Settings panel with config management
- Add 3 API endpoints: GET /api/v2/config, POST /api/v2/config/edit, GET /api/v2/config/validate
- Add Settings button (⚙️) to bottom bar
- Add Settings panel with CSS styling (8 classes)
- Add JavaScript functions: toggleSettings, loadSettings, editSetting, saveSetting, validateSettings, cancelEdit, toast
- Support viewing/editing/validating all config sections (server, postgresql, authentication, test, logging)
- Update AGENTS.md with UI Settings documentation

Features:
- Real-time config editing via UI
- Input validation before save
- Toast notifications for user feedback
- Responsive design matching existing UI style

Files changed:
- src/server.rs: +70 lines (API handlers)
- src/page.html: +110 lines (UI + JS)
- AGENTS.md: +40 lines (documentation)

Tested: All API endpoints verified, UI elements present in HTML
2026-05-16 20:30:39 +08:00
Warren
af0676c8dd docs: add authentication system documentation 2026-05-16 17:55:25 +08:00
Warren
e3b699cda7 docs: add deployment test experience summary (methodology focused) 2026-05-16 17:01:57 +08:00
Warren
07c6bbf704 docs: update AGENTS.md with CI fix success (Run ID 7) 2026-05-16 16:48:16 +08:00
Warren
87a3eea2c6 docs: add CI log retrieval methods and failure diagnosis to AGENTS.md 2026-05-16 16:40:52 +08:00
Warren
24f3ddc34e docs: update AGENTS.md with deployment status and CI issues 2026-05-16 16:16:07 +08:00
Warren
7757827ece chore: update workflow labels and add access token documentation 2026-05-16 15:57:59 +08:00
Warren
e3d6b60825 feat: MarkBase initial version
Phase 1 (Infrastructure):
- Docs: README.md, AGENTS.md, CHANGELOG.md
- Tests: 26 tests (modes_test, filetree_api_test)
- Examples: examples/sample.md, sample.json
- CI/CD: .gitea/workflows/test.yml, release.yml
- Runner: configuration scripts and guides

Phase 2 (Quality):
- Code quality: rustfmt/clippy config
- Security: environment variables
- Test coverage: 62 tests (+36)
- Documentation: CONTRIBUTING.md, docs/api.yaml
- Showcase: demo_features.md, developer_quickstart.md

Test coverage: 75%
Test pass rate: 100%
2026-05-16 15:37:37 +08:00