summaryrefslogtreecommitdiffstats
path: root/vpp-common/vpp-translate-utils/src
diff options
context:
space:
mode:
authorMarek Gradzki <mgradzki@cisco.com>2016-10-10 14:55:15 +0200
committerMaros Marsalek <mmarsale@cisco.com>2016-10-13 11:27:29 +0000
commite90041d108c7c72901ddda0124a71fbb7c582cca (patch)
tree2166bcf4eaa6cba90fb0a852b49c0981fc4404e4 /vpp-common/vpp-translate-utils/src
parent5d4de31ab3a6c7b1b1759fcb8a227492c770d61c (diff)
HONEYCOMB-233: add support for mixing L2/L3 rules
In case of L2 interfaces, acls are translated into a chain of classify tables and assigned as L2 table. In case of L3 interfaces, acls are translated into ip4 and ip6 chains (eth only rules go to both chains, rest - depending on ip-version). Limitations: - it is not possible to define L3 rule without specifying ip-version (common header fields for IP4/IP6 have different offsets), - eth rules on L3 interfaces are applied only to IP traffic (vpp classfier limitation). Change-Id: I7ca2648cabad8c6e936cf71a51e06596a42891e8 Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
Diffstat (limited to 'vpp-common/vpp-translate-utils/src')
-rw-r--r--vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/Ipv4Translator.java2
-rw-r--r--vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/MacTranslator.java2
2 files changed, 3 insertions, 1 deletions
diff --git a/vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/Ipv4Translator.java b/vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/Ipv4Translator.java
index 84b0a2e68..56aa4f149 100644
--- a/vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/Ipv4Translator.java
+++ b/vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/Ipv4Translator.java
@@ -30,6 +30,8 @@ import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.
*/
public interface Ipv4Translator extends ByteDataTranslator {
+ Ipv4Translator INSTANCE = new Ipv4Translator() {};
+
/**
* Creates address array from address part of {@link Ipv4Prefix}
*/
diff --git a/vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/MacTranslator.java b/vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/MacTranslator.java
index a947f95c6..14cc28909 100644
--- a/vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/MacTranslator.java
+++ b/vpp-common/vpp-translate-utils/src/main/java/io/fd/honeycomb/translate/vpp/util/MacTranslator.java
@@ -28,7 +28,7 @@ import org.apache.commons.codec.DecoderException;
import org.apache.commons.codec.binary.Hex;
/**
- * Trait providing logic for translation of ipv4-related data
+ * Trait providing logic for translation of MAC address data
*/
public interface MacTranslator {