lkml.org 
[lkml]   [2001]   [Nov]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: Bind to protocol with AF_PACKET doesn't work for outgoing packets
    Date
    Hello!

    > Just to have an symmetric API. Everything else is too ugly to explain
    > in manpages ;)

    Explaining is easy. Blah-blah-blah... Sockets bound to ETH_P_ALL
    are able to get copy of output packets which is useful f.e.
    for packet sniffers (ref to [libpacp],[tcpdump]). In later kernels
    this can be disabled with option PACKET_NOOUTPUT. When this option
    is not supported user of packet socket bound to ETH_P_ALL has to filter
    output packets at user level checking for pkt_type == PACKET_OUTPUT
    or using an equivalent BPF applet.


    > That would require changing/breaking PF_PACKET, no?

    No. Ideally the option could be PACKET_GRAB_OUTPUT and be disabled
    by default (for symmetry :-)). But as soon as it was forgotten,
    it has to be enabled by default.

    Alexey
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:12    [W:0.023 / U:2.112 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site