pyhanko.sign.timestamps.requests_client module

class pyhanko.sign.timestamps.requests_client.HTTPTimeStamper(url, https=False, timeout=5, auth=None, headers=None)

Bases: pyhanko.sign.timestamps.api.TimeStamper

Standard HTTP-based timestamp client.

request_headers() dict

Format the HTTP request headers.

Returns

Header dictionary.

async async_request_tsa_response(req: asn1crypto.tsp.TimeStampReq) asn1crypto.tsp.TimeStampResp

Submit the specified timestamp request to the server.

Parameters

req – Request body to submit.

Returns

A timestamp response from the server.

Raises

IOError – Raised in case of an I/O issue in the communication with the timestamping server.