Public Member Functions | |
def | ca_detail |
def | ee_uri |
def | ee_uri_tail |
def | generate_roa |
def | regenerate_roa |
def | roa_uri |
def | serve_post_save_hook |
def | sql_delete_hook |
def | sql_fetch_hook |
def | sql_insert_hook |
def | startElement |
def | update_roa |
def | withdraw_roa |
Public Attributes | |
as_number | |
ipv4 | |
ipv6 | |
Static Public Attributes | |
tuple | attributes = ("action", "tag", "self_id", "route_origin_id", "as_number", "ipv4", "ipv6") |
XML attributes for this element. | |
tuple | booleans = ("suppress_publication",) |
Boolean attributes (value "yes" or "no") for this element. | |
ca_detail_id = None | |
cert = None | |
string | element_name = "route_origin" |
roa = None | |
tuple | sql_template |
<route_origin/> element.
Definition at line 532 of file left_right.py.
def rpki.left_right.route_origin_elt.ca_detail | ( | self | ) |
Fetch all ca_detail objects that link to this route_origin object.
Definition at line 576 of file left_right.py.
def rpki.left_right.route_origin_elt.ee_uri | ( | self, | ||
ca | ||||
) |
Return the publication URI for this route_origin's ROA's EE certificate.
Definition at line 735 of file left_right.py.
def rpki.left_right.route_origin_elt.ee_uri_tail | ( | self | ) |
Return the tail (filename) portion of the URI for this route_origin's ROA's EE certificate.
Definition at line 731 of file left_right.py.
def rpki.left_right.route_origin_elt.generate_roa | ( | self | ) |
Generate a ROA based on this <route_origin/> object. At present this does not support ROAs with multiple signatures (neither does the current CMS code). At present we have no way of performing a direct lookup from a desired set of resources to a covering certificate, so we have to search. This could be quite slow if we have a lot of active ca_detail objects. Punt on the issue for now, revisit if profiling shows this as a hotspot. Once we have the right covering certificate, we generate the ROA payload, generate a new EE certificate, use the EE certificate to sign the ROA payload, publish the result, then throw away the private key for the EE cert, all per the ROA specification. This implies that generating a lot of ROAs will tend to thrash /dev/random, but there is not much we can do about that.
Definition at line 625 of file left_right.py.
def rpki.left_right.route_origin_elt.regenerate_roa | ( | self | ) |
def rpki.left_right.route_origin_elt.roa_uri | ( | self, | ||
ca, | ||||
key = None | ||||
) |
Return the publication URI for this route_origin's ROA.
Definition at line 727 of file left_right.py.
def rpki.left_right.route_origin_elt.serve_post_save_hook | ( | self, | ||
q_pdu, | ||||
r_pdu | ||||
) |
Extra server actions for route_origin_elt.
Reimplemented from rpki.xml_utils.data_elt.
Definition at line 580 of file left_right.py.
def rpki.left_right.route_origin_elt.sql_delete_hook | ( | self | ) |
Extra SQL delete actions for route_origin_elt -- handle address ranges.
Reimplemented from rpki.sql.sql_persistant.
Definition at line 572 of file left_right.py.
def rpki.left_right.route_origin_elt.sql_fetch_hook | ( | self | ) |
Extra SQL fetch actions for route_origin_elt -- handle prefix list.
Reimplemented from rpki.sql.sql_persistant.
Definition at line 548 of file left_right.py.
def rpki.left_right.route_origin_elt.sql_insert_hook | ( | self | ) |
Extra SQL insert actions for route_origin_elt -- handle address ranges.
Reimplemented from rpki.sql.sql_persistant.
Definition at line 563 of file left_right.py.
def rpki.left_right.route_origin_elt.startElement | ( | self, | ||
stack, | ||||
name, | ||||
attrs | ||||
) |
Handle <route_origin/> element. This requires special processing due to the data types of some of the attributes.
Reimplemented from rpki.xml_utils.base_elt.
Definition at line 584 of file left_right.py.
def rpki.left_right.route_origin_elt.update_roa | ( | self | ) |
Bring this route_origin's ROA up to date if necesssary.
Definition at line 597 of file left_right.py.
def rpki.left_right.route_origin_elt.withdraw_roa | ( | self, | ||
regenerate = False | ||||
) |
Withdraw ROA associated with this route_origin. In order to preserve make-before-break properties without duplicating code, this method also handles generating a replacement ROA when requested.
Definition at line 694 of file left_right.py.
tuple rpki.left_right.route_origin_elt.attributes = ("action", "tag", "self_id", "route_origin_id", "as_number", "ipv4", "ipv6") [static] |
XML attributes for this element.
Reimplemented from rpki.xml_utils.base_elt.
Definition at line 536 of file left_right.py.
tuple rpki.left_right.route_origin_elt.booleans = ("suppress_publication",) [static] |
Boolean attributes (value "yes" or "no") for this element.
Reimplemented from rpki.xml_utils.base_elt.
Definition at line 537 of file left_right.py.
rpki.left_right.route_origin_elt.ca_detail_id = None [static] |
Definition at line 544 of file left_right.py.
rpki.left_right.route_origin_elt.cert = None [static] |
Definition at line 545 of file left_right.py.
string rpki.left_right.route_origin_elt.element_name = "route_origin" [static] |
Definition at line 535 of file left_right.py.
rpki.left_right.route_origin_elt.roa = None [static] |
Definition at line 546 of file left_right.py.
tuple rpki.left_right.route_origin_elt.sql_template [static] |
Initial value:
rpki.sql.template("route_origin", "route_origin_id", "ca_detail_id", "self_id", "as_number", ("roa", rpki.x509.ROA), ("cert", rpki.x509.X509))
Definition at line 539 of file left_right.py.