> => this is like playing with UIDs, which are in the context of the
> application and can be set by set[e]uid() & co, to permit or deny access to
> privileged ports. My idea is to tune the context before performing some
> operations and to reset it after to its previous setup.

While the semantics of such an approach is well-documented and
understood in the uid space, I think it is hard to introduce new such
mechanisms due to the side effect dangers.
Assume you introduce env/context source address selection knobs
and that both getaddrinfo() and connect()/sendto() will use them.
First problem that appears is that internal to getaddrinfo() sockets might
be connected (e.g. to connect to a DNS server, LDAP, whatever else).
It is hard to guage the possible impact of such side effects, but I think
they in general make the system much harder to understand. (Yes, they
are a form of global variables and I think passing explicit arguments
results in less complexity that using global context.)

   Erik

--------------------------------------------------------------------
IETF IPng Working Group Mailing List
IPng Home Page:                      http://playground.sun.com/ipng
FTP archive:                      ftp://playground.sun.com/pub/ipng
Direct all administrative requests to [EMAIL PROTECTED]
--------------------------------------------------------------------

Reply via email to