2
0
mirror of https://github.com/openvswitch/ovs synced 2025-10-17 14:28:02 +00:00

ofp-util: Add SCTP support

Reviewed-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Joe Stringer <joe@wand.net.nz>
Signed-off-by: Ben Pfaff <blp@nicira.com>
This commit is contained in:
Joe Stringer
2013-08-22 20:24:45 +12:00
committed by Ben Pfaff
parent c6bcb68592
commit 0d56eaf2e0
14 changed files with 251 additions and 38 deletions

View File

@@ -100,6 +100,11 @@ print_netflow(struct ofpbuf *buf)
ntohs(rec->src_port), ntohs(rec->dst_port));
break;
case IPPROTO_SCTP:
printf(", SCTP %"PRIu16" > %"PRIu16,
ntohs(rec->src_port), ntohs(rec->dst_port));
break;
case IPPROTO_ICMP:
printf(", ICMP %"PRIu16":%"PRIu16,
ntohs(rec->dst_port) >> 8,
@@ -120,6 +125,7 @@ print_netflow(struct ofpbuf *buf)
if (rec->ip_proto != IPPROTO_TCP &&
rec->ip_proto != IPPROTO_UDP &&
rec->ip_proto != IPPROTO_SCTP &&
rec->ip_proto != IPPROTO_ICMP) {
if (rec->src_port != htons(0)) {
printf(", src_port %"PRIu16, ntohs(rec->src_port));