| 410 | } |
| 411 | |
| 412 | int |
| 413 | SocksProxy::state_send_socks5_auth_method(int event, [[maybe_unused]] void *data) |
| 414 | { |
| 415 | ink_assert(state == SOCKS_ACCEPT); |
| 416 | switch (event) { |
| 417 | case VC_EVENT_WRITE_COMPLETE: |
| 418 | state = AUTH_DONE; |
| 419 | |
| 420 | buf->reset(); |
| 421 | timeout = this_ethread()->schedule_in(this, HRTIME_SECONDS(netProcessor.socks_conf_stuff->socks_timeout)); |
| 422 | |
| 423 | // We always send "No authentication is required" to client, |
| 424 | // so the next is socks5 request. |
| 425 | vc_handler = &SocksProxy::state_read_socks5_client_request; |
| 426 | clientVC->do_io_read(this, INT64_MAX, buf); |
| 427 | break; |
| 428 | case VC_EVENT_WRITE_READY: |
| 429 | default: |
| 430 | Dbg(dbg_ctl_SocksProxy, "Received unexpected event: %s\n", get_vc_event_name(event)); |
| 431 | break; |
| 432 | } |
| 433 | |
| 434 | return EVENT_DONE; |
| 435 | } |
| 436 | |
| 437 | int |
| 438 | SocksProxy::state_read_socks5_client_request(int event, [[maybe_unused]] void *data) |
nothing calls this directly
no test coverage detected