> >>> Maybe use Pause/Resume ?
>
> > It suppress async notification. So you don't receive events anymore but I/O
> > continue as much as winsock can, for example filling his receive buffer.
>
> Got it. Wouldn't this be similar to ignoring OnDataAvailable event

You can't ignore OnDataavailable event ! If you don't call Receive from 
OnDataAvailable event, the
event will be triggered again and again until you read the data. You'll enter 
an infinite loop.
Calling Pause will stop OnDataAvailable from being triggered, this is different.

> and is vulnerable to DOS attack?

Whan paused, a socket will still accept some data, until winsock buffer is 
full. Then transmission
will be stopped until you resume the socket. At that time, you'll start to 
receive data again
(OnDataAvailable will be triggered again). You application has full control 
about what data is sent
and can detect anormal traffic and close the connection.

> > There is a flag FPaused but it is not exposed as a property.
>
> Oh, will you be able to expose it? I can modify the source
> code for now but I think it's useful when Pause and Resume
> is exposed.

Not really. You can have a flag set/reset in your own application when you call 
Pause/Resume, or you
can derive from TWSocket and create the property in your derived component. 
That's what OOP is all
about.

--
Contribute to the SSL Effort. Visit
http://www.overbyte.be/eng/ssl.html
--
[EMAIL PROTECTED]
Author of ICS (Internet Component Suite, freeware)
Author of MidWare (Multi-tier framework, freeware)
http://www.overbyte.be



-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://www.elists.org/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to