From: Justin Pettit Date: Thu, 14 May 2009 23:21:03 +0000 (-0700) Subject: netflow: Document 1400-byte packet length limit. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=45b20cb8bc5fef702d44631d74be1e203f334947;p=openvswitch netflow: Document 1400-byte packet length limit. The NetFlow code accumulates records until the packet is 1400 bytes or some amount of time has passed. This just adds a comment that NetFlow messages are limited to 30 records, which places a ceiling on how large the message can be (1400 is below that ceiling). --- diff --git a/secchan/netflow.c b/secchan/netflow.c index dc83a9b0..b68a51ca 100644 --- a/secchan/netflow.c +++ b/secchan/netflow.c @@ -227,6 +227,8 @@ netflow_expire(struct netflow *nf, const struct ofexpired *expired) nf_rec->ip_proto = expired->flow.nw_proto; nf_rec->ip_tos = expired->ip_tos; + /* NetFlow messages are limited to 30 records. A length of 1400 + * bytes guarantees that the limit is not exceeded. */ if (nf->packet.size >= 1400) { netflow_run(nf); }