Hello.
I'd like to control download volume/speed on my side -- and on the server's side as well (to be polite). ... It is not about "my own download manager".
Let's imagine: I allow my son to download max 500Mb / day from utube, and still, he initiates a session to download a 10Gb HD movie. (Not necessarily ab. parental control, but technically this is a good example).
The question I have is: how to limit. I want to write a driver that'd control this on the TCP (IP?) level. Is it possible to on TCP level?
I know I can handle it locally (by e.g. narrowing the TCP window I advertise to the server, or by simply closing the connection after XXX bytes).
But waht I really want is to tell the (say) utube politely: (after the connection had been established and the downloading is in progress) : don't try try hard to still squeeze this movie into small segments, and create a lot of congestion on the n/w - we're done.
I'd like to avoid the unnecessary n/w on any side; basically I'd like to be able (on the TCP level) to tell the other end: This is it, we're done for today. Please don't retry to deliver the whole movie, I am not interested in watching the rest of it (today). (So that utube would just stop polluting the bandwidth instantaneously).
Maybe to confuse you more -- but hopefully to clarify, -- here's an excerpt from the "Definitive guide to Linux network programming", p.31: (Talking about the 6 bits part of the TCP header: URG, ACK, PSH, RST, SYS, FIN): ""... situations arise when data must be transmitted out of band. ... This is whether the URG bit comes into play. Consider a connection a user wishes to abort, such as ..." (etc.).
That's probably what I am looking for: send the utube the "URG" with "ABORT". The only thing that is unclear to me from this text is this "ABORT". Is this "RST"? or what?
Please push me a bit in a right direction.
Thanks Gurus in advance.