Re: [exim-dev] DSCP for inbound connections

トップ ページ
このメッセージを削除
このメッセージに返信
著者: Jeremy Harris
日付:  
To: exim-dev
題目: Re: [exim-dev] DSCP for inbound connections
On 2012-06-03 15:24, Phil Pennock wrote:
> On 2012-06-03 at 09:58 -0400, Phil Pennock wrote:
>> Variable: still not quite sure about exposing this, or if perhaps it
>> should be an expansion item rather than a variable, so that each time
>> it's expanded the value is fetched. Er, I'm also blanking on how to
>> *implement* this with a read()-based API, without switching our entire
>> SMTP read system to a readmsg()-based system, which I'm *very* reluctant
>> to do for such a minor feature.
>
> Stevens, Unix Network Programming, volume 1 3rd edition (Stevens,
> Fenner, Rudoff), page 215, under "IP_TOS Socket Option":
>
>    This option lets us set the type-of-service (TOS) field (which
>    contains the DSCP and ECN fields, Figure A.1) in the IP header for a
>    TCP, UDP or SCTP socket.  If we call getsockopt for this option, the
>    current value that would be placed into the DSCP and ECN fields in the
>    IP header (which defaults to 0) is returned.  There is no way to fetch
>    the value from a received IP datagram.

>
> That last sentence clinches it, there will not be a
> $received_initial_dscp or $received_dscp added to Exim.


Seems like a lack in the available interface rather than anything
fundamental, but given how long those bit-positions have been lying around
unused in the ipv4 header I really doubt that many people care.

Should the position be (or become) different in some OS we want
to support we can revisit; as you note an expansion item would
be preferable to a variable (even if a first implementation
could only support the connect-time value, IMHO).
--
Jeremy