After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 667858 - Add support for setting Type Of Service on IP sockets
Add support for setting Type Of Service on IP sockets
Status: RESOLVED DUPLICATE of bug 623187
Product: glib
Classification: Platform
Component: network
2.25.x
Other Linux
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2012-01-13 10:34 UTC by Sebastian Dröge (slomo)
Modified: 2012-12-12 09:50 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Sebastian Dröge (slomo) 2012-01-13 10:34:33 UTC
See summary, this can be done on Unix with setsockopt() and IP_TOS/IPV6_TCLASS
Comment 1 Sebastian Dröge (slomo) 2012-01-13 11:13:34 UTC
...and this should of course not be used for the "old" TOS but for DSCP (RFC 2474) and ECN (RFC 3168).
Comment 2 Dan Winship 2012-01-13 19:20:21 UTC
There was discussion in bug 623187 about how much we want to expose random sockopts, because there are a more-or-less infinite number of them, and we can't wrap them all... Between that bug and bug 626589, I decided the goal should be have GSocket methods for things that "lots" of programs would need, and just make it easy to use setsockopt() directly if you need to set a more obscure option.

Alas, I don't really have a good sense of which options are needed by "lots" of programs and which aren't. :-} Copying at least what GNet implements probably makes sense.

Since the last discussion in 623187 I was thinking about maybe also having a GSocket wrapper specifically for int-valued sockopts (which is 90% of them really). Eg, it would cover IP_TOS, IP_MULTICAST_LOOP, SO_BROADCAST, etc.
Comment 3 Dan Winship 2012-12-12 09:50:03 UTC
duping this to 623187, which now has a patch for g_socket_set_option()

*** This bug has been marked as a duplicate of bug 623187 ***