exabgp icon indicating copy to clipboard operation
exabgp copied to clipboard

flowspec redirect ip implemention

Open pubyun opened this issue 9 years ago • 12 comments

some vendor like Huawei only implement new draft:

https://tools.ietf.org/html/draft-ietf-idr-flowspec-redirect-ip-02

and exabgp only implement old draft:

https://tools.ietf.org/html/draft-simpson-idr-flowspec-redirect-02

so the huawei and exabgp is not compatible

pubyun avatar Nov 17 '16 07:11 pubyun

Hello @pubyun

Some other vendors also implement the old draft - so I am stuck and doomed to displease someone until the document reach RFC status ! :-(

Thomas

thomas-mangin avatar Nov 17 '16 11:11 thomas-mangin

can ExaBGP support two draft and have a option for it?

pubyun avatar Nov 17 '16 12:11 pubyun

everything is possible but the realistic answer is not easily and I have no time to be able to start this work atm.

thomas-mangin avatar Nov 17 '16 13:11 thomas-mangin

@thomas-mangin Could you tell us where we can get the value of redirect ip of the config file in the code ? I want to try to make some changes to test the new draft https://tools.ietf.org/html/draft-ietf-idr-flowspec-redirect-ip-02 for example flow { route test { match { destination 100.0.80.2/32; #destination-port >8080&<8088 =3128; source-port >1024; protocol tcp; } then { redirect 192.168.20.2; } } }

Johnny0326 avatar Aug 22 '17 07:08 Johnny0326

@Johnny0326 happy to help but .. I do not understand the question ..

thomas-mangin avatar Aug 22 '17 08:08 thomas-mangin

@thomas-mangin I want to know where can I get value of the parameter of redirect ip, then I can assign it into the BGP Extended Communities. In the draft https://tools.ietf.org/html/draft-simpson-idr-flowspec-redirect-02 the redirect IP is writed in the BGP Extended Communities.

Johnny0326 avatar Aug 22 '17 08:08 Johnny0326

@Johnny0326 I still do not understand. The parser create a Change object which contains the NLRI and attribute the value will be within that object. You will need to read the code and understand the class structure if you want to perform changes.

The difference between the draft and the implementation change is very small, but as I said, as long as no RFC is out, I do not intend to change the code, unless all large vendors have already updated their implementation to the latest version.

thomas-mangin avatar Aug 22 '17 11:08 thomas-mangin

@thomas-mangin (and others):

I know this thread is a year old but wanted to update with my observations as well:

We have run into similar issues with Juniper (vSRX) where it does not like the extended community type (0x0800) for redirect-to-ip flow spec too whereas Cisco seems to be happy :) and seems to support only the new community type

Looks like following clarifies the formatting of BGP FlowSpec Redirect Extended community:

https://tools.ietf.org/html/rfc7674

Would be good to know if ExaBGP would be able to support both in future versions.

Thanks

sonixyznitesh avatar Nov 02 '17 21:11 sonixyznitesh

@thomas-mangin

Any update on this one?

We are using ExaBGP v3.4.20 and it uses 'extended community type = 0x0800' for flow spec redirect-to-ip - this is causing juniper to reject the route with following error message:

"Extended Communities(16): Unsupported IANA community format:800:0:0:0:0:0:0"

Looks like Juniper expects community type 0x8108 which uses: 'Generic Transitive Experimental Use Extended Community Part 2 Sub-Types' 9 (sub type = 0x08)

To confuse the matter further, when I look at IANA assignments, I found following as well for FlowSpec IPv4/Ipv6 redirect to IP

  • Transitive IPv4-Address-Specific Extended Community Sub-Types : 0x0c
  • Transitive IPv6-Address-Specific Extended Community Types: 0x000c

https://www.iana.org/assignments/bgp-extended-communities/bgp-extended-communities.xhtml#trans-ipv6

sonixyznitesh avatar Nov 08 '17 02:11 sonixyznitesh

No RFC - no change in code in 3.4. to follow the principle of least surprise. However things may have changed enough to justify a change of code in 4.0

thomas-mangin avatar Nov 08 '17 06:11 thomas-mangin

Unfortunately I need to send flowspec redirect routes to Juniper gear, so I'll have to patch my exa to support the ietf draft.

Given the RFC (still ☹️) hasn't been finalized and there's now a vendor split between simpson, ietf, and both - is there interest in upstreaming that patchset behind a config flag, or do you want to hold off?

elindsey avatar Sep 25 '19 20:09 elindsey

Yes, i would gratefully take this on.

thomas-mangin avatar Sep 26 '19 06:09 thomas-mangin