I have a SRX340 in packet mode that I am soon to deploy in a multi-homed BGP setup. With the SRX I don't have enough memory to take two full tables, however I don't want to limit myself to just connected routes or defaults.
We are in ARIN and I have been exploring the idea of filtering for ARIN subnets, but as something simpler to start with I would like to be able to filter for any networks that my provider broadcasts, plus any customers that announce through them. I want to be able to do so even if the provider or their customers are prepending AS numbers.
From what I can tell, there is no mechanism in the regex to say "this as (in any multiple) plus any multiple of the next AS hop"
Because of how my two providers are set up, I don't want to stop prepending from forcing me through provider A when the destination is one hop through provider B, even if they prepend. Obviously there are circumstances in which said destination might prepend in advance of maintenance to engineer traffic in over another link, but that is more of a remote situation.
Without maintaining a specific list of next-hop peers for each upstream provider (which would be unreasonable) I can't find a decent way to do it. I know Cisco IOS has something to this effect, am I missing the JunOS version somehow?