Implement Extended Optional Parameters Length 54/80854/8
authorRobert Varga <robert.varga@pantheon.tech>
Thu, 14 Mar 2019 11:35:40 +0000 (12:35 +0100)
committerRobert Varga <robert.varga@pantheon.tech>
Tue, 30 Apr 2019 11:21:24 +0000 (13:21 +0200)
commitbe9d76931bce08f488aa152ef5232eafe774c93f
treef3f705ce9ebffd586fe36c40e30d9ec685e6df37
parent310f15691a6235382a40320faaca6e5a6e3a4484
Implement Extended Optional Parameters Length

This corrects handling of optional parameters to comply with RFC4271
and adds the ability to use draft-ietf-idr-ext-opt-param-05.

As per the draft, outbound encoding is used only when necessary and
on inbound it is correctly detected when sent by peer.

JIRA: BGPCEP-868
Change-Id: If822d9b9ce4bf982da5f698aac5248b28b0aaa79
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
bgp/parser-impl/src/main/java/org/opendaylight/protocol/bgp/parser/impl/message/BGPOpenMessageParser.java
bgp/parser-impl/src/main/java/org/opendaylight/protocol/bgp/parser/impl/message/open/CapabilityParameterParser.java
bgp/parser-impl/src/test/java/org/opendaylight/protocol/bgp/parser/impl/OpenTest.java
bgp/parser-spi/src/main/java/org/opendaylight/protocol/bgp/parser/spi/ParameterLengthOverflowException.java [new file with mode: 0644]
bgp/parser-spi/src/main/java/org/opendaylight/protocol/bgp/parser/spi/ParameterRegistry.java
bgp/parser-spi/src/main/java/org/opendaylight/protocol/bgp/parser/spi/ParameterSerializer.java
bgp/parser-spi/src/main/java/org/opendaylight/protocol/bgp/parser/spi/ParameterUtil.java
bgp/parser-spi/src/main/java/org/opendaylight/protocol/bgp/parser/spi/pojo/SimpleParameterRegistry.java
bgp/parser-spi/src/test/java/org/opendaylight/protocol/bgp/parser/spi/UtilsTest.java
bgp/parser-spi/src/test/java/org/opendaylight/protocol/bgp/parser/spi/pojo/BgpTestActivator.java
bgp/parser-spi/src/test/java/org/opendaylight/protocol/bgp/parser/spi/pojo/SimpleRegistryTest.java