Merit Network
Can't find what you're looking for? Search the Mail Archives.
  About Merit   Services   Network   Resources & Support   Network Research   News   Events   Home

Discussion Communities: Merit Network Email List Archives

North American Network Operators Group

Date Prev | Date Next | Date Index | Thread Index | Author Index | Historical

Route Programming (was Re: bgp route-map)

  • From: Leo Bicknell
  • Date: Mon Aug 25 16:07:02 2003

This reminds me of something I've wanted to bring up to the community
for a long time.  I'd like to see a "route programming language" that
gets implemented in a multi-vendor way.  No, I'm not talking about like
RPSL, but rather, let me give some examples:

1) Pull out session details via "variables":

      route-statement foo {
          if ($route has community(1234:$session{'asn'})) {
              set_asprepend($route, "1234 1234")
          }
      }

2) Check for the route in other routing tables:

      route-statement bar {
          if ($route in ospf) {
             set_localpref($route, 10)
          }
          if ($route in bgp && $route has communty(1234:666)) 
             drop($route)
          }
          set_localpref($route, 100)
      }

3) Scan other route tables:

      route-statement baz {
          if ($route supernet-in bgp) {
              drop($route);
          }
      }

4) Other weird stuff:

      route-statement hack {
          if ($route = "1.2.3.0/24") {
              announce_route("1.2.3.10/32", "192.168.1.1")
          }
      }

Basically all the data on the box would be made available via global
variables (eg, session IP, session ASN, bgp version, etc), and all
dynamic data would have interfaces (eg scan other routing tables,
acl's, etc).  You'd write a "function" which would get passed a
route object, and act on it.  Functions could further pass that
route on calling other functions (allowing you to create common
policy).

Sadly, while I can think of many cool things you could do, I know
little about how to really design a languge.  I also have no idea
how bad other people want this, how hard it would be to get vendors
to implement, etc.  Feel free to add your support, or call me a
crackpot.

-- 
       Leo Bicknell - bicknell@ufp.org - CCIE 3440
        PGP keys at http://www.ufp.org/~bicknell/
Read TMBG List - tmbg-list-request@tmbg.org, www.tmbg.org

Attachment: pgp00054.pgp
Description: PGP signature




Discussion Communities


About Merit | Services | Network | Resources & Support | Network Research
News | Events | Contact | Site Map | Merit Network Home


Merit Network, Inc.