Re-enable SSL attempts for 'web' services with HTTP fallback

- Try HTTPS first for web services, fallback to HTTP on SSL failure
- Maintains the requested behavior while handling protocol mismatches
parent f29f0154
...@@ -482,6 +482,9 @@ static int handle_proxy_request(int client_fd, wssshd_state_t *state, const wsss ...@@ -482,6 +482,9 @@ static int handle_proxy_request(int client_fd, wssshd_state_t *state, const wsss
if (strcmp(service_type, "https") == 0) { if (strcmp(service_type, "https") == 0) {
use_ssl = true; use_ssl = true;
printf("[WEB-PROXY] Service type 'https', using SSL\n"); printf("[WEB-PROXY] Service type 'https', using SSL\n");
} else if (strcmp(service_type, "web") == 0) {
use_ssl = true; // Try HTTPS first for 'web'
printf("[WEB-PROXY] Service type 'web', trying SSL first\n");
} else { } else {
printf("[WEB-PROXY] Service type '%s', using plain TCP\n", service_type); printf("[WEB-PROXY] Service type '%s', using plain TCP\n", service_type);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment