snar / bgpq3

bgpq3
BSD 2-Clause "Simplified" License
362 stars 53 forks source link

Enable support for outputting Huawei as-path access-lists #39

Closed wbergg closed 5 years ago

wbergg commented 5 years ago

Add support for Huawei devices (-H) to output Huawei as-path access-lists.

Eg. ./bgpq3 -f 39651 AS-COMHEM -H ip as-path-filter NN permit ^39651(39651)*$ ip as-path-filter NN permit ^39651([0-9]+)*_(25037|28942|56563|59835)$

snar commented 5 years ago

On Mon, Aug 06, 2018 at 01:59:57AM -0700, Alexander Wagberg wrote:

Add support for Huawei devices (-H) to output Huawei as-path access-lists.

Eg. ./bgpq3 -f 39651 AS-COMHEM -H ip as-path-filter NN permit ^39651(39651)$ ip as-path-filter NN permit ^39651([0-9]+)_(25037|28942|56563|59835)$

Can you provide link to Huawei documentation, so I can implement prefix-lists too ?

wbergg commented 5 years ago

You need a login to see the documentation, I took a screenshot of both as-path and prefix-lists: https://wberg.com/huawei.png

snar commented 5 years ago

On Mon, Aug 06, 2018 at 01:59:57AM -0700, Alexander Wagberg wrote:

Add support for Huawei devices (-H) to output Huawei as-path access-lists.

Eg. ./bgpq3 -f 39651 AS-COMHEM -H ip as-path-filter NN permit ^39651(39651)$ ip as-path-filter NN permit ^39651([0-9]+)_(25037|28942|56563|59835)$

Done, pushed to github head. Two notes:

Example:

./bgpq3 -Uf 39651 AS-COMHEM undo ip as-path-filter NN ip as-path-filter NN permit ^39651(39651)$ ip as-path-filter NN permit ^39651([0-9]+)_(25037|28942|56563|59835)$

wbergg commented 5 years ago

That's correct, undo ip as-path-filter < name > !