getsockopt(SO_SNDBUF) and openssh/HPN

2015-12-29 Thread Chris Stankevitz

Hello,

Please identify any false statements (particularly statement 7 which 
accuses FreeBSD 10.1 of having a bug):


1. openssh limits the size of "the outgoing buffer" to 65KB

2. (1) limits bandwidth on high BDP links.

3. FreeBSD 10.1 supplied openssh/HPN tries to fix (2) by increasing the 
size of "the outgoing buffer" to match the SO_SNDBUF capacity


4. openssh/HPN accomplishes (3) by periodically calling 
getsockopt(SO_SNDBUF)


5. In FreeBSD 10.1, getsockopt(SO_SNDBUF) does not return the value set 
by setsockopt(SO_SNDBUF).  Instead it reports the high watermark of the 
outgoing buffer.


6. (3) does nothing because of (4) and (5)

7. There is a bug in FreeBSD 10.1 networking or FreeBSD 10.1 supplied 
openssh/HPN:


7a. FreeBSD bug: getsockopt(SO_SNDBUF) does not return value set by 
setsockopt(SO_SNDBUF)


7b. openssh/HPN bug: do not use getsockopt(SO_SNDBUF) to get the value 
set by setsockopt(SO_SNDBUF) -- use something else



Original thread from August 2015:
 https://www.mail-archive.com/freebsd-net@freebsd.org/msg49793.html

Thank you,

Chris

___
freebsd-net@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


BPF Berkeley Packet Filter

2015-12-29 Thread Juan Herrera
Hello,

I have a question regarding Berkeley Packet filter, which is Can I read an
incoming packet length with BPF, I am working on a project that requires to
filter the receiving packets in the kernel before they get to userspace,
but I need to be able to read the packet length when applying BPF because I
(previously) encapsulated the packet with my own metadata before sending it
to the machine with BPF so I want to read packet length to decapsulate as I
know the value for the metadata at the end of the packet?


Thank you in advance!
___
freebsd-net@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


[Bug 205706] Watchdog timeout on em driver under heavy traffic on a bridge configuration

2015-12-29 Thread bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=205706

Mark Linimon  changed:

   What|Removed |Added

   Assignee|freebsd-b...@freebsd.org|freebsd-net@FreeBSD.org
   Keywords||IntelNetworking

-- 
You are receiving this mail because:
You are the assignee for the bug.
___
freebsd-net@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"


BPF Berkeley Packet Filter

2015-12-29 Thread Juan Herrera
Hello BSD folks,

I am developing a networking application in C and I have a question
regarding BPF (Berkeley Packet Filters),
I will give you an idea of the app first,  I need to send a packet from
machine A to machine B (any kind of packet) so for this I wrote a packet
generator application which will send a packet to machine B, but before
sending the packet I need to append some metadata values at the end of the
packet, already done, so in machine B I have a raw socket listener app
ready to receive incoming packets from machine A, however I want to
implement filtering with BPF on machine B, but as my metadata was appended
at the end of the packet (have to be at the end), I need to read the packet
length with(using) Berkeley Packet Filter to match a specific field to
filter one of the bytes at the end of my packet (metadata appended), in
other words I need to know the incoming packet length to filtered against
one of the metadatas fields and be able to drop the packet before reaching
user space applications(drop it in kernel space).

So my question is, Can I use BPF to read the packet length to do what I
want?

Thank you in advance!

Happy Holidays!
___
freebsd-net@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"