mirror of
https://github.com/m1ngsama/TNT.git
synced 2026-02-08 00:54:03 +00:00
Replace deprecated message-based authentication and channel APIs with modern callback-based server implementation (libssh 0.9+). Changes: - Replace ssh_message_auth_password with auth_password_function callback - Replace ssh_message_channel_request_pty_* with channel_pty_request_function - Remove #pragma GCC diagnostic ignored "-Wdeprecated-declarations" - Implement session_context_t to pass state between callbacks - Fix event loop to wait for auth, channel open, AND channel ready (PTY/shell/exec) Key improvements: - Eliminates message loop complexity (libssh handles state machine) - Proper handling of SSH exec requests (e.g., "ssh host exit") - More maintainable and future-proof code Testing: - All tests passing (17/17) - Basic functionality: 3/3 - Anonymous access: 2/2 - Security features: 11/11 - Stress test: pass This closes the maintenance debt listed in TODO.md and ensures compatibility with future libssh versions.
544 B
544 B
TODO
Maintenance
- Replace deprecated
libsshfunctions insrc/ssh_server.c:→ssh_message_auth_passwordauth_password_functioncallback (✓ completed)→ssh_message_channel_request_pty_width/heightchannel_pty_request_functioncallback (✓ completed)- Migrated to callback-based server API as of libssh 0.9+
Future Features
- Implement robust command handling for non-interactive SSH exec requests.
- Basic exec support completed (handles
exitcommand) - All tests passing
- Basic exec support completed (handles