![]() |
|
#1
|
|||
|
|||
Setting ToS field in the IP header, socket programmingHi friends,
I am new to windows socket programming. I just managed to set up a UDP server and a client, so that the server is able to send UDP packets (read from a file) through the network to the client. In my source code, I can set these information like the following: CPP / C++ / C Code:
These are fine. However, my particular application needs me to set another field in the IP header, which is the 3-bit Type of Service (ToS) field. I do not know how this could be done, does anyone here who have done something similar before? I am very grateful for your replies. Thanks! I am using VC.NET under windows. David Last edited by LuciWiz : 08-Feb-2006 at 12:40.
Reason: Please insert your C++ code between [c++] & [/c++] tags
|
|
#2
|
|||
|
|||
Re: Setting ToS field in the IP header, socket programmingQuote:
I don't have .NET (or any experience with .NET sockets programming), so I can't answer the question directly. I suggest that you poke around msdn for the function setsocketopt(), and do some further searching for "Socket Options", specifically the "IP_TOS" socket option. (Note that, for Linux at least, certain parts of the DSCP/ECN fields affected by setsocketopt() may be overwritten by the kernel. Don't know about Windows.) Regards, Dave Last edited by davekw7x : 08-Feb-2006 at 13:52.
|
Recent GIDBlog
Python ebook by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Where to go for Registry editing and socket programming ? | realnapster | C++ Forum | 2 | 08-Feb-2006 09:54 |
| Pcap programming in C++ | goal86sg | C++ Forum | 2 | 25-Jan-2006 15:02 |
| socket programming | pointer | C++ Forum | 1 | 10-May-2005 16:53 |
| FLTK2 setting input value of an FLTK Input field causes system to crash. | Gutty | FLTK Forum | 0 | 06-Apr-2005 14:30 |
| write a function in socket programming | dxgn | C++ Forum | 0 | 07-Jan-2005 09:48 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The