- 19 Sep, 2025 1 commit
-
-
Stefy Lanza (nextime / spora ) authored
- Update project name from 'WebSocket SSH' to 'WSSSH:: Warp-Powered Stefy's Spatial Secure Hyperdrive' - Update project description to emphasize evolution as universal tunneling utility - Update README.md, DOCUMENTATION.md, CHANGELOG.md, TODO.md - Update all man pages (wsssh.1, wsscp.1, wssshc.1, wsssht.1) - Update Debian control files for both packages - Update configuration examples and build scripts - Update source code comments in tunnel and client files
-
- 18 Sep, 2025 39 commits
-
-
Stefy Lanza (nextime / spora ) authored
-
Stefy Lanza (nextime / spora ) authored
New wsscp application: - WebSocket SCP wrapper similar to wsssh but for SCP instead of SSH - Uses -P option for port detection (SCP standard) instead of -p - Automatically constructs ProxyCommand for WebSocket tunnels - Supports same command line syntax as regular SCP - Includes automatic port detection from -P option - Full integration with wsssht WebSocket tunnel infrastructure Implementation details: - wsscp.h: Header file with configuration structures and function declarations - wsscp.c: Complete implementation with argument parsing and SCP command generation - Updated configure.sh to build wsscp alongside other tools - Added wsscp.1 man page with comprehensive documentation - Tested functionality with debug mode and argument parsing Features: - Automatic wsssht path detection (PATH or same directory) - Smart port detection: explicit --wssshd-port takes precedence over -P option - Support for all wsssht tunnel options (--tunnel, --tunnel-control, --debug) - Compatible with existing wssshc/wsssht infrastructure - Proper error handling and user-friendly help messages Usage examples: wsscp localfile user@myclient:/remote/path wsscp -P 2222 localfile user@myclient.server.com:/remote/path wsscp --debug --tunnel websocket localfile user@myclient:/remote/path
-
Stefy Lanza (nextime / spora ) authored
wsssh improvements: - Parse SSH arguments for -p option to extract port value - Automatically add --wssshd-port to ProxyCommand when -p is specified and --wssshd-port is not explicitly set - Fix build warnings in find_wsssht_path function - Change debug mode to execute SSH command instead of just printing it wsssht improvements: - Modify pipe mode debug output to use stderr instead of stdout - Prevent debug messages from interfering with piped data streams - All debug output in pipe mode now goes to stderr to avoid contaminating stdin/stdout These changes improve the usability and reliability of both wsssh and wsssht applications, especially when used in pipe mode or with SSH port specifications.
-
Stefy Lanza (nextime / spora ) authored
- Create wsssh.h header file with configuration structures and function declarations - Implement wsssh.c with comprehensive SSH wrapper functionality: * Parse command line arguments (--help, --clientid, --wssshd-host, --wssshd-port, --debug, --tunnel, --tunnel-control) * Parse target string in format: user[@clientid[.wssshd-host[:sshstring]]] * Build ProxyCommand using wsssht --pipe with appropriate options * Find wsssht in PATH or same directory as wsssh * Construct and execute SSH command with ProxyCommand * Debug mode shows constructed command without executing - Add wsssh to build system (configure.sh and Makefile) - Update debian/control to include wsssh in package description - Create comprehensive man page (man/wsssh.1) with usage examples - Tested functionality with various command line options wsssh provides a convenient wrapper around SSH that automatically sets up WebSocket tunneling through wsssht, making it easy to use SSH with WebSocket relays without manual ProxyCommand configuration.
-
Stefy Lanza (nextime / spora ) authored
- Remove wsssh.c and wsscp.c source files - Remove wsssh.1 and wsscp.1 man pages - Remove wsssh.conf.example and wsscp.conf.example config files - Update configure.sh to exclude wsssh and wsscp from build - Update debian/control to reflect remaining tools (wssshc + wsssht) - Verified build works with only wssshc and wsssht binaries - Project now focuses on wssshc (client) and wsssht (tunnel tool with pipe mode)
-
Stefy Lanza (nextime / spora ) authored
- Add MODE_PIPE constant to wsssht.h - Implement run_pipe_mode() function with proper tunnel negotiation - Add --pipe and --mode pipe command line options - Pipe mode negotiates tunnel (tunnel_request -> tunnel_ack) like other modes - Redirects raw tunnelled data to stdin/stdout instead of binding to TCP ports - Silent operation with no terminal output - Compatible with SSH ProxyCommand for transparent WebSocket SSH tunneling - Update include paths in all affected files after moving headers to libwsssht/ - Update configure.sh to generate correct makefile with new file locations
-
Stefy Lanza (nextime / spora ) authored
-
Stefy Lanza (nextime / spora ) authored
- Remove duplicate remove_tunnel() call in handle_connection cleanup - Prevent double-free of tunnel resources during concurrent connection cleanup - Ensure proper thread synchronization during tunnel cleanup - Fix race condition between forwarding thread exit and cleanup
-
Stefy Lanza (nextime / spora ) authored
- Add forward_thread field to tunnel_t structure for thread synchronization - Remove pthread_detach() to allow proper thread joining during cleanup - Add pthread_join() in cleanup to wait for forwarding thread completion - Prevent race conditions between cleanup and forwarding threads - Ensure tunnel resources are not freed while threads are still using them - Fix concurrent connection cleanup issues in wsssht daemon mode
-
Stefy Lanza (nextime / spora ) authored
- Implement thread-based concurrent connection handling - Fix segmentation fault caused by shared static variables - Each connection now gets its own WebSocket tunnel and resources - Replace global tunnel management with per-thread instances - Add proper cleanup for individual connection threads - Allow multiple SSH sessions to connect simultaneously to the same port
-
Stefy Lanza (nextime / spora ) authored
- Updated README.md project structure to reflect new libwsssht/ modular organization - Updated DOCUMENTATION.md with new modular component descriptions - Added CHANGELOG.md entry for version 1.6.1 with refactoring details - Added TODO.md entry documenting the completed refactoring work All documentation now reflects the new modular architecture with improved maintainability.
-
Stefy Lanza (nextime / spora ) authored
- Created libwsssht/ directory with modular components: * utils.h/c: Utility functions (print_usage, parse_connection_string, parse_args) * modes.h/c: Mode-specific functions (bridge, script, daemon modes) * threads.h/c: Thread-related functions and structures * wsssht.h: Main header with includes and declarations - Reduced wsssht.c from 2769 lines to 674 lines (main function only) - Updated Makefile and configure.sh to handle new modular structure - Maintained exact same functionality and command-line interface - Improved code maintainability and organization All functionality preserved, build successful, and wsssht binary works correctly.
-
Stefy Lanza (nextime / spora ) authored
-
Stefy Lanza (nextime / spora ) authored
- Suppress verbose tunnel_data debug messages in main tunnel loop - Suppress tunnel_data debug messages in thread function - Suppress tunnel_data debug messages in daemon mode - Suppress WebSocket 'Received message' and 'Processing message' debug messages for tunnel_data - Maintain functionality while reducing debug log verbosity - Preserve other debug messages (tunnel_response, tunnel_close, etc.)
-
Stefy Lanza (nextime / spora ) authored
- wssshd: Added full JSON logging for all received/sent control messages when --debug enabled - wssshc: Verified existing control message logging - wsssht: Suppressed verbose data channel messages in debug mode - Fixed wsssht daemon mode for multiple sequential connections - Fixed wsssht script mode data forwarding and JSON output - Increased thread cleanup timeout to prevent race conditions - All components compile and work correctly
-
Stefy Lanza (nextime / spora ) authored
- wssshd (websocket.py): Log full JSON content of all received and sent control channel messages when --debug enabled - wssshc: Verified existing debug logging for control messages - Fixed wsssht script mode data forwarding for tunnel_response messages - Suppressed data channel message output in script mode for clean JSON protocol - Fixed wsssht daemon mode to properly handle multiple connections and wait indefinitely
-
Stefy Lanza (nextime / spora ) authored
- Add debug logging for all control channel messages in wssshd and wssshc when --debug flag is enabled, showing full JSON content of received and sent messages - Fix data forwarding issue in wsssht script mode - Suppress data channel message output in wsssht script mode for cleaner output - Enhance script_started message in wsssht script mode to include tunnel_host, tunnel_port, and service fields - Remove obsolete test_bridge_interactive.sh file Control channel messages now logged include: register, registered, registration_error, tunnel_request, tunnel_ack, tunnel_close, tunnel_error for both server and client.
-
Stefy Lanza (nextime / spora ) authored
- Bridge mode was incorrectly using raw socket operations over SSL connection - Updated to use SSL_read/SSL_write for all WebSocket communication - Fixed send_websocket_message to use send_websocket_frame with SSL - Fixed pong frame sending to use SSL - Fixed select() and FD_ISSET to monitor correct socket This resolves the 'send_error' and connection closure issues in bridge mode tests.
-
Stefy Lanza (nextime / spora ) authored
- wssshd: Log full content of all received and sent control messages when --debug is enabled - wssshc: Already logs control messages, registration message logging enhanced - wsssht: Fixed memory corruption issue with config struct allocations Control channel messages include: register, registered, registration_error, tunnel_request, tunnel_ack, tunnel_error, tunnel_close, tunnel_data, tunnel_response
-
Stefy Lanza (nextime / spora ) authored
- Enhanced bridge mode to handle incoming tunnel control messages from WebSocket - Added JSON output for tunnel_data, tunnel_response, tunnel_close messages - Added WebSocket connection status messages (websocket_close, websocket_connection_closed) - Updated test scripts to include tunnel control channel message testing - Updated documentation with comprehensive examples of control channel messages - Added new testing scenario for tunnel control channel verification Bridge mode now properly forwards all tunnel control channel messages as JSON through stdout, allowing external applications to monitor tunnel state and server communications in real-time.
-
Stefy Lanza (nextime / spora ) authored
- test_bridge_mode.sh: Automated test script for bridge mode functionality - test_bridge_interactive.sh: Interactive testing tool with manual JSON command input - BRIDGE_MODE_TESTING.md: Complete testing guide with examples and integration patterns Features: - Automated and interactive testing modes - JSON command examples and validation - Real-time response monitoring - Error handling and process management - Integration examples in Python and Node.js - Troubleshooting guide and best practices - Colored output and user-friendly interface These tools provide comprehensive testing capabilities for the new bridge mode, allowing developers to easily test and integrate with the JSON stdin/stdout interface.
-
Stefy Lanza (nextime / spora ) authored
- Fixed documentation to correctly state that in bridge mode: - Tunnel control channel messages are communicated through stdin/stdout (JSON protocol) - Tunnel data channel messages remain handled by wsssht (normal forwarding) - Updated README.md, DOCUMENTATION.md, CHANGELOG.md, and TODO.md - The implementation was already correct, just the documentation was backwards
-
Stefy Lanza (nextime / spora ) authored
- Updated documentation to clarify that in ALL modes, wsssht handles tunnel control channel messages - Clarified that in bridge mode specifically, tunnel data channel messages are NOT handled by wsssht - Instead, raw tunnel data is communicated through stdin/stdout for external processing - Updated README.md, DOCUMENTATION.md, CHANGELOG.md, and TODO.md with this clarification - This ensures proper understanding of bridge mode's data handling architecture
-
Stefy Lanza (nextime / spora ) authored
- Updated README.md with comprehensive operating mode descriptions - Added detailed usage examples for all modes (interactive, silent, bridge, script, daemon) - Updated CHANGELOG.md with version 1.6.0 featuring new operating modes - Updated TODO.md with completed items and new feature descriptions - Updated DOCUMENTATION.md with operating mode details and API documentation - Enhanced man pages with new command-line options - Updated configuration examples to include new [wssht] section options - Comprehensive documentation coverage for all new features
-
Stefy Lanza (nextime / spora ) authored
- Added run_bridge_mode() function with JSON stdin/stdout interface - Added run_script_mode() function with JSON protocol for scripting - Bridge mode: JSON communication between stdin/stdout and WebSocket - Script mode: JSON status updates, command processing, and monitoring - Both modes provide structured JSON output for programmatic use - Fixed compilation warnings and ensured clean build - All operating modes now fully implemented
-
Stefy Lanza (nextime / spora ) authored
- Added run_daemon_mode() function for lazy tunnel establishment - Daemon mode waits for first connection attempt before establishing tunnel - Reduces resource usage by not connecting until actually needed - Maintains all existing functionality after tunnel is established - Fixed compilation errors and ensured clean build - Updated mode handling to support daemon mode
-
Stefy Lanza (nextime / spora ) authored
- Modified websocket_handshake() function to accept debug parameter - Updated all debug messages in websocket_handshake to only print when debug=1 - Updated all callers of websocket_handshake() to pass debug flag - Fixed compilation warnings and ensured clean build - WebSocket handshake messages now only appear with --debug flag
-
Stefy Lanza (nextime / spora ) authored
- Fixed unused parameter warnings in run_bridge_mode and run_script_mode functions - Added parameter usage in debug output to eliminate compiler warnings - Compilation now clean with no warnings or errors
-
Stefy Lanza (nextime / spora ) authored
- Added --config FILE option to specify custom config file path - Removed [wssht] section from wsssh.conf.example (legacy) - Created separate wsssht.conf.example with wssht-specific options - Updated man page with new --config option and mode options - Updated usage message to include all new options - Config file validation: errors if specified file doesn't exist
-
Stefy Lanza (nextime / spora ) authored
- Fixed 'free(): invalid pointer' error when using service prefix format - Issue was caused by modifying the original allocated string and then trying to free a pointer to the middle of it - Added proper pointer tracking to ensure correct memory deallocation
-
Stefy Lanza (nextime / spora ) authored
- Connection string values now properly override config file values - Fixed issue where 'wsssht zeiss' wasn't working due to incorrect precedence logic - Command line options still take highest precedence, then connection string, then config file
-
Stefy Lanza (nextime / spora ) authored
- Support connection string format: [service://]clientid[@wssshd-host][:wssshd-port] - Command line options take precedence over connection string values - Update usage message and man page with new syntax - Add comprehensive documentation for connection string format - Maintain backward compatibility with existing option-based usage
-
Stefy Lanza (nextime / spora ) authored
- Remove leftover logic for handling positional arguments in parse_args() - Since wsssht no longer accepts user@host arguments, remove the non-option argument handling - Remove unused parse_hostname() and parse_target_args() functions - Fix issue where valid options were triggering --help output
-
Stefy Lanza (nextime / spora ) authored
- Add tunnel-port option to wsssht.conf.example - Update man page configuration example to include all options - Reorder options logically in both files - Include comprehensive comments explaining each option
-
Stefy Lanza (nextime / spora ) authored
- Update all config file references from 'wssht' to 'wsssht' - Rename wssht.conf.example to wsssht.conf.example - Update man page to reflect correct config file names - Fix config reading calls to use 'wsssht' instead of 'wssht'
-
Stefy Lanza (nextime / spora ) authored
- Change 'Transport types' to 'Transport' in --tunnel option description - Add 'or websocket' to the description for clarity - Update both usage message in wsssht.c and man page wsssht.1
-
Stefy Lanza (nextime / spora ) authored
- Move --wssshd-port option to appear right after --wssshd-host - Update both usage message in wsssht.c and man page wsssht.1 - Maintain logical grouping of related options
-
Stefy Lanza (nextime / spora ) authored
- Update read_config_value_from_file() to support config precedence: 1. ~/.config/wsssh/wssht.conf (user config) 2. /etc/wsssht.conf (system config) - Update man page to document config file precedence order - Command line options still have highest priority
-
Stefy Lanza (nextime / spora ) authored
- Remove parsing of user@domain format from wsssht - Add --clientid option for specifying client ID - Add --wssshd-port option (replacing -p/--port) - Update wssshd-host default to mbetter.nexlab.net - Add client_id field to wsssh_config_t struct - Update config reading to include clientid and wssshd-port - Update wssht.conf.example with new options - Update man page wsssht.1 with new options and examples - Ensure --wssshd-host is required if not in config - Update all usage messages and documentation
-