diff --git a/rfc3161/api.py b/rfc3161/api.py index 889da4d..6f44104 100644 --- a/rfc3161/api.py +++ b/rfc3161/api.py @@ -182,7 +182,6 @@ class RemoteTimestamper(object): response = urllib2.urlopen(http_request).read() except (IOError, socket.error), e: raise TimestampingError('Unable to send the request to %s' % self.url, e) - open('response.tsr', 'w').write(response) tst_response, substrate = decoder.decode(response, asn1Spec=rfc3161.TimeStampResp()) if substrate: return False, 'Extra data returned' diff --git a/tests/api.py b/tests/api.py index 10dea5e..95f8c5b 100644 --- a/tests/api.py +++ b/tests/api.py @@ -26,7 +26,7 @@ class Rfc3161(unittest.TestCase): PASSWORD = 'teszt' CERTIFICATE = os.path.join(os.path.dirname(__file__), '../data/e_szigno_test_tsa2.crt') - data = 'xx' + data = '{"comment": "Envoi en Commission", "to": "Benjamin Dauvergne", "filetype": "Arr\u00eat CC", "from": "Benjamin Dauvergne", "files": [{"name": "affectations_ange1d.xlsx", "digest": "ce57e4ba353107dddaab91b9ad26c0569ffe0f94", "size": 16279}]}' certificate = file(CERTIFICATE).read() value, substrate = rfc3161.RemoteTimestamper( PUBLIC_TSA_SERVER, certificate=certificate, username=USERNAME,