Re: Import filter on 2nd ASN in AS path?

2019-03-28 Thread Robert Scheck
Hello Ondrej, On Thu, 28 Mar 2019, Ondrej Zajicek wrote: > That is unfortuately not possible (only single ASNs or ASN ranges), > although it is a thing that makes perfect sense, so we should implement > it. cool, I'm curious for it :) > What about: delete(bgp_path, bgp_path.first).first ? Yes,

Re: Import filter on 2nd ASN in AS path?

2019-03-27 Thread Ondrej Zajicek
On Thu, Mar 28, 2019 at 12:25:29AM +0100, Robert Scheck wrote: > Hello Maria, > hello Alexander, > > first of all, thank you very much for your suggestions. > > On Tue, 26 Mar 2019, Maria Matějka wrote: > > Did you try using BGP path mask? Like > > if (bgp.path ~ [= ? bogon bogon * =]) … > > I

Re: Import filter on 2nd ASN in AS path?

2019-03-27 Thread Robert Scheck
Hello Maria, hello Alexander, first of all, thank you very much for your suggestions. On Tue, 26 Mar 2019, Maria Matějka wrote: > Did you try using BGP path mask? Like > if (bgp.path ~ [= ? bogon bogon * =]) … I didn't try this before, but I'm now also not sure how I could get my int set

Re: Import filter on 2nd ASN in AS path?

2019-03-26 Thread Maria Matějka
Hi! Did you try using BGP path mask? Like if (bgp.path ~ [= ? bogon bogon * =]) … Writing this from my phone. Please consult documentation or filter/test.conf file in source tree for exact syntax and examples. Maria On March 26, 2019 10:34:39 AM GMT+01:00, Alexander Zubkov wrote: >Hi, >

Re: Import filter on 2nd ASN in AS path?

2019-03-26 Thread Alexander Zubkov
Hi, You can try to delete AS-TRANSIT from the path and get first. Something like (this is just a sketch): delete(bgp_path, AS-TRANSIT).first ~ BOGON_ASNS On Mon, Mar 25, 2019 at 9:50 PM Robert Scheck wrote: > > Hello folks, > > can I somehow import filter only on the 2nd AS number in the AS

Import filter on 2nd ASN in AS path?

2019-03-25 Thread Robert Scheck
Hello folks, can I somehow import filter only on the 2nd AS number in the AS path? I know with the snippet below (heavily inspired by bgpfilterguide.nlnog.net), I can filter on AS numbers that appear somewhere in the AS path, however this import filter catches by nature also some