From dcdf9ef1787cb0a4e86de1c37f50618b89974fb5 Mon Sep 17 00:00:00 2001 From: Rob Austein Date: Fri, 2 Nov 2007 03:47:25 +0000 Subject: Checkpoint svn path=/pow/POW-0.7/lib/pkix.py; revision=1231 --- scripts/rpki/up_down.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'scripts/rpki/up_down.py') diff --git a/scripts/rpki/up_down.py b/scripts/rpki/up_down.py index edb70657..d4b62153 100644 --- a/scripts/rpki/up_down.py +++ b/scripts/rpki/up_down.py @@ -315,7 +315,7 @@ class issue_pdu(base_elt): class issue_response_pdu(class_response_syntax): """Up-Down protocol "issue_response" PDU.""" - def check(self): + def check_syntax(self): """Check whether this looks like a reasonable issue_response PDU. XML schema should be tighter for this response. """ @@ -419,6 +419,12 @@ class error_response_pdu(base_elt): elt.text = str(self.status) return [elt] + def check(self): + """Handle an error response. For the moment, just raise an + exception, eventually figure out something more clever to do. + """ + raise rpki.exceptions.UpstreamError, self.codes[self.status] + class message_pdu(base_elt): """Up-Down protocol message wrapper PDU.""" -- cgit v1.2.3