Top Level Namespace
Defined in:
Constant Summary
-
DEFAULT_DELAY =
200_i64
-
DEFAULT_PORT =
1234
-
DELAY_VARIANCE =
0.1
-
HELP_BANNER =
"Use delay-proxy [target-host:]port [proxy-port] [delay in milliseconds]"
-
SOCKET_BUFFER_SIZE =
(1024 * 1024) * 8
-
VERSION =
{{ (`shards version \"/srv/crystaldoc.info/github-hugopl-delay-proxy-v0.1.0/src\"`).chomp.stringify }}
Method Summary
- forward_socket(src : IO, dst : IO, label, delay : Int)
- handle_connection(proxy_socket : Socket, target_host : String, target_port : Int, delay : Int64)
- main
- parse_host_port(_nil : Nil, default_port : Int)
- parse_host_port(str : String, default_port : Int | Nil = nil)
- parse_options
- random_delay(delay : Int)
Method Detail
def handle_connection(proxy_socket : Socket, target_host : String, target_port : Int, delay : Int64)
#