diff options
author | Rob Austein <sra@hactrn.net> | 2012-02-17 21:53:03 +0000 |
---|---|---|
committer | Rob Austein <sra@hactrn.net> | 2012-02-17 21:53:03 +0000 |
commit | 84dd133ca6bb55e14725074e700eca9f8d845edf (patch) | |
tree | d205eb727b52172b4a065a7b8496884b00d4f85f /rpkid/rpki/http.py | |
parent | faa7ce891439f07e467d44573b883ef6cdfa03fa (diff) |
Revoke certificates and clean up published objects when processing a
left-right destroy action. Clean up empty publication directories on
withdrawal. Fix rootd's handling of CRLs and manifests. See #197.
svn path=/trunk/; revision=4354
Diffstat (limited to 'rpkid/rpki/http.py')
-rw-r--r-- | rpkid/rpki/http.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/rpkid/rpki/http.py b/rpkid/rpki/http.py index d8afd44c..0df7e6f2 100644 --- a/rpkid/rpki/http.py +++ b/rpkid/rpki/http.py @@ -766,7 +766,14 @@ class http_client(http_stream): self.update_timeout() if self.msg.code != 200: - raise rpki.exceptions.HTTPRequestFailed, "HTTP request failed with status %s, reason %s, response %s" % (self.msg.code, self.msg.reason, self.msg.body) + errmsg = "HTTP request failed" + if self.msg.code is not None: + errmsg += " with status %s" % self.msg.code + if self.msg.reason: + errmsg += ", reason %s" % self.msg.reason + if self.msg.body: + errmsg += ", response %s" % self.msg.body + raise rpki.exceptions.HTTPRequestFailed(errmsg) self.queue.return_result(self, self.msg, detach = self.expect_close) def handle_close(self): |