2009/304 IP PROMISC Flag

James Carlson james.d.carlson at sun.com
Fri May 15 07:02:57 PDT 2009


I'm sponsoring this fast-track request for Girish Moodalbail.  The
timer is set to 05/22/2009.


The release binding is "patch/micro" and consolidation is "ON".  The
stability level of the ifconfig output with new interface flag is 
"Committed".

Problem Definition and Proposal:
---------------------------------

Today the ifconfig(1m) output does not display the promiscuous state
of an underlying physical interface.  The Solaris kernel has all the
provisions to record the promiscuous state of the underlying physical
interface in 'phyint_flags' member variable of struct phyint, but it
does not expose that state using the existing (unused) IFF_PROMISC
flag.

Further, IFF_PROMISC is a standard flag that works on other Unix
variants and we should support it for compatibility.

Making IP subscribe to the DLPI DL_NOTE_PROMISC_ON/OFF_PHYS
notifications and set/reset the IFF_PROMISC flag would fix the
problem.  With this fix the ifconfig(1m) output would have a new
interface flag 'PROMISC' displayed in the output.  (In fact, ifconfig
already supports the flag, but hasn't yet displayed it due to a lack
of kernel support.)

For example:

bash-3.2# ifconfig -a
bge0: flags=1004943<UP,BROADCAST,RUNNING,PROMISC,MULTICAST,DHCP,IPv4> 
mtu 1500 index 2
         inet 10.8.48.152 netmask ffffff80 broadcast 10.8.48.255
         ether 0:3:ba:94:2f:56
bge0: flags=2000941<UP,RUNNING,PROMISC,MULTICAST,IPv6> mtu 1500 index 2
         inet6 fe80::203:baff:fe94:2f56/10
         ether 0:3:ba:94:2f:56
bge0:1: flags=2080941<UP,RUNNING,PROMISC,MULTICAST,ADDRCONF,IPv6> mtu 
1500 index 2
         inet6 2002:a08:39f0:3:203:baff:fe94:2f56/64

As shown above, all the IP interfaces defined on 'bge0' have PROMISC 
interface flag set.

Interface change:

	Name		Stability		Comments
	PROMISC		Committed		ifconfig(1M) flag

The ifconfig(1M) man page will be updated to document the new
interface flag.



More information about the opensolaris-arc mailing list