git://git.onelab.eu
/
sliver-openvswitch.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add Nicira extension to OpenFlow for dropping spoofed ARP packets.
[sliver-openvswitch.git]
/
ofproto
/
ofproto.c
diff --git
a/ofproto/ofproto.c
b/ofproto/ofproto.c
index
91ff023
..
2e1530a
100644
(file)
--- a/
ofproto/ofproto.c
+++ b/
ofproto/ofproto.c
@@
-2631,6
+2631,12
@@
xlate_nicira_action(struct action_xlate_ctx *ctx,
ctx->flow.tun_id = oa->tunnel.tun_id = nast->tun_id;
break;
ctx->flow.tun_id = oa->tunnel.tun_id = nast->tun_id;
break;
+ case NXAST_DROP_SPOOFED_ARP:
+ if (ctx->flow.dl_type == htons(ETH_TYPE_ARP)) {
+ odp_actions_add(ctx->out, ODPAT_DROP_SPOOFED_ARP);
+ }
+ break;
+
/* If you add a new action here that modifies flow data, don't forget to
* update the flow key in ctx->flow at the same time. */
/* If you add a new action here that modifies flow data, don't forget to
* update the flow key in ctx->flow at the same time. */