Difference between revisions of "Sockaccept"
From Scriptwiki
m |
|||
(One intermediate revision by one other user not shown) | |||
Line 9: | Line 9: | ||
[[Sockrename]] Check MyWebServerConnection $+ $ticks | [[Sockrename]] Check MyWebServerConnection $+ $ticks | ||
} | } | ||
+ | else { sockclose Check } | ||
} | } | ||
[[Category:Socket]] | [[Category:Socket]] | ||
+ | [[Category:Commands]] |
Latest revision as of 19:24, 30 January 2011
The sockaccept command assigns a TCP socket name to an incoming connection in an On socklisten event
sockaccept <name>
Examples
on *:SOCKLISTEN:MyWebServer: { sockaccept Check if ($sock(check).ip == allowedIP) { Sockrename Check MyWebServerConnection $+ $ticks } else { sockclose Check } }