home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1997 December / Internet_Info_CD-ROM_Walnut_Creek_December_1997.iso / drafts / draft_ietf_q_t / draft-ietf-rps-rpsl-00.txt < prev    next >
Text File  |  1996-11-26  |  75KB  |  2,002 lines

  1.  
  2. Internet Draft                                           Cengiz Alaettinoglu
  3. Expires  May 25, 1997                                                USC/ISI
  4. draft-ietf-rps-rpsl-00.txt                                        Tony Bates
  5.                                                                Cisco Systems
  6.                                                                 Elise Gerich
  7.                                                              At Home Network
  8.                                                            Daniel Karrenberg
  9.                                                                         RIPE
  10.                                                              Marten Terpstra
  11.                                                                 Bay Networks
  12.                                                            Curtis Villamizar
  13.                                                                          ANS
  14.                                                            November 25, 1996
  15.  
  16.  
  17.  
  18.                 Routing Policy Specification Language (RPSL)
  19.  
  20.  
  21.  
  22.  
  23. Status of this Memo
  24.  
  25.  
  26. This  Internet  Draft   is  the  reference   document  for  Routing   Policy
  27. Specification Language  (RPSL). RPSL  allows  the specification  of  routing
  28. policies at high  level; for example  at the  Autonomous System (AS)  level.
  29. At the  same time,  policies  can be  specified  with sufficient  detail  in
  30. RPSL so that  low level router  configurations can be  generated from  them.
  31. RPSL is extensible; new routing protocols  and new protocol features can  be
  32. introduced at any time.
  33.  
  34. This document is an Internet Draft, and can be found as draft-ietf-rps-rpsl-
  35. 00.txt in any  standard internet  drafts repository.    Internet Drafts  are
  36. working documents of the Internet Engineering Task Force (IETF), its  Areas,
  37. and its Working Groups.  Note that other groups may also distribute  working
  38. documents as Internet Drafts.
  39.  
  40. Internet Drafts  are draft  documents valid  for a  maximum of  six  months.
  41. Internet Drafts may be  updated, replaced, or  obsoleted by other  documents
  42. at any time.   It  is not appropriate  to use Internet  Drafts as  reference
  43. material, or to cite  them other than  as a ``working  draft'' or ``work  in
  44. progress.''
  45.  
  46. Please check  the I-D  abstract  listing contained  in each  Internet  Draft
  47. directory to learn the current status of this or any other Internet Draft.
  48. Internet Draft                     RPSL                    November 25, 1996
  49.  
  50. 1 Introduction
  51.  
  52.  
  53. This  Internet  Draft   is  the  reference   document  for  Routing   Policy
  54. Specification Language  (RPSL). RPSL  allows  the specification  of  routing
  55. policies at high  level; for example  at the  Autonomous System (AS)  level.
  56. At the  same time,  policies  can be  specified  with sufficient  detail  in
  57. RPSL so that  low level router  configurations can be  generated from  them.
  58. RPSL is extensible; new routing protocols  and new protocol features can  be
  59. introduced at any time.
  60.  
  61. RIPE-81 [4] was the first language  deployed in the Internet for  specifying
  62. routing policies.     It  was later  replaced  by  another  language  called
  63. RIPE-181 [3].   There  are limitations  in the  types of  policies that  can
  64. be described by  RIPE-181 and  the limitations became  evident when  several
  65. enterprises tried to use RIPE-181 to describe their routing policies.   RPSL
  66. addresses RIPE-181's limitations.
  67.  
  68. RPSL is  object oriented;  that is,  objects  contain pieces  of policy  and
  69. administrative information.   These objects are  registered in the  Internet
  70. Routing Registry (IRR) by  the authorized organizations.   The  registration
  71. process is not within the scope of this document.  Please refer to [1].
  72.  
  73. In the following sections,  we present the classes  that are used to  define
  74. various policy  and  administrative  objects.    The  mntner  class  defines
  75. entities authorized to add, delete and modify a set of objects.  The  person
  76. class describes technical and administrative contact personnel.   Autonomous
  77. systems (ASes) are specified using the aut-num class.  Routes are  specified
  78. using the  route class.    Sets  of ASes  and routes  can be  defined  using
  79. the as-set  and  route-set classes.     The dictionary  class  provides  the
  80. extensibility to  the language.    The  inet-rtr class  is used  to  specify
  81. routers.
  82.  
  83. The reader of this  document is expected  to be familiar  with BGP [12]  and
  84. interAS routing policies.  This document  is not a tutorial on RPSL, nor  on
  85. policy routing.   Please refer  to applications document  for a tutorial  on
  86. RPSL[2].
  87.  
  88.  
  89. 2 RPSL Names, Reserved Words, and Representation
  90.  
  91.  
  92. Each class has a set of attributes which store a piece of information  about
  93. the objects of  the class.    Attributes can be  mandatory or  optional:   A
  94. mandatory attribute has to be defined for all objects of the class; optional
  95. attributes can  be skipped.    Attributes  can also  be single  or  multiple
  96. valued.  Each object is uniquely identified by a set of attributes, referred
  97. to as the class ``key''.
  98.  
  99. The value of an attribute has a type.   The following types are most  widely
  100.  
  101.  
  102.  
  103. Alaettinoglu et.  al.             Expires  May 25, 1997             [Page 2]
  104. Internet Draft                     RPSL                    November 25, 1996
  105.  
  106. used:
  107.  
  108.  
  109. <object-name>Many  objects in RPSL  have a name.   An  <object-name> is made
  110.     up of letters, digits, the character underscore ``_'', and  the character
  111.     hyphen ``-''; the first  character of a name must  be a letter, and  the
  112.     last character of a name must  be a letter or a  digit.  Names are  case
  113.     insensitive.  The following words are reserved by RPSL, and they can not
  114.     be used as names:
  115.  
  116.  
  117.           any as-any rs-any peeras
  118.           and or not
  119.           atomic from to at action accept announce networks
  120.  
  121.  
  122.     Names starting with  certain prefixes  are reserved  for certain  object
  123.     types.   Names  starting with  ``as-'' are  reserved for  as set  names.
  124.     Names starting with ``rs-'' are reserved for route set names.
  125.  
  126. <as-number>An  AS number x is represented as  the string ``ASx''.  That  is,
  127.     the AS 226 is represented as AS226.
  128.  
  129. <ip-address>An IP  address is represented as a sequence of four integers  in
  130.     the range from  0 to  255 separated  by the character  dot ``.''.    For
  131.     example, 128.9.128.5 represents a valid IP address.
  132.  
  133. <address-prefix>An  address prefix is represented as an IP address  followed
  134.     by the character slash  ``/'' followed by an  integer in the range  from
  135.     0 to 32.   The  following are valid  address prefixes:   128.9.128.5/32,
  136.     128.9.0.0/16, 0.0.0.0/0; and the following address prefixes are invalid:
  137.     0/0, 128.9/16 since 0 or 128.9 are not strings containing four integers.
  138.  
  139. <date>A date  is represented as an eight digit integer of the form  YYYYMMDD
  140.     where YYYY represents the year, MM represents the month of the year  (01
  141.     through 12), and  DD represents the  day of the  month (01 through  31).
  142.     For example, June 24, 1996 is represented as 19960624.
  143.  
  144. <email-address>is as described in RFC-822[5].
  145.  
  146. <dns-name>is as described in RFC-1034[10].
  147.  
  148. <person>is  either  a  full  name  of  a   person  or  a  uniquely  assigned
  149.     NIC-handle.  Its syntax has the following form:
  150.  
  151.  
  152.           <firstname> [<initials>] <lastname>
  153.         | <nic-handle>
  154.  
  155.            E.g.
  156.               John E Doe
  157.  
  158.  
  159. Alaettinoglu et. al.             Expires  May 25, 1997              [Page 3]
  160. Internet Draft                     RPSL                    November 25, 1996
  161.  
  162.               JED31
  163.  
  164.  
  165.     A NIC handle is an identifier used by INTERNIC to unambiguously refer to
  166.     people.
  167.  
  168. <free-form>is a sequence of ASCII characters.
  169.  
  170. <X-object-name>is  a name of  an object of  type X. That  is <mntner-object-
  171.     name> is a name of an mntner object.
  172.  
  173. <registry-name>is  a name of an  IRR registry.   The routing registries  are
  174.     listed in Appendix A.
  175.  
  176.  
  177. A value of an attribute may also be a  lists of one of these types.  A  list
  178. is represented by separating the list members by commas ``,''.  For example,
  179. ``AS1, AS2, AS3, AS4'' is a list of AS numbers.  Note that being list valued
  180. and being multiple valued are orthogonal.   A multiple valued attribute  has
  181. more than one  value each of  which may or  may not be  a list depending  on
  182. the attribute.  On the other hand a single valued attribute may have  a list
  183. value.
  184.  
  185. An RPSL object is textually represented as a list of attribute-value  pairs.
  186. Each attribute-value pair is written on a separate line.  The attribute name
  187. starts at column 0, followed by character  ``:''  and followed by the  value
  188. of the attribute.   The object's  representation ends when  a blank line  is
  189. encountered.   An attribute's  value can be  split over  multiple lines,  by
  190. starting the continuation lines with a white-space (`` '' or tab) character.
  191. The order of  attribute-value pairs  is significant,  hence  attribute-value
  192. pairs can not be reordered.
  193.  
  194. An object's description may contain comments.  A comment can be anywhere  in
  195. an object's definition except  for column 0,  it starts  at the first  ``#''
  196. character on a  line and ends  at the  first end-of-line character.    White
  197. space characters can be used to improve readability.
  198.  
  199.  
  200. 3 mntner Class
  201.  
  202.  
  203. The mntner class defines  entities that can create,  delete and update  RPSL
  204. objects.  A provider, before he/she can create any RPSL object, first  needs
  205. to create a mntner object.  The attributes of the mntner class are  shown in
  206. Figure 1.  A more complete description of mntner class can be found  in [7].
  207. Here, we summarize the mntner class for completeness.
  208.  
  209. The mntner attribute is mandatory and is the class key attribute.  Its value
  210. is an RPSL name.  The auth attribute specifies the scheme that will  be used
  211. to identify and authenticate update requests  from this maintainer.  It  has
  212.  
  213.  
  214.  
  215. Alaettinoglu et.  al.             Expires  May 25, 1997             [Page 4]
  216. Internet Draft                     RPSL                    November 25, 1996
  217.  
  218.  
  219.   Attribute  Value                    Type
  220.   mntner     <object-name>            mandatory, single-valued, class key
  221.   descr      <free-form>              mandatory, single-valued
  222.   auth       see description in text  mandatory, multi-valued
  223.   upd-to     <email-address>          mandatory, multi-valued
  224.   mnt-nfy    <email-address>          optional, multi-valued
  225.   tech-c     <person>                 mandatory, multi-valued
  226.   admin-c    <person>                 mandatory, multi-valued
  227.   remarks    <free-form>              optional, multi-valued
  228.   notify     <email-address>          optional, multi-valued
  229.   mnt-by     <mntner-object-name>     mandatory, multi-valued
  230.   changed    <email-address> <date>   mandatory, multi-valued
  231.   source     <registry-name>          mandatory, single-valued
  232.  
  233.  
  234.                      Figure 1:  mntner Class Attributes
  235.  
  236.  
  237. the following syntax:
  238.  
  239.  
  240.    auth: <scheme-id> <auth-info>
  241.  
  242.    E.g.
  243.           auth: NONE
  244.           auth: CRYPT-PW dhjsdfhruewf
  245.           auth: MAIL-FROM .*@ripe\.net
  246.  
  247.  
  248. The <scheme-id>'s currently defined are:  NONE, MAIL-FROM and CRYPT-PW.  The
  249. <auth-info> is additional information required  by a particular scheme:   in
  250. the case  of MAIL-FROM,  it is  a regular  expression matching  valid  email
  251. addresses; in the case of CRYPT-PW, it  is a password in UNIX crypt  format.
  252. If multiple auth attributes are specified, an update request satisfying  any
  253. one of them is authenticated to be from the maintainer.
  254.  
  255. The upd-to  attribute  is an  email  address.    On an  unauthorized  update
  256. attempt of an object  maintained by this maintainer,  an email message  will
  257. be sent to this  address.   The mnt-nfy attribute  is an email  address.   A
  258. notification message will  be forwarded  to this email  address whenever  an
  259. object maintained by this maintainer is added, changed or deleted.
  260.  
  261. The descr attribute is a short, free-form textual description of the object.
  262. The tech-c attribute  is a technical  contact person.   This  is someone  to
  263. be contacted for technical problems such  as misconfiguration.  The  admin-c
  264. attribute is an administrative contact person.   The remarks attribute is  a
  265. free text explanation or  clarification.  The  notify attribute is an  email
  266. address to which  notifications of changes  to this object  should be  sent.
  267. The mnt-by attribute is a mntner object name.  The authorization for changes
  268.  
  269.  
  270.  
  271. Alaettinoglu et.  al.             Expires  May 25, 1997             [Page 5]
  272. Internet Draft                     RPSL                    November 25, 1996
  273.  
  274. to this object is governed by that maintainer object.  The changed attribute
  275. documents who last changed this object, and when this change was made.   Its
  276. syntax has the following form:
  277.  
  278.  
  279.    changed: <email-address> <YYYYMMDD>
  280.  
  281.    E.g.
  282.    changed: johndoe@terabit-labs.nn 19900401
  283.  
  284.  
  285. The  <email-address>  identifies  the  person  who  made  the  last  change.
  286. <YYYYMMDD> is the date of  the change.   The source attribute specifies  the
  287. registry where the object is registered.
  288.  
  289. The descr,  tech-c, admin-c,  remarks, notify,  mnt-by,  changed and  source
  290. attributes are attributes of all  RPSL classes.   We do not further  discuss
  291. them in other sections.
  292.  
  293.  
  294. 4 person Class
  295.  
  296.  
  297. A person class is used to describe information about people.  Even though it
  298. does not describe routing  policy, we still describe  it here briefly  since
  299. many policy objects make reference  to person objects.   The details of  the
  300. person class can be found in Reference [9].
  301.  
  302. The attributes  of the  person class  are shown  in Figure  2.   The  person
  303. attribute is  the full  name  of the  person.    The  phone and  the  fax-no
  304. attributes have the following syntax:
  305.  
  306.  
  307.       phone: +<country-code> <city> <subscriber> [ext. <extension>]
  308.  
  309.    E.g.:
  310.       phone: +31 20 12334676
  311.       phone: +44 123 987654 ext. 4711
  312.  
  313.  
  314.  
  315.  
  316. 5 route Class
  317.  
  318.  
  319. Each interAS route originated  by an AS is  specified using a route  object.
  320. The attributes  of the  route  class are  shown  in Figure  3.    The  route
  321. attribute is the  address prefix of  the route and  the origin attribute  is
  322. the AS number of the AS that  originates the route into the interAS  routing
  323. system.  The route and origin attribute pair is the class key.
  324.  
  325.  
  326.  
  327. Alaettinoglu et.  al.             Expires  May 25, 1997             [Page 6]
  328. Internet Draft                     RPSL                    November 25, 1996
  329.  
  330.  
  331.   Attribute  Value                    Type
  332.   person     <person>                 mandatory, single-valued, class key
  333.   address    <free-form>              mandatory, multi-valued
  334.   phone      see description in text  mandatory, multi-valued
  335.   fax-no     same as phone            optional, multi-valued
  336.   e-mail     <email-address>          mandatory, multi-valued
  337.   nic-hdl    see description in text  optional, single-valued
  338.  
  339.  
  340.                      Figure 2:  person Class Attributes
  341.  
  342.  
  343.  
  344. Attribute          Value                                  Type
  345. route              <address-prefix>        mandatory, single-valued, class key
  346. origin             <as-number>             mandatory, single-valued, class key
  347. withdrawn          <date>                  optional, single-valued
  348. member-of          <route-set-object-name> optional, single-valued Section 6 
  349. inject-at          see Section 9           optional, multi-valued
  350. aggregate-by       see Section 9           optional, single-valued
  351. export-components  see Section 9           optional, single-valued
  352. holes              see Section 9           optional, single-valued
  353.  
  354.  
  355.                      Figure 3:  route Class Attributes
  356.  
  357.  
  358.  
  359. The Figure 4 shows examples of four route  objects.  Note that the last  two
  360. route objects have the same address  prefix, namely 128.8.0.0/16.   However,
  361. they are different route objects since they are originated by different ASes
  362. (i.e. they have different keys).
  363.  
  364.  
  365.    route:128.9.0.0/16
  366.    origin: AS226
  367.  
  368.    route: 128.99.0.0/16
  369.    origin: AS226
  370.  
  371.    route: 128.8.0.0/16
  372.    origin: AS1
  373.  
  374.    route: 128.8.0.0/16
  375.    origin: AS2
  376.    withdrawn: 19960624
  377.  
  378.  
  379.                           Figure 4:  Route Objects
  380.  
  381.  
  382.  
  383. Alaettinoglu et.  al.             Expires  May 25, 1997             [Page 7]
  384. Internet Draft                     RPSL                    November 25, 1996
  385.  
  386. The withdrawn attribute,  if present,  signifies that the  originator AS  no
  387. longer originates this address prefix in the Internet.  Its value is a  date
  388. indicating the date of withdrawal.   In Figure 4,  the last route object  is
  389. withdrawn (i.e. no longer originated by AS2) on June 24, 1996.
  390.  
  391.  
  392. 6 Set Classes
  393.  
  394.  
  395. To specify policies,  it is often  useful to define  sets of  objects.   For
  396. this purpose we  define two  classes route-set and  as-set.   These  classes
  397. define a named set.   The members of these  sets can be specified by  either
  398. explicitly listing them  in the set  object's definition,  or implicitly  by
  399. having route and aut-num objects refer to the set name in their definitions,
  400. or a combination of both methods.
  401.  
  402.  
  403. 6.1 route-set Class
  404.  
  405.  
  406. The attributes of the route-set class are shown in Figure 5.  The  route-set
  407. attribute defines the name of the set.  It is an RPSL name that  starts with
  408. ``rs-''.  The members attribute lists the  members of the set.  The  members
  409. attribute is a list of address prefixes or other route-set names.
  410.  
  411.  
  412.  
  413. Attribute            Value                          Type
  414. route-set            <object-name>      mandatory, single-valued, class key
  415. members              list of <address-prefixes>     optional, single-valued
  416. members-by-referral  list of <mntner-object-names>  optional, single-valued
  417.  
  418.                    Figure 5:  route-set Class Attributes
  419.  
  420.  
  421.  
  422. Figure 6 presents some example route-set  objects.  The set rs-foo  contains
  423. two address prefixes, namely 128.9.0.0/16 and 128.9.0.0/16.  The set  rs-bar
  424. contains the members of the set rs-foo and the address prefix  128.7.0.0/16.
  425. The set rs-empty contains no members.
  426.  
  427. The members-by-referral  attribute is  a  list of  maintainer names  or  the
  428. keyword ANY.  If  this  attribute  is used,  the  route  set  also  includes
  429. those address prefixes whose  route objects are registered  by one of  these
  430. maintainers and  whose  member-of  attribute  refers to  the  name  of  this
  431. route set.     If the  value  of  a members-by-referral  attribute  is  ANY,
  432. any route object  referring to  the route  set name  is a  member.   If  the
  433. members-by-referral attribute is missing,  only the address prefixes  listed
  434. in the members attribute are members of the set.
  435.  
  436. Figure 7 presents example route-set objects that use the members-by-referral
  437.  
  438.  
  439. Alaettinoglu et.  al.             Expires  May 25, 1997             [Page 8]
  440. Internet Draft                     RPSL                    November 25, 1996
  441.  
  442.  
  443.    route-set: rs-foo
  444.    members: 128.9.0.0/16, 128.9.0.0/24
  445.  
  446.    route-set: rs-bar
  447.    members: 128.7.0.0/16, rs-foo
  448.  
  449.    route-set: rs-empty
  450.  
  451.  
  452.                         Figure 6:  route-set Objects
  453.  
  454.  
  455.    route-set: rs-foo
  456.    members-by-referral: MNTR-ME, MNTR-YOU
  457.  
  458.    route-set: rs-bar
  459.    members: 128.7.0.0/16
  460.    members-by-referral: MNTR-YOU
  461.  
  462.    route: 128.9.0.0/16
  463.    origin: AS1
  464.    member-of: rs-foo
  465.    mnt-by: MNTR-ME
  466.  
  467.    route: 128.8.0.0/16
  468.    origin: AS2
  469.    member-of: rs-foo, rs-bar
  470.    mnt-by: MNTR-YOU
  471.  
  472.  
  473.                        Figure 7:  route-set objects.
  474.  
  475. attribute.     The  set  rs-foo   contains  two  address  prefixes,   namely
  476. 128.8.0.0/16 and 128.9.0.0/16 since the  route objects for 128.8.0.0/16  and
  477. 128.9.0.0/16 refer to the set name rs-foo in their member-of attribute.  The
  478. set rs-bar contains the address prefixes 128.7.0.0/16 and 128.8.0.0/16.  The
  479. route 128.7.0.0/16 is explicitly listed in the members attribute of  rs-bar,
  480. and the route object for  128.8.0.0/16 refer to the  set name rs-bar in  its
  481. member-of attribute.
  482.  
  483.  
  484.  
  485. 6.2 as-set Class
  486.  
  487.  
  488. The attributes  of the  as-set class  are shown  in Figure  8.   The  as-set
  489. attribute defines the name of the set.  It is an RPSL name that  starts with
  490. ``as-''.  The members attribute lists the  members of the set.  The  members
  491. attribute is a list of AS numbers, or other as-set names.
  492.  
  493.  
  494.  
  495. Alaettinoglu et.  al.             Expires  May 25, 1997             [Page 9]
  496. Internet Draft                     RPSL                    November 25, 1996
  497.  
  498.  
  499. Attribute            Value                          Type
  500. as-set               <object-name>      mandatory, single-valued, class key
  501. members              list of <address-prefixes>     optional, single-valued
  502. members-by-referral  list of <mntner-object-names>  optional, single-valued
  503.  
  504.  
  505.                      Figure 8:  as-set Class Attributes
  506.  
  507.  
  508.  
  509. Figure 9 presents two  as-set objects.   The set  as-foo contains two  ASes,
  510. namely AS1 and AS2.  The set  as-bar contains the members of the set  as-foo
  511. and AS3, that is it contains AS1, AS2, AS3.
  512.  
  513.    as-set: as-foo                      as-set: as-bar
  514.    members: AS1, AS2                   members: AS3, as-foo
  515.  
  516.  
  517.                          Figure 9:  as-set objects.
  518.  
  519.  
  520. The members-by-referral  attribute is  a  list of  maintainer names  or  the
  521. keyword ANY. If this attribute is used, the AS set also includes those  ASes
  522. whose aut-num objects are registered by  one of these maintainers and  whose
  523. member-of attribute refers to the name  of this AS set.   If the value of  a
  524. members-by-referral attribute is ANY, any AS object referring to the AS  set
  525. is a member of the  set.  If  the members-by-referral attribute is  missing,
  526. only the ASes listed in the members attribute are members of the set.
  527.  
  528.  
  529.    as-set: as-foo
  530.    members: AS1, AS2
  531.    members-by-referral: MNTR-ME
  532.  
  533.    aut-num: AS3                          aut-num: AS4
  534.    member-of: as-foo                     member-of: as-foo
  535.    mnt-by: MNTR-ME                       mnt-by: MNTR-OTHER
  536.  
  537.  
  538.                         Figure 10:  as-set objects.
  539.  
  540. Figure 10  presents  an example  as-set  object that  uses  the  members-by-
  541. referral attribute.  The set as-foo contains AS1, AS2 and AS3.  AS4 is not a
  542. member of the set as-foo even  though the aut-num object references  as-foo.
  543. This is because MNTR-OTHER is not listed in the as-foo's members-by-referral
  544. attribute.
  545.  
  546.  
  547.  
  548.  
  549.  
  550.  
  551. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 10]
  552. Internet Draft                     RPSL                    November 25, 1996
  553.  
  554. 6.3 Predefined Set Objects
  555.  
  556.  
  557. In a  context that  expects a  route set  (e.g.   members  attribute of  the
  558. route-set class),  an AS  number  ASx defines  the set  of routes  that  are
  559. originated by ASx;  and an as-set AS-X  defines the set  of routes that  are
  560. originated by the ASes in AS-X. A route p is said to be originated by ASx if
  561. there is a route object for p with ASx as the value of the origin attribute.
  562. For example, in Figure 11,  the route set rs-special contains  128.9.0.0/16,
  563. routes of AS1 and AS2, and routes of the ASes in AS set AS-FOO.
  564.  
  565.  
  566.    route-set: rs-special
  567.    members: 128.9.0.0/16, AS1, AS2, AS-FOO
  568.  
  569.  
  570.           Figure 11:  Use of AS numbers and AS sets in route sets.
  571.  
  572. The keyword rs-any  defines the  set of all  routes registered  in IRR.  The
  573. keyword as-any defines the set of all ASes registered in IRR.
  574.  
  575.  
  576. 6.4 Splitting the set name space
  577.  
  578.  
  579. Set names can be hierarchical.  A hierarchical set name is a sequence of set
  580. names and AS numbers separated by colons ``:''.  For example, the  following
  581. names are  valid:   AS1:AS-CUSTOMERS, AS1:RS-EXCEPTIONS,  AS1:RS-EXPORT:AS2,
  582. RS-EXCEPTIONS:RS-BOGUS. All set names in an hierarchical as-set name  should
  583. start with ``as-'';  and all  set names  in an  hierarchical route-set  name
  584. should start with ``rs-''.
  585.  
  586. A set object with name X1:...:Xn-1:Xn can only be created by the  maintainer
  587. of the object with name  X1:...:Xn-1.  That is,  only the maintainer of  AS1
  588. can create a set with name AS1:AS-FOO; and only the maintainer of AS1:AS-FOO
  589. can create a set with name AS1:AS-FOO:AS-BAR.
  590.  
  591.  
  592. 7 aut-num Class
  593.  
  594.  
  595. ASes are specified using the aut-num class.   The attributes of the  aut-num
  596. class are shown in  Figure 12.   The value of the  aut-num attribute is  the
  597. AS number of  the AS described  by this object.   The  as-name attribute  is
  598. a symbolic name  (in RPSL name  syntax) of  the AS. The  import, export  and
  599. default routing policies  of the AS  are specified using  as-in, as-out  and
  600. default attributes respectively.   igp-to-egp and egp-to-igp attributes  are
  601. used to specify how routes are injected to and from the IGP protocol.
  602.  
  603.  
  604.  
  605.  
  606.  
  607. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 11]
  608. Internet Draft                     RPSL                    November 25, 1996
  609.  
  610.  
  611.    Attribute   Value                 Type
  612.    aut-num     <as-number>           mandatory, single-valued, class key
  613.    as-name     <object-name>         mandatory, single-valued
  614.    member-of   <as-set-object-name>  optional, single-valued
  615.    as-in       see Section 7.1       optional, multi valued
  616.    as-out      see Section 7.2       optional, multi valued
  617.    default     see Section 7.3       optional, multi valued
  618.    igp-to-egp  see Section 7.4       optional, multi valued
  619.    egp-to-igp  see Section 7.4       optional, multi valued
  620.  
  621.  
  622.                     Figure 12:  aut-num Class Attributes
  623.  
  624.  
  625. 7.1 as-in Attribute:  Import Policy Specification
  626.  
  627.  
  628.  
  629.  
  630.      ----------------------                   ----------------------
  631.      |            7.7.7.1 |-------|   |-------| 7.7.7.2            |
  632.      |                    |     ========      |                    |
  633.      |   AS1              |      EX1  |-------| 7.7.7.3     AS2    |
  634.      |                    |                   |                    |
  635.      |            9.9.9.1 |------       ------| 9.9.9.2            |
  636.      ----------------------     |       |     ----------------------
  637.                                ===========
  638.                                    |    EX2
  639.      ----------------------        |
  640.      |            9.9.9.3 |---------
  641.      |                    |
  642.      |   AS3              |
  643.      ----------------------
  644.  
  645.  
  646. Figure 13:  Example topology  consisting of three ASes,  AS1, AS2, and  AS3;
  647. two exchange points, EX1 and EX2; and six routers.
  648.  
  649.  
  650. A typical interconnection of ASes  is shown in Figure 13.   In this  example
  651. topology, there are  three ASes,  AS1, AS2,  and AS3;  two exchange  points,
  652. EX1 and  EX2; and  six routers.    Routers connected  to  the same  exchange
  653. point peer with each  other, i.e. open a  connection for exchanging  routing
  654. information.  Each router would export a subset of the routes it has  to its
  655. peer routers.  Peer routers would import a subset of these routes.  A router
  656. while importing routes would  set some route attributes.   For example,  AS1
  657. can assign higher  preference values to  the routes it  imports from AS2  so
  658. that it prefers AS2  over AS3.   While exporting routes,  a router may  also
  659. set some route attributes in order  to affect route selection by its  peers.
  660. For example, AS2 may set the MULTI-EXIT-DISCRIMINATOR BGP attribute so  that
  661.  
  662.  
  663. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 12]
  664. Internet Draft                     RPSL                    November 25, 1996
  665.  
  666. AS1 prefers to use the router 9.9.9.2.  Most interAS policies are  specified
  667. by specifying what route  subsets can be imported  or exported, and how  the
  668. various route attributes are set and used.
  669.  
  670. In RPSL, an import policy is divided  into import policy expressions.   Each
  671. import policy expression is specified using  an as-in attribute.  The  as-in
  672. attribute has the following syntax:
  673.  
  674.  
  675.     as-in: from <peering-1> [action <action-1>]
  676.            . . .
  677.            from <peering-N> [action <action-N>]
  678.            accept <filter>
  679.  
  680.  
  681. The action specification is optional.   The semantics  are as follows:   the
  682. set of routes that are matched by <filter> are imported in all the  peerings
  683. specified; while importing routes at  <peering-M> <action-M> is executed  to
  684. set the attributes.
  685.  
  686.  
  687.   E.g.
  688.     aut-num: AS1
  689.     as-in: from AS2 action pref = 1 accept { 128.9.0.0/16 }
  690.  
  691.  
  692. This example states that  the route 128.9.0.0/16 is  accepted from AS2  with
  693. preference 1.  In the next  few subsections, we will describe how  peerings,
  694. actions and filters are specified.
  695.  
  696.  
  697. 7.1.1 Peering Specification
  698.  
  699.  
  700. Our example above  used an  AS number  to specify  peerings.   The  peerings
  701. can be  specified at  different granularities.    The  syntax of  a  peering
  702. specification is as follows:
  703.  
  704.  
  705.      <peer-as> [<peer-router>] [at <local-router>]
  706.    | <as-set> [at <local-router>]
  707.  
  708.  
  709. where  <local-router>  and  <peer-router>  are  IP  addresses  of   routers,
  710. <peer-as> is an AS number, and <as-set> is  an AS set name.  <peer-as>  must
  711. be the AS number  of <peer-router>.   Both <local-router> and  <peer-router>
  712. are optional.    We  first  describe the  semantics  using the  first  form.
  713. If both  <local-router>  and  <peer-router>  are  specified,   this  peering
  714. specification identifies only  the peering between  these two routers.    If
  715. only <local-router>  is  specified, this  peering  specification  identifies
  716. all the  peerings between  <local-router> and  any of  its peer  routers  in
  717.  
  718.  
  719. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 13]
  720. Internet Draft                     RPSL                    November 25, 1996
  721.  
  722. <peer-as>.  If only  <peer-router> is specified, this peering  specification
  723. identifies all  the  peerings  between  any  router  in  the  local  AS  and
  724. <peer-router>.   If neither <local-router>  nor <peer-router> is  specified,
  725. this peering specification identifies all the peerings between any router in
  726. the local AS and any router in <peer-as>.  If the <as-set> form is used, the
  727. peering specification identifies all the peerings between <local-router> and
  728. any of its peer routers in one of  the ASes in <as-set>.  If  <local-router>
  729. is not  specified, the  peering specification  identifies all  the  peerings
  730. between any router in the local AS and any of its peer routers in one of the
  731. ASes in <as-set>.
  732.  
  733. We next give examples.   Consider  the topology of Figure  13 where AS1  has
  734. two routers 7.7.7.1 and 9.9.9.1; AS2 has three routers 7.7.7.2, 7.7.7.3  and
  735. 9.9.9.2; AS3 has one router 9.9.9.3.  7.7.7.1, 7.7.7.2 and 7.7.7.3 peer with
  736. each other; 9.9.9.1, 9.9.9.2 and 9.9.9.3  peer with each other.  In  example
  737. (1) below 7.7.7.1 imports 128.9.0.0/16 from 7.7.7.2.
  738.  
  739.  
  740.   (1) aut-num: AS1
  741.       as-in: from AS2 7.7.7.2 at 7.7.7.1 accept { 128.9.0.0/16 }
  742.  
  743.   (2) aut-num: AS1
  744.       as-in: from AS2         at 7.7.7.1 accept { 128.9.0.0/16 }
  745.  
  746.   (3) aut-num: AS1
  747.       as-in: from AS2                    accept { 128.9.0.0/16 }
  748.  
  749.   (4) as-set: AS-FOO
  750.       members: AS2, AS3
  751.  
  752.       aut-num: AS1
  753.       as-in: from AS-FOO      at 9.9.9.1 accept { 128.9.0.0/16 }
  754.  
  755.   (5) aut-num: AS1
  756.       as-in: from AS-FOO                 accept { 128.9.0.0/16 }
  757.  
  758.   (6) aut-num: AS1
  759.       as-in: from AS2         at 9.9.9.1 accept { 128.9.0.0/16 }
  760.       as-in: from AS3         at 9.9.9.1 accept { 128.9.0.0/16 }
  761.  
  762.   (7) aut-num: AS1
  763.       as-in: from AS2                    accept { 128.9.0.0/16 }
  764.       as-in: from AS3                    accept { 128.9.0.0/16 }
  765.  
  766.  
  767. In example (2), 7.7.7.1 imports 128.9.0.0/16  from 7.7.7.2 and 7.7.7.3.   In
  768. example (3),  7.7.7.1 imports  128.9.0.0/16 from  7.7.7.2 and  7.7.7.3,  and
  769. 9.9.9.1 imports 128.9.0.0/16 from 9.9.9.2.  In example (4), 9.9.9.1  imports
  770. 128.9.0.0/16 from 9.9.9.2  and 9.9.9.3.    In example  (5), 9.9.9.1  imports
  771. 128.9.0.0/16 from 9.9.9.2 and 9.9.9.3, and 7.7.7.1 imports 128.9.0.0/16 from
  772. 7.7.7.2 and 7.7.7.3.  The example (4) and (5) are equivalent to examples (6)
  773.  
  774.  
  775. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 14]
  776. Internet Draft                     RPSL                    November 25, 1996
  777.  
  778. and (7) respectively.
  779.  
  780.  
  781. 7.1.2 Action Specification
  782.  
  783.  
  784. Policy actions in RPSL set or  modify route attributes, such as assigning  a
  785. preference to a  route, adding a  community to the  community attribute,  or
  786. setting the MULTI-EXIT-DISCRIMINATOR  attribute.   Policy  actions can  also
  787. instruct routers to perform special operations, such as route flap  damping.
  788. The routing policy attributes whose values can be modified in policy actions
  789. are specified  in the  RPSL  dictionary.   Please  refer  to Section  8  for
  790. details.
  791.  
  792. It is  possible  to  form  composite policy  actions  by  separating  policy
  793. actions with semicolons in which case the actions are executed in the  order
  794. specified (i.e.  left to right).  For example:
  795.  
  796.  
  797.     aut-num: AS1
  798.     as-in: from AS2
  799.            action pref = 10; med = 0; community .= 10250;
  800.            accept { 128.9.0.0/16 }
  801.  
  802.  
  803. 7.1.3 Filter Specification
  804.  
  805.  
  806. A policy filter  is a  logical expression  which when  applied to  a set  of
  807. routes returns a  subset of these  routes.   We say that  the policy  filter
  808. matches the subset returned.  The  policy filter can match routes using  any
  809. route attribute, such as the destination address prefix (or NLRI),  AS-path,
  810. or community attributes.
  811.  
  812. The following policy filters can be used to select a subset of routes:
  813.  
  814.  
  815. ANY
  816.     The keyword ANY matches all routes.
  817.  
  818. Address-Prefix Set
  819.     This is an explicit list of address prefixes enclosed in  braces '{' and
  820.     '}'.   The policy  filter matches  the set of  routes whose  destination
  821.     address-prefix is in the set.  For example:
  822.  
  823.  
  824.             { 0.0.0.0/0 }
  825.             { 128.9.0.0/16, 128.8.0.0/16, 128.7.128.0/17, 5.0.0.0/8 }
  826.             { }
  827.  
  828.  
  829.  
  830.  
  831. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 15]
  832. Internet Draft                     RPSL                    November 25, 1996
  833.  
  834.     An address prefix can be optionally followed by an operator '^-',  '^+',
  835.     '^n', or  '^n-m'  where n  and  m are  integers.    ^- operator  is  the
  836.     exclusive more specifics operator; it  stands for the more specifics  of
  837.     the address prefix excluding the address prefix itself.  ^+ operator  is
  838.     the inclusive more specifics operator; it stands for the more  specifics
  839.     of the address prefix including the address prefix itself.  ^n operator,
  840.     stands for all  the length  n specifics  of the  address prefix.    ^n-m
  841.     operator, stands  for all  the length  n to  length m  specifics of  the
  842.     address prefix.  For example, the set
  843.  
  844.  
  845.          { 5.0.0.0/8^+, 128.9.0.0/16^-, 30.0.0.0/8^16,  30.0.0.0/8^24-32 }
  846.  
  847.  
  848.     contains all the  more specifics of  5.0.0.0/8 including 5.0.0.0/8,  all
  849.     the more specifics of 128.9.0.0/16 excluding 128.9.0.0/16, all the  more
  850.     specifics of 30.0.0.0/8 which are of length 16 such as 30.9.0.0/16,  and
  851.     all the more specifics of 30.0.0.0/8 which  are of length 24 to 32  such
  852.     as 30.9.9.100/28.
  853.  
  854. Route Set Name
  855.     A route set name matches the set of routes that are members of  the set.
  856.     A route set name may be a name of a route-set object, an AS number, or a
  857.     name of an as-set object (AS numbers and as-set names implicitly  define
  858.     route sets; please see Section 6.3).  For example:
  859.  
  860.  
  861.           aut-num: AS1
  862.           as-in: from AS2 action pref = 1 accept AS2
  863.           as-in: from AS2 action pref = 1 accept AS-FOO
  864.           as-in: from AS2 action pref = 1 accept RS-FOO
  865.  
  866.  
  867.     The keyword PeerAS can be used instead of the AS number of the  peer AS.
  868.     PeerAS is particularly useful when the peering is specified using an  AS
  869.     set.  For example:
  870.  
  871.  
  872.           as-set: AS-FOO
  873.           members: AS2 AS3
  874.  
  875.           aut-num: AS1
  876.           as-in: from AS-FOO action pref = 1 accept PeerAS
  877.  
  878.  
  879.     is same as:
  880.  
  881.  
  882.           aut-num: AS1
  883.           as-in: from AS2 action pref = 1 accept AS2
  884.  
  885.  
  886. Alaettinoglu et. al.             Expires  May 25, 1997             [Page 16]
  887. Internet Draft                     RPSL                    November 25, 1996
  888.  
  889.           as-in: from AS3 action pref = 1 accept AS3
  890.  
  891.  
  892.     A route set  name can also  be followed  by one of  the operators  '^-',
  893.     '^+', '^n' or '^n-m'.   These operators are distributive over the  route
  894.     sets.   For example,  { 5.0.0.0/8,  6.0.0.0/8 }^+ equals  { 5.0.0.0/8^+,
  895.     6.0.0.0/8^+ },  and AS1^-  equals all  the exclusive  more specifics  of
  896.     routes originated by AS1.
  897.  
  898. AS Path Regular Expressions
  899.     An AS-path  regular  expression  can  be used  as  a  policy  filter  by
  900.     enclosing the  expression in  `<' and  `>'.   An  AS-path policy  filter
  901.     matches the set  of routes which  traverses a sequence  of ASes  matched
  902.     by the AS-path regular expression.   A router  can check this using  the
  903.     AS_PATH attribute  in the  Border Gateway Protocol  [12], or  the RD_PATH
  904.     attribute in the Inter-Domain Routing Protocol[11].
  905.  
  906.     AS-path Regular Expressions are POSIX compliant regular expressions over
  907.     the alphabet of AS  numbers.  The  regular expression constructs are  as
  908.     follows:
  909.  
  910.  
  911.     ASN      where ASN is  an AS number.   ASN matches  the AS-path that  is
  912.                  of length 1 and contains the corresponding AS number  (e.g.
  913.                  AS-path regular expression AS1 matches the AS-path ``1'').
  914.  
  915.                  The keyword PeerAS can be used instead of the AS  number of
  916.                  the peer AS.
  917.  
  918.     AS-set   where AS-set is an  AS set name.   AS-set matches the  AS-paths
  919.                  that is matched by one of the ASes in the AS-set.
  920.  
  921.     .        matches the AS-paths matched by any AS number.
  922.  
  923.     [...]    is an AS number  set.  It matches  the AS-paths matched by  the
  924.                  AS numbers listed between the brackets.  The AS  numbers in
  925.                  the set are separated by white space characters.  If  a `-'
  926.                  is used between two AS numbers in this set, all  AS numbers
  927.                  between the two  AS numbers are  included in the  set.   If
  928.                  an as-set name is listed, all AS numbers in the  as-set are
  929.                  included.
  930.  
  931.     [^...]   is a complemented AS number set.  It matches any  AS-path which
  932.                  is not matched by the AS numbers in the set.
  933.  
  934.     ^        Matches the empty string at the beginning of an AS-path.
  935.  
  936.     $        Matches the empty string at the end of an AS-path.
  937.  
  938.  
  939.     We next list the regular expression operators in the decreasing order of
  940.  
  941.  
  942. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 17]
  943. Internet Draft                     RPSL                    November 25, 1996
  944.  
  945.     evaluation.  These operators  are left associative, i.e. performed  left
  946.     to right.
  947.  
  948.  
  949.     Unary postfix operators * + ?
  950.                  For  a  regular expression  A,  A*  matches  zero  or  more
  951.                  occurrences of A; A+ matches one or more occurrences of  A;
  952.                  A? matches zero or one occurrence of A.
  953.  
  954.     Binary catenation operator
  955.                  This  is  an  implicit  operator  and  exists  between  two
  956.                  regular  expressions  A  and  B  when  no  other   explicit
  957.                  operator  is specified.     The resulting  expression  A  B
  958.                  matches an AS-path if A matches some prefix of the  AS-path
  959.                  and B matches the rest of the AS-path.
  960.  
  961.     Binary alternative (or) operator |
  962.                  For a  regular  expressions A  and  B, A  | B  matches  any
  963.                  AS-path that is matched by A or B.
  964.  
  965.  
  966.     Parenthesis can be  used to  override the default  order of  evaluation.
  967.     White spaces can be used to increase readability.
  968.  
  969.     The following are examples of AS-path filters:
  970.  
  971.  
  972.        <AS3>
  973.        <^AS1>
  974.        <AS2$>
  975.        <^AS1 AS2 AS3$>
  976.        <^AS1 .* AS2$>.
  977.  
  978.  
  979.     The first  example matches  any route whose  AS-path contains  AS3,  the
  980.     second matches routes whose AS-path  starts with AS1, the third  matches
  981.     routes whose  AS-path ends  with AS2,  the fourth  matches routes  whose
  982.     AS-path is exactly ``1 2 3'', and the fifth matches routes whose AS-path
  983.     starts with  AS1 and  ends  in AS2  with any  number  of AS  numbers  in
  984.     between.
  985.  
  986.  
  987. Composite Policy Filters
  988.  
  989.  
  990. The following operators (in decreasing order  of evaluation) can be used  to
  991. form composite policy filters:
  992.  
  993.  
  994. NOT Given a policy  filter x, NOT x matches  the set of routes that are  not
  995.     matched by x.  That is it is the negation of policy filter x.
  996.  
  997.  
  998. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 18]
  999. Internet Draft                     RPSL                    November 25, 1996
  1000.  
  1001. AND Given two policy  filters x and y, x  AND y matches the intersection  of
  1002.     the routes that are matched by x and that are matched by y.
  1003.  
  1004. OR Given two policy filters x and y, x OR y matches the union  of the routes
  1005.     that are matched by x and that are matched by y.
  1006.  
  1007.  
  1008. Note that an OR operator can be implicit, that is `x y' is equivalent  to `x
  1009. OR y'.
  1010.  
  1011.  
  1012.   E.g.
  1013.     NOT {128.9.0.0/16, 128.8.0.0/16}
  1014.     AS226 AS227 OR AS228
  1015.     AS226 AND NOT {128.9.0.0/16}
  1016.     AS226 AND {0.0.0.0/0^0-18}
  1017.  
  1018.  
  1019. The first example  matches any route  except 128.9.0.0/16 and  128.8.0.0/16.
  1020. The second example matches the routes of AS226, AS227 and AS228.  The  third
  1021. example matches the routes of AS226 except 128.9.0.0/16.  The fourth example
  1022. matches the routes of AS226 whose length are shorter than 19.
  1023.  
  1024. Policy filters  can  also use  the  values  of other  attributes  (e.g.  the
  1025. community attribute) for  comparison.   The attributes whose  values can  be
  1026. used in policy filters are specified in  the RPSL dictionary.  Please  refer
  1027. to Section 8 for details.
  1028.  
  1029.  
  1030. 7.1.4 Example Policy Expressions
  1031.  
  1032.  
  1033.     aut-num: AS1
  1034.     as-in: from AS2 action pref = 1
  1035.            from AS3 action pref = 2
  1036.            accept AS4
  1037.  
  1038.  
  1039. The above  example states  that  AS4's routes  are  accepted from  AS2  with
  1040. preference 1,  and from AS3  with preference  2 (routes  with lower  integer
  1041. preference values are preferred over  routes with higher integer  preference
  1042. values).
  1043.  
  1044.  
  1045.     aut-num: AS1
  1046.     as-in: from AS2 7.7.7.2 at 7.7.7.1 action pref = 1
  1047.            from AS2                    action pref = 2
  1048.            accept AS4
  1049.  
  1050.  
  1051.  
  1052.  
  1053.  
  1054. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 19]
  1055. Internet Draft                     RPSL                    November 25, 1996
  1056.  
  1057. The above example states that AS4's routes are accepted from AS2 on  peering
  1058. 7.7.7.1-7.7.7.2 with preference 1,  and on any other  peering with AS2  with
  1059. preference 2.
  1060.  
  1061.  
  1062. 7.2 as-out Attribute:  Export Policy Specification
  1063.  
  1064.  
  1065. Similarly,  an  export  policy  expression  is  specified  using  an  as-out
  1066. attribute.  The value of an as-out attribute has the following syntax:
  1067.  
  1068.  
  1069.     as-out: to <peering-1> [action <action-1>]
  1070.             . . .
  1071.             to <peering-N> [action <action-N>]
  1072.             announce <filter>
  1073.  
  1074.  
  1075. The action specification is optional.   The semantics  are as follows:   the
  1076. set of routes that are matched by <filter> are exported in all the  peerings
  1077. specified; while exporting routes at  <peering-M> <action-M> is executed  to
  1078. set the attributes.
  1079.  
  1080.  
  1081.   E.g.
  1082.     aut-num: AS1
  1083.     as-out: to AS2 action med = 5; community .= 70
  1084.             announce AS4
  1085.  
  1086.  
  1087. In this example, AS4's routes are announced to AS2 with the med  attribute's
  1088. value set to 5 and community 70 added to the community list.
  1089.  
  1090. Example:
  1091.  
  1092.  
  1093.     aut-num: AS1
  1094.     as-out: to AS-FOO announce ANY
  1095.  
  1096.  
  1097. In this example,  AS1 announces all  of its routes  to the  ASes in the  set
  1098. AS-FOO.
  1099.  
  1100.  
  1101. 7.3 default Attribute:  Default Policy Specification
  1102.  
  1103.  
  1104. Default routing policies  are specified using  the default attribute.    The
  1105. default attribute has the following syntax:
  1106.  
  1107.  
  1108.  
  1109.  
  1110. Alaettinoglu et. al.             Expires  May 25, 1997             [Page 20]
  1111. Internet Draft                     RPSL                    November 25, 1996
  1112.  
  1113.     default: to <peering> [action <action>] [networks <filter>]
  1114.  
  1115.  
  1116. The <action>  and  <filter> specifications  are  optional.    The  semantics
  1117. are as  follows:   The <peering>  specification indicates  the AS  (and  the
  1118. router if  present)  is being  defaulted  to;  the  <action>  specification,
  1119. if present,  indicates  various  attributes of  defaulting,  for  example  a
  1120. relative preference if  multiple defaults  are specified;  and the  <filter>
  1121. specifications, if present, is a policy filter.  A router chooses a  default
  1122. router from the routes in its routing table that matches this <filter>.
  1123.  
  1124. In the following example, AS1 defaults to AS2 for routing.
  1125.  
  1126.  
  1127.     aut-num: AS1
  1128.     default: to AS2
  1129.  
  1130.  
  1131. In the following example, router 7.7.7.1  in AS1 defaults to router  7.7.7.2
  1132. in AS2.
  1133.  
  1134.  
  1135.     aut-num: AS1
  1136.     default: to AS2 7.7.7.2 at 7.7.7.1
  1137.  
  1138.  
  1139. In the following example, AS1 defaults to AS2 and AS3, but prefers AS2  over
  1140. AS3.
  1141.  
  1142.  
  1143.     aut-num: AS1
  1144.     default: to AS2 action pref = 1
  1145.     default: to AS3 action pref = 2
  1146.  
  1147.  
  1148. In the following example, AS1 defaults  to AS2 and uses 128.9.0.0/16 as  the
  1149. default network.
  1150.  
  1151.  
  1152.     aut-num: AS1
  1153.     default: to AS2 networks { 128.9.0.0/16 }
  1154.  
  1155.  
  1156. 7.4 egp-to-igp and igp-to-egp Attributes:  Injecting Routes
  1157.  
  1158.  
  1159. egp-to-igp attribute specifies how routes  from an interAS routing  protocol
  1160. are injected into an  IGP protocol, and  igp-to-egp attribute specifies  how
  1161. IGP routes are injected into  the interAS routing protocol.   The syntax  of
  1162. the egp-to-igp and igp-to-egp attributes are as follows:
  1163.  
  1164.  
  1165.  
  1166. Alaettinoglu et. al.             Expires  May 25, 1997             [Page 21]
  1167. Internet Draft                     RPSL                    November 25, 1996
  1168.  
  1169.     egp-to-igp: [at <router>] into <protocol>
  1170.                 [action <action>] inject <filter>
  1171.     igp-to-egp: [at <router>] from <protocol>
  1172.                 [action <action>] inject <filter>
  1173.  
  1174.  
  1175. where <router> is an IP address of a router; <protocol> is the IGP  protocol
  1176. name (valid protocol names are defined in the dictionary); and <action>  and
  1177. <filter> are as in the as-in attribute.   The semantics are that the  router
  1178. injects the set of routes matched by <filter> to/from the IGP <protocol> and
  1179. sets the route attributes according to the <action> specified.  If  <router>
  1180. is not specified, all routers in the AS perform the injection.
  1181.  
  1182. In the following example, all interAS routes are injected into RIP.
  1183.  
  1184.  
  1185.         aut-num: AS1
  1186.         as-in: from AS2 accept AS2
  1187.         egp-to-igp: into RIP inject ANY
  1188.  
  1189.  
  1190. In the following example, AS1 accepts AS2's routes including more specifics,
  1191. but does not inject the more specifics into OSPF.
  1192.  
  1193.  
  1194.         aut-num: AS1
  1195.         as-in: from AS2 accept AS2^+
  1196.         egp-to-igp: into OSPF inject AS2
  1197.  
  1198.  
  1199. In the following example,  AS1 injects its static  routes (routes which  are
  1200. members of the set AS1:RS-STATIC-ROUTES) to the interAS routing protocol and
  1201. appends AS1 twice to their as paths.
  1202.  
  1203.  
  1204.         aut-num: AS1
  1205.         igp-to-egp: from STATIC action aspath.prepend(AS1, AS1)
  1206.                                 inject AS1:RS-STATIC-ROUTES
  1207.  
  1208.  
  1209. 7.5 Ambiguity Resolution
  1210.  
  1211.  
  1212. It is possible that the same peering can be covered by more that one peering
  1213. specification in a policy expression.  For example:
  1214.  
  1215.  
  1216.     aut-num: AS1
  1217.     as-in: from AS2 7.7.7.2 at 7.7.7.1 action pref = 2
  1218.            from AS2 7.7.7.2 at 7.7.7.1 action pref = 1
  1219.            accept AS4
  1220.  
  1221.  
  1222. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 22]
  1223. Internet Draft                     RPSL                    November 25, 1996
  1224.  
  1225. This is  not an  error,  though definitely  not  desirable.   To  break  the
  1226. ambiguity, the action  corresponding to the  first peering specification  is
  1227. used.  That is the routes are accepted with preference 2.  We call this rule
  1228. as the specification-order rule.
  1229.  
  1230. Consider the example:
  1231.  
  1232.  
  1233.     aut-num: AS1
  1234.     as-in: from AS2                    action pref = 2
  1235.            from AS2 7.7.7.2 at 7.7.7.1 action pref = 1; dpa = 5
  1236.            accept AS4
  1237.  
  1238.  
  1239. where both peering specifications cover the peering 7.7.7.1-7.7.7.2,  though
  1240. the second one covers  it more specifically.   The specification order  rule
  1241. still applies, and only the action ``pref =  2'' is executed.  In fact,  the
  1242. second peering-action pair has  no use since  the first peering-action  pair
  1243. always covers it.   If the intended policy was  to accept these routes  with
  1244. preference 1 on this particular peering  and with preference 2 in all  other
  1245. peerings, the user should have specified:
  1246.  
  1247.  
  1248.     aut-num: AS1
  1249.     as-in: from AS2 7.7.7.2 at 7.7.7.1 action pref = 1; dpa = 5
  1250.            from AS2                    action pref = 2
  1251.            accept AS4
  1252.  
  1253.  
  1254. It is also possible that more than one policy expression can cover the  same
  1255. set of routes for the same peering.  For example:
  1256.  
  1257.  
  1258.     aut-num: AS1
  1259.     as-in: from AS2 action pref = 2 accept AS4
  1260.     as-in: from AS2 action pref = 1 accept AS4
  1261.  
  1262.  
  1263. In this case, the specification-order  rule is still used.   That is,  AS4's
  1264. routes are  accepted from  AS2  with preference  2.    If the  filters  were
  1265. overlapping but not exactly the same:
  1266.  
  1267.  
  1268.     aut-num: AS1
  1269.     as-in: from AS2 action pref = 2 accept AS4
  1270.     as-in: from AS2 action pref = 1 accept AS4 OR AS5
  1271.  
  1272.  
  1273. the AS4's routes are accepted from  AS2 with preference 2 and however  AS5's
  1274. routes are also accepted, but with preference 1.
  1275.  
  1276.  
  1277.  
  1278. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 23]
  1279. Internet Draft                     RPSL                    November 25, 1996
  1280.  
  1281. We next give  the general specification  order rule for  the benefit of  the
  1282. RPSL implementors.  Consider two policy expressions:
  1283.  
  1284.  
  1285.     aut-num: AS1
  1286.     as-in: from peerings-1 action action-1 accept filter-1
  1287.     as-in: from peerings-2 action action-2 accept filter-2
  1288.  
  1289.  
  1290. The  above  policy  expressions  are  equivalent  to  the  following   three
  1291. expressions where there is no overlap:
  1292.  
  1293.  
  1294.     aut-num: AS1
  1295.     as-in: from peerings-1 action action-1 accept filter-1
  1296.     as-in: from peerings-3 action action-2 accept filter-2 AND NOT filter-1
  1297.     as-in: from peerings-4 action action-2 accept filter-2
  1298.  
  1299.  
  1300. where  peerings-3  are  those  that  are  covered  by  both  peerings-1  and
  1301. peerings-2, and peerings-4 are those that are covered by peerings-2 but  not
  1302. by peerings-1 (``filter-2  AND NOT  filter-1'' matches the  routes that  are
  1303. matched by filter-2 but not by filter-1).
  1304.  
  1305. Example:
  1306.  
  1307.  
  1308.     aut-num: AS1
  1309.     as-in: from AS2 7.7.7.2 at 7.7.7.1
  1310.            action pref = 2
  1311.            accept {128.9.0.0/16}
  1312.     as-in: from AS2
  1313.            action pref = 1
  1314.            accept {128.9.0.0/16, 75.0.0.0/8}
  1315.  
  1316.  
  1317. Lets consider two  peerings with AS2,  7.7.7.1-7.7.7.2 and  9.9.9.1-9.9.9.2.
  1318. Both policy expressions cover 7.7.7.1-7.7.7.2.   On this peering, the  route
  1319. 128.9.0.0/16 is accepted  with preference  2,  and the  route 75.0.0.0/8  is
  1320. accepted with preference 1.  The peering 9.9.9.1-9.9.9.2 is only covered  by
  1321. the second policy expressions.   Hence, both the route 128.9.0.0/16 and  the
  1322. route 75.0.0.0/8 are accepted with preference 1 on peering 9.9.9.1-9.9.9.2.
  1323.  
  1324.  
  1325. 8 dictionary Class
  1326.  
  1327.  
  1328. The dictionary  class provides  extensibility  to RPSL.  Dictionary  objects
  1329. define routing policy  attributes, types,  and routing protocols.    Routing
  1330. policy attributes, henceforth called rp-attributes, may correspond to actual
  1331.  
  1332.  
  1333.  
  1334. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 24]
  1335. Internet Draft                     RPSL                    November 25, 1996
  1336.  
  1337. protocol attributes, such as the  BGP path attributes (e.g. community,  dpa,
  1338. and AS-path), or they may correspond to router features (e.g. BGP route flap
  1339. damping).  As new protocols, new protocol attributes, or new router features
  1340. are introduced,  the dictionary  object is  updated to  include  appropriate
  1341. rp-attribute and protocol definitions.
  1342.  
  1343. An rp-attribute is an abstract class;  that is their data representation  is
  1344. not available.   Instead,  they are accessed  through access methods.    For
  1345. example, an rp-attribute for  the BGP AS-path attribute  may have an  access
  1346. method called  length which  returns the  length  of the  AS-path.    Access
  1347. methods can take arguments.  Arguments are strongly typed.  For example,  an
  1348. rp-attribute for the BGP AS-path attribute may have an access method  called
  1349. prepend which takes  AS numbers  as argument and  prepends them  to the  BGP
  1350. AS-path attribute.
  1351.  
  1352. Once an  rp-attribute is  defined  in the  dictionary,  it  can be  used  to
  1353. describe policy filters  and actions.   Policy analysis  tools are  required
  1354. to fetch the  dictionary object and  recognize newly defined  rp-attributes,
  1355. types, and protocols.   The analysis tools  may approximate policy  analyses
  1356. on rp-attributes:  a filter  defining rp-attribute method may always  match,
  1357. and an action defining rp-attribute method may always perform  no-operation.
  1358. Analysis tools may even download code to perform appropriate operations.
  1359.  
  1360. The attributes  of  the dictionary  class  are shown  in  Figure 14.     The
  1361. dictionary attribute is the name of the dictionary object, obeying the  RPSL
  1362. naming rules.  There can be many dictionary objects, however there is always
  1363. one well-known dictionary object ``RPSL''. All tools use this dictionary  by
  1364. default.
  1365.  
  1366.  
  1367.  Attribute     Value                   Type
  1368.  dictionary    <object-name>           mandatory, single-valued, class key
  1369.  rp-attribute  see description in text optional, multi valued
  1370.  typedef       see description in text optional, multi valued
  1371.  protocol      see description in text optional, multi valued
  1372.  
  1373.                   Figure 14:  dictionary Class Attributes
  1374.  
  1375.  
  1376.  
  1377. The rp-attribute attribute has the following syntax:
  1378.  
  1379.  
  1380.    rp-attribute: <name>
  1381.       <method-1>(<type-1-1>, ..., <type-1-N1> [, "..."])
  1382.       ...
  1383.       <method-M>(<type-M-1>, ..., <type-M-NM> [, "..."])
  1384.  
  1385.  
  1386. where <name> is the name of the rp-attribute; and <method-i> is the name  of
  1387. an access method for  the rp-attribute, taking Ni  arguments where the  j-th
  1388.  
  1389.  
  1390. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 25]
  1391. Internet Draft                     RPSL                    November 25, 1996
  1392.  
  1393. argument is of type <type-i-j>.  A method name is either an RPSL name or one
  1394. of the operators defined in Figure 15.   The operator methods can take  only
  1395. one argument.
  1396.  
  1397.  
  1398.    operator=           operator==
  1399.    operator<<=         operator<
  1400.    operator>>=         operator>
  1401.    operator+=          operator>=
  1402.    operator-=          operator<=
  1403.    operator*=
  1404.    operator/=
  1405.    operator.=
  1406.  
  1407.  
  1408.                            Figure 15:  Operators
  1409.  
  1410. An rp-attribute can have many methods defined  for it.  Some of the  methods
  1411. may even have the same name, in which case their arguments are of  different
  1412. types.   If the argument  list is followed  by ``...'',  the method takes  a
  1413. variable number of arguments.  In this case, the actual arguments after  the
  1414. Nth argument are of type <type-N>.
  1415.  
  1416. Arguments are strongly  typed.   A type  of an  argument can be  one of  the
  1417. predefined types or  one of the  dictionary defined types.   The  predefined
  1418. type names are listed in Figure 16.   The integer and the real types can  be
  1419. followed by a lower and an upper bound to specify the set of valid values of
  1420. the argument.  The range specification is  optional.  We use the C  language
  1421. conventions for representing  integer and  real values.   The  enum type  is
  1422. followed by a list  of RPSL names  which are the valid  values of the  type.
  1423. The boolean type can take the  values true or false.   as_number, ip_address,
  1424. address_prefix and  dns_name types  are as  in Section 2.   filter  type is  a
  1425. policy filter as in Section 7.
  1426.  
  1427.  
  1428.    integer[lower, upper]              as_number
  1429.    real[lower, upper]                 ip_address
  1430.    enum[name, name, ...]              address_prefix
  1431.    string                             dns_name
  1432.    boolean                            filter
  1433.  
  1434.  
  1435.                         Figure 16:  Predefined Types
  1436.  
  1437.  
  1438. The typedef attribute specifies a dictionary defined type.  Its syntax is as
  1439. follows:
  1440.  
  1441.  
  1442.    typedef: <name> <type-1> ... <type-N>
  1443.  
  1444.  
  1445.  
  1446. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 26]
  1447. Internet Draft                     RPSL                    November 25, 1996
  1448.  
  1449. where <name> is the name of the  type being defined and <type-M> is  another
  1450. type name, either predefined or dictionary defined.   The type defined by  a
  1451. typedef is either of the types 1 through N (analogous to unions in C[8]).
  1452.  
  1453. A dictionary defined type can also be a list type, specified as:
  1454.  
  1455.  
  1456.         list [<min_elems>:<max_elems>] of <type>
  1457.  
  1458.  
  1459. where the  list  elements are  of  <type> and  the  list contains  at  least
  1460. <min_elems> and  at most  <max_elems>  elements.   The  size specification  is
  1461. optional.   In this  case, there  is no restriction  in the  number of  list
  1462. elements.  A value of a list  type is represented as a sequence of  elements
  1463. separated by the character  ``,'' and enclosed  by the characters ``{''  and
  1464. ``}''.
  1465.  
  1466. A protocol attribute of  the dictionary class defines  a protocol and a  set
  1467. of peering options for  that protocol (which are  used in inet-rtr class  in
  1468. Section 10).  Its syntax is as follows:
  1469.  
  1470.  
  1471.    protocol: <name>
  1472.       MANDATORY | OPTIONAL <option-1>(<type-1-1>, ..., <type-1-N1> [, "..."])
  1473.       ...
  1474.       MANDATORY | OPTIONAL <option-M>(<type-M-1>, ..., <type-M-NM> [, "..."])
  1475.  
  1476.  
  1477. where <name>  is  the name  of  the protocol;  MANDATORY  and  OPTIONAL  are
  1478. keywords; and <option-i> is  a peering option for  this protocol, taking  Ni
  1479. many arguments.   The syntax and  semantics of the arguments  are as in  the
  1480. rp-attribute.  If the keyword MANDATORY is used the option is mandatory  and
  1481. needs to be specified  for each peering  of this protocol.   If the  keyword
  1482. OPTIONAL is used the option can be skipped.
  1483.  
  1484. The  Figure  18  shows  the  initial   RPSL  dictionary.     It  has   eight
  1485. rp-attributes:   pref to  assign local  preference to  the routes  accepted;
  1486. med to assign a value  to the MULTI_EXIT_DISCRIMINATOR BGP attribute; dpa  to
  1487. assign a value to the  DPA BGP attribute; aspath  to prepend a value to  the
  1488. AS_PATH BGP attribute; community to  assign a value to or to check the  value
  1489. of the community BGP attribute; flap_damp to enable or disable routing  flap
  1490. damping feature  of the  routers; next-hop  to assign  next  hop routers  to
  1491. static routes; and cost to assign a  cost to static routes.  The  dictionary
  1492. defines two types:   community_elm and  community_list.    community_elm  type
  1493. is either a  4-byte unsigned integer,  or one  of the keywords  no_export  or
  1494. no_advertise, or  a list of two  2-byte unsigned integers  in which case  the
  1495. two integers are concatenated to form a  4-byte integer.  (The last form  is
  1496. often used in the  Internet to partition  the community space.   A  provider
  1497. uses its AS number as  the first two bytes, and  assigns a semantics of  its
  1498.  
  1499.  
  1500. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 27]
  1501. Internet Draft                     RPSL                    November 25, 1996
  1502.  
  1503.  
  1504. dictionary:   RPSL
  1505. rp-attribute: pref # preference, smaller values represent higher preferences
  1506.               operator=(integer[0, 65535])  # assign an integer
  1507. rp-attribute: med    # BGP multi_exit_discriminator attribute
  1508.               operator=(integer[0, 65535])  # assign an integer
  1509.               operator=(enum[igp_cost])     # assign the IGP metric
  1510. rp-attribute: dpa    # BGP destination preference attribute (dpa)
  1511.               operator=(integer[0 65535])   # assign an integer
  1512. rp-attribute: aspath # BGP aspath attribute
  1513.               prepend(as_number, ...)       # prepend the AS numbers
  1514.                                             # from last to first order
  1515. typedef:      community_elm # needed for the community attribute
  1516.               integer(0, 4294967000),       # 4 byte community value
  1517.               enum[no_export,  no_advertise]# defined in RFC 1997
  1518.               list[2:2] of integer[0 65535] # construct a 4 byte integer
  1519.                                             # by concating two 2-byte integers
  1520. typedef:      community_list # needed for the community attribute
  1521.               list of community_elm
  1522. rp-attribute: community # BGP community attribute
  1523.               operator=(community_list)     # assign a list of communities
  1524.               operator==(community_list)    # true if equals the argument
  1525.                                             # order independent comparison
  1526.               operator.=(community_elm)     # append an element
  1527.               append(community_elm)         # same as .=
  1528.               remove(community_elm)         # delete an element
  1529.               contains(community_elm)       # true if element is contained
  1530. rp-attribute: flap_damp # flap_damping router feature
  1531.               enable()                      # enable flap_damping
  1532.               disable()                     # disable flap_damping
  1533. rp-attribute: next-hop # next hop router in a static route
  1534.               operator=(ip_address)         # assign a router address
  1535. rp-attribute: cost # cost of a static route
  1536.               operator=(integer[0, 65535])  # assign an integer
  1537.  
  1538.  
  1539.                     Figure 17:  RPSL Dictionary (cont.)
  1540.  
  1541. choice to the last two bytes.)
  1542.  
  1543. The initial  dictionary (Figure  18)  defines only  options for  the  Border
  1544. Gateway Protocol:  asno and flap_damp.   The mandatory asno option is the  AS
  1545. number of the  peer router.    The optional  flap_damp  option instructs  the
  1546. router to damp route flaps when importing routes from the peer router.
  1547.  
  1548.  
  1549.  
  1550.  
  1551.  
  1552.  
  1553. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 28]
  1554. Internet Draft                     RPSL                    November 25, 1996
  1555.  
  1556.  
  1557. protocol:     BGP # Border Gateway Protocol
  1558.               MANDATORY asno(as_number)   # as number of the peer router
  1559.               OPTIONAL flap_damp()        # enable flap damping
  1560. protocol:     OSPF
  1561. protocol:     RIP
  1562. protocol:     IGRP
  1563. protocol:     IS-IS
  1564. protocol:     STATIC
  1565.  
  1566.  
  1567.                         Figure 18:  RPSL Dictionary
  1568.  
  1569. 8.1 Policy Actions and Filters Using RP-Attributes
  1570.  
  1571.  
  1572. The syntax of  a policy action  or a filter  using an rp-attribute  x is  as
  1573. follows:
  1574.  
  1575.  
  1576.     x.method(arguments)
  1577.     x ``op'' argument
  1578.  
  1579.  
  1580. where  method  is  a  method  and  ``op''  is  an  operator  method  of  the
  1581. rp-attribute x.
  1582.  
  1583. The pref rp-attribute can be assigned a positive integer as follows:
  1584.  
  1585.  
  1586.    pref = 10
  1587.  
  1588.  
  1589. The med rp-attribute can be assigned  either a positive integer or the  word
  1590. ``igp_cost'' as follows:
  1591.  
  1592.  
  1593.    med = 0
  1594.    med = igp_cost
  1595.  
  1596.  
  1597. The dpa rp-attribute can be assigned a positive integer as follows:
  1598.  
  1599.  
  1600.    dpa = 100
  1601.  
  1602.  
  1603. The BGP  community  attribute is  list-valued,  that  is  it is  a  list  of
  1604. 4-byte integers each representing a  ``community''.  The following  examples
  1605. demonstrate how to add communities to this rp-attribute:
  1606.  
  1607.  
  1608.  
  1609. Alaettinoglu et. al.             Expires  May 25, 1997             [Page 29]
  1610. Internet Draft                     RPSL                    November 25, 1996
  1611.  
  1612.    community .= 100
  1613.    community .= NO_EXPORT
  1614.    community .= {3561, 10}
  1615.  
  1616.  
  1617. In the last case, a 4-byte integer is constructed where the more significant
  1618. two bytes equal  3561 and  the less  significant two bytes  equal 10.    The
  1619. following examples demonstrate how to delete communities from the  community
  1620. rp-attribute:
  1621.  
  1622.  
  1623.    community.delete(100)
  1624.    community.delete(NO_EXPORT)
  1625.    community.delete({3561, 10})
  1626.  
  1627.  
  1628. Filters that use the community  rp-attribute can be defined as  demonstrated
  1629. by the following examples:
  1630.  
  1631.  
  1632.    community.contains(100)
  1633.    community.contains(NO_EXPORT)
  1634.    community.contains({3561, 10})
  1635.  
  1636.  
  1637. The community rp-attribute can be set to a list of communities as follows:
  1638.  
  1639.  
  1640.    community = {100, NO_EXPORT, {3561, 10}, 200}
  1641.    community = {}
  1642.  
  1643.  
  1644. In this  first case,  the community  rp-attribute contains  the  communities
  1645. 100, NO_EXPORT,  {3561, 10},  and 200.    In the  latter case,  the community
  1646. rp-attribute is cleared.  The community rp-attribute can be compared against
  1647. a list of communities as follows:
  1648.  
  1649.  
  1650.    community == {100, 200}
  1651.    community == {}
  1652.  
  1653.  
  1654. To influence the route selection,  the BGP as_path rp-attribute can be  made
  1655. longer by prepending AS numbers to it as follows:
  1656.  
  1657.  
  1658.    aspath.prepend(AS1)
  1659.    aspath.prepend(AS1, AS1, AS1)
  1660.  
  1661.  
  1662. Flap damping can be turned on or off as follows:
  1663.  
  1664.  
  1665. Alaettinoglu et. al.             Expires  May 25, 1997             [Page 30]
  1666. Internet Draft                     RPSL                    November 25, 1996
  1667.  
  1668.    flap_damp.enable()
  1669.    flap_damp.disable()
  1670.  
  1671.  
  1672. The following examples are invalid:
  1673.  
  1674.  
  1675.    med = -50                      # -50 is not in the range
  1676.    med = igp                      # igp is not one of the enum values
  1677.    med.assign(10)                 # method assign is not defined
  1678.    community.append({AS3561, 20}) # the first argument should be 3561
  1679.  
  1680.  
  1681. Figure 19 shows a  more advanced example  using the rp-attribute  community.
  1682. In this  example,  AS3561  bases  its  route  selection  preference  on  the
  1683. community attribute.    Other  ASes  may indirectly  affect  AS3561's  route
  1684. selection  by  including   the  appropriate  communities   in  their   route
  1685. announcements.
  1686.  
  1687. aut-num: AS1
  1688. as-out: to AS2 action community.={3651, 10}
  1689.         to AS3 action community.={3651, 20}
  1690.         announce AS1
  1691.  
  1692. as-set: AS3561:AS-PEERS
  1693. members: AS2, AS3
  1694.  
  1695. aut-num: AS3561
  1696. as-in: from AS3561:AS-PEERS
  1697.        action pref = 10
  1698.        accept community.contains({3651, 10})
  1699. as-in: from AS3561:AS-PEERS
  1700.        action pref = 20
  1701.        accept community.contains({3651, 20})
  1702. as-in: from AS3561:AS-PEERS
  1703.        action pref = 30
  1704.        accept ANY
  1705.  
  1706.  
  1707.         Figure 19:  Policy example using the community rp-attribute.
  1708.  
  1709.  
  1710.  
  1711. 9 Advanced route Class
  1712.  
  1713.  
  1714. 9.1 Specifying Static Routes
  1715.  
  1716.  
  1717. The attribute inject-at can be used to specify static routes.  Its syntax is
  1718. as follows:
  1719.  
  1720.  
  1721. Alaettinoglu et. al.             Expires  May 25, 1997             [Page 31]
  1722. Internet Draft                     RPSL                    November 25, 1996
  1723.  
  1724.    inject-at: <router> [action <action>]
  1725.  
  1726.  
  1727. where <router>  is an  IP address  of a  router and  <action> is  as in  the
  1728. aut-num class.  <router> executes the <action> and injects the route to  the
  1729. interAS routing system.  <action> may set certain route attributes such as a
  1730. next-hop router or a cost.
  1731.  
  1732. In the following example, the router 7.7.7.1 injects the route 128.7.0.0/16.
  1733. The next-hop router for this  route is 7.7.7.2 and the  route has a cost  of
  1734. 10.
  1735.  
  1736.  
  1737.    route:     128.7.0.0/16
  1738.    origin:    AS1
  1739.    inject-at: 7.7.7.1 action next-hop = 7.7.7.2; cost = 10;
  1740.  
  1741.  
  1742. 9.2 Specifying Aggregate Routes
  1743.  
  1744.  
  1745. The attributes  aggregate-by, inject-at,  export-components,  and holes  are
  1746. used for specifying aggregate routes [6].
  1747.  
  1748. The aggregate-by attribute defines  what component routes  are used to  form
  1749. the aggregate.  Its syntax is as follows:
  1750.  
  1751.  
  1752.    aggregate-by: [atomic] <filter>
  1753.  
  1754.  
  1755. A router in the origin AS forms the aggregate route if there is at least one
  1756. route in its routing  table that matches  <filter>.   If the keyword  ATOMIC
  1757. is specified, the  aggregation is  done atomically, otherwise  the BGP  path
  1758. attributes of the matching routes are  used to form the BGP path  attributes
  1759. of the aggregate route.   For  example, if atomic  aggregation is done,  the
  1760. aggregate route  would have  an  AS-path that  starts from  the  aggregating
  1761. AS [6].   Otherwise, the  aggregate route would  have an AS-path  containing
  1762. AS-sets formed from the AS-paths of the matching routes.
  1763.  
  1764. Figure 20  shows  some example  aggregate  route  objects.    The  aggregate
  1765. 128.9.0.0/16 is  generated if  there  is a  route  that matches  the  filter
  1766. ``128.9.0.0/16^- AND  <^AS226>''  (this  filter matches  more  specifics  of
  1767. 128.9.0.0/16 that are  received form  AS226).   The BGP  path attributes  of
  1768. the matching  routes  are  used to  form  the  BGP path  attributes  of  the
  1769. route 128.9.0.0/16.  Similarly,  the aggregate 128.8.0.0/16 is generated  if
  1770. there is a route  that matches the  filter ``128.8.0.0/16^- AND  <^AS226>''.
  1771. However, its  path attributes  are generated  using the  atomic  aggregation
  1772. rules [6].   The aggregate 128.7.0.0/16 is  always and atomically  generated
  1773. since the policy filter ``ANY'' matches any route in the routing table.
  1774.  
  1775.  
  1776.  
  1777. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 32]
  1778. Internet Draft                     RPSL                    November 25, 1996
  1779.  
  1780.  
  1781.    route: 128.9.0.0/16
  1782.    origin: AS1
  1783.    aggregate-by: {128.9.0.0/16^-} AND <^AS226>
  1784.  
  1785.    route: 128.8.0.0/16
  1786.    origin: AS1
  1787.    aggregate-by: ATOMIC {128.8.0.0/16^-} AND <^AS226>
  1788.  
  1789.    route: 128.7.0.0/16
  1790.    origin: AS1
  1791.    aggregate-by: ATOMIC ANY
  1792.    inject-at: 7.7.7.1
  1793.    inject-at: 9.9.9.1
  1794.    export-components: {128.7.9.0/24}
  1795.  
  1796.  
  1797.                     Figure 20:  Aggregate route objects.
  1798.  
  1799. The inject-at attribute lists the routers in the originating AS that  inject
  1800. this route  to the  interAS routing  system.   That  is,  these routers  are
  1801. configured to  perform the  aggregation.    If  the inject-at  attribute  is
  1802. missing, all routers  in the originating  AS perform the  aggregation.   The
  1803. route 128.7.0.0/16 in Figure 20 is  injected by routers 7.7.7.1 and  9.9.9.1
  1804. in AS1.
  1805.  
  1806. When a  set of  routes are  aggregated, the  intent is  to  export only  the
  1807. aggregate route and suppress  the exporting of the  component routes to  the
  1808. outside world.  However, to satisfy certain policy and topology  constraints
  1809. (e.g. a multi-homed component), it is  often required to export some of  the
  1810. components.   The  export-components attribute  equals an  RPSL filter  that
  1811. matches the routes that  need to be  exported to the neighboring  ASes.   If
  1812. this attribute is missing,  no component route needs  to be exported to  the
  1813. neighboring ASes.  The export-components attribute can only be specified  if
  1814. an aggregate-by attribute is specified for the route object.  The  component
  1815. 128.7.9.0/24 of route  128.7.0.0/16 in  Figure 20  needs to  be exported  to
  1816. other ASes.
  1817.  
  1818. The holes  attribute lists  the  component address  prefixes which  are  not
  1819. reachable through  the aggregate  route (perhaps  that part  of the  address
  1820. space is unallocated).  Figure 21 shows a route object whose two components,
  1821. namely 128.9.0.0/16 and 128.7.0.0/16, are  not reachable via the  aggregate.
  1822. That is, if a data packet destined to a host in 128.9.0.0/16 is sent to AS1,
  1823. AS1 can not deliver it to its final destination (i.e. it is black-holed).
  1824.  
  1825.  
  1826.  
  1827.  
  1828.  
  1829.  
  1830.  
  1831.  
  1832.  
  1833. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 33]
  1834. Internet Draft                     RPSL                    November 25, 1996
  1835.  
  1836.  
  1837.    route: 128.9.0.0/12
  1838.    origin: AS1
  1839.    aggregate-by: {128.9.0.0/12^-}
  1840.    holes: 128.7.0.0/16, 128.9.0.0/16
  1841.  
  1842.  
  1843. Figure 21:    The  route  128.9.0.0/12 does  not  lead  to  destinations  in
  1844. 128.9.0.0/16.
  1845.  
  1846. 10 inet-rtr Class
  1847.  
  1848.  
  1849. Routers are  specified using  the inet-rtr  class.   The  attributes of  the
  1850. inet-rtr class are shown in  Figure 22.  The  inet-rtr attribute is a  valid
  1851. DNS name of the router  described.  Each alias  attribute, if present, is  a
  1852. canonical DNS name for the router.   The value of an ifaddr attribute is  an
  1853. IP address followed by the word ``masklen'' and followed by an integer.  The
  1854. local-as attribute specifies  the AS  number of the  AS which  owns/operates
  1855. this router.
  1856.  
  1857.  
  1858. Attribute  Value                          Type
  1859. inet-rtr   <dns-name>                     mandatory, single-valued, class key
  1860. alias      <dns-name>                     optional, multi-valued
  1861. local-as   <as-number>                    mandatory, single-valued
  1862. ifaddr     <ip-address> masklen <integer> mandatory, multi-valued
  1863. peer       see description in text        optional, multi-valued
  1864.  
  1865.  
  1866.                    Figure 22:  inet-rtr Class Attributes
  1867.  
  1868.  
  1869. Figure 23 presents an example  inet-rtr object.  The  name of the router  is
  1870. ``amsterdam.ripe.net''.  ``amsterdam1.ripe.net'' is a canonical name for the
  1871. router.  The router is connected to  4 networks.  Its IP addresses and  mask
  1872. lengths in those networks are specified in the ifaddr attributes.
  1873.  
  1874. Each peer attribute, if present,  specifies a protocol peering with  another
  1875. router.  The value  of a peer attribute is  a protocol name followed by  the
  1876. IP address of  the peer router  and followed  by a comma  separated list  of
  1877. peering options for that protocol.   Possible protocol names and  attributes
  1878. are defined in the dictionary (please see Section 8).  In the above example,
  1879. the router has  a BGP peering  with the router  192.87.45.195 in AS3334  and
  1880. turns the flap damping on when importing routes from this router.
  1881.  
  1882.  
  1883.  
  1884.  
  1885.  
  1886.  
  1887.  
  1888.  
  1889. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 34]
  1890. Internet Draft                     RPSL                    November 25, 1996
  1891.  
  1892.  
  1893.         inet-rtr: Amsterdam.ripe.net
  1894.         alias:    amsterdam1.ripe.net
  1895.         localas:  AS3333
  1896.         ifaddr:   192.87.45.190 masklen 24
  1897.         ifaddr:   192.87.4.28   masklen 24
  1898.         ifaddr:   193.0.0.222   masklen 27
  1899.         ifaddr:   193.0.0.158   masklen 27
  1900.         peer:     BGP 192.87.45.195 asno(AS3334), flap_damp()
  1901.  
  1902.  
  1903.                         Figure 23:  inet-rtr Objects
  1904.  
  1905. 11 Acknowledgements
  1906.  
  1907.  
  1908. We would like to thank  Jessica Yu, Randy Bush,  Alan Barrett, David  Meyer,
  1909. David Kessens, Bill Manning,  Sue Hares,  Ramesh Govindan, Kannan  Varadhan,
  1910. Satish Kumar, Craig  Labovitz, Rusty  Eddy, David J.  LeRoy, David  Whipple,
  1911. Jon Postel, Deborah  Estrin, and  Elliot Schwartz for  various comments  and
  1912. suggestions.
  1913.  
  1914.  
  1915.  
  1916. References
  1917.  
  1918.  
  1919.  [1] How to register in RADB. http://www.ra.net/RADB.tools.docs/.
  1920.  
  1921.  [2] C. Alaettinouglu.  Application of Routing Policy Specification  Language
  1922.      (RPSL)  on  the Internet.  Internet  draft,  USC  Information  Sciences
  1923.      Institute. Work in progress.
  1924.  
  1925.  [3] T.  Bates, E.  Gerich,  L. Joncheray,  J-M. Jouanigot,  D.  Karrenberg,
  1926.      M.  Terpstra,  and  J.  Yu.   Representation  of  IP  Routing  Policies
  1927.      in  a Routing  Registry.  Technical Report  ripe-181, RIPE,  RIPE  NCC,
  1928.      Amsterdam, Netherlands, October 1994.
  1929.  
  1930.  [4] T. Bates, J-M. Jouanigot, D. Karrenberg, P. Lothberg, and  M. Terpstra.
  1931.      Representation of IP  Routing Policies in the RIPE Database.  Technical
  1932.      Report ripe-81, RIPE, RIPE NCC, Amsterdam, Netherlands, February 1993.
  1933.  
  1934.  [5] D. Crocker.  Standard for  the format of  ARPA Internet text  messages.
  1935.      Request for Comment RFC-822, Network Information Center, August 1982.
  1936.  
  1937.  [6] V.  Fuller, T.  Li,  J. Yu,  and  K. Varadhan.  Classless  Inter-Domain
  1938.      Routing (CIDR): an Address Assignment and Aggregation Strategy, 1993.
  1939.  
  1940.  [7] D.  Karrenberg  and M.  Terpstra.  Authorisation  and  Notification  of
  1941.      Changes in  the RIPE  Database. Technical Report  ripe-120, RIPE,  RIPE
  1942.      NCC, Amsterdam, Netherlands, October 1994.
  1943.  
  1944.  
  1945. Alaettinoglu et. al.             Expires  May 25, 1997             [Page 35]
  1946. Internet Draft                     RPSL                    November 25, 1996
  1947.  
  1948.  [8] B.  W.  Kernighan  and D.  M.  Ritchie.  The  C  Programming  Language.
  1949.      Prentice-Hall, 1978.
  1950.  
  1951.  [9] A.  Lord  and   M.  Terpstra.  RIPE  Database  Template  for   Networks
  1952.      and  Persons. Technical  Report ripe-119,  RIPE,  RIPE NCC,  Amsterdam,
  1953.      Netherlands, October 1994.
  1954.  
  1955. [10] P. V. Mockapetris. Domain names - concepts and facilities.  Request for
  1956.      Comment RFC-1034, Network Information Center, November 1987.
  1957.  
  1958. [11] Y.   Rekhter.  Inter-Domain   Routing  Protocol  (IDRP).   Journal   of
  1959.      Internetworking Research and Experience, 4:61--80, 1993.
  1960.  
  1961. [12] Y. Rekhter and T. Li. A Border Gateway Protocol 4 (BGP-4).  Request for
  1962.      Comment RFC-1654, Network Information Center, July 1994.
  1963.  
  1964.  
  1965. A Routing Registry Sites
  1966.  
  1967.  
  1968. The set of routing registries as of November 1996 are RIPE, RADB, CANet, MCI
  1969. and ANS. You may  contact one of  these registries to  find out the  current
  1970. list of registries.
  1971.  
  1972.  
  1973.  
  1974.  
  1975.  
  1976.  
  1977.  
  1978.  
  1979.  
  1980.  
  1981.  
  1982.  
  1983.  
  1984.  
  1985.  
  1986.  
  1987.  
  1988.  
  1989.  
  1990.  
  1991.  
  1992.  
  1993.  
  1994.  
  1995.  
  1996.  
  1997.  
  1998.  
  1999.  
  2000.  
  2001. Alaettinoglu et.  al.            Expires  May 25, 1997             [Page 36]
  2002.