Archives and re-stamping
A time stamp proves that a document existed at the moment of the time stamp. That proof rests on the certificate the service signed the time stamp with and on the hash algorithm (SHA-256). The certificate has an expiry date, and algorithms grow weaker over time. For a long-term archive the time stamp must therefore be renewed: before it weakens, a new time stamp confirms both the document and all the earlier time stamps.
Signed documents
Section titled “Signed documents”For documents you sign with the AdES web API, choose level LTA (see Signature levels and time stamps). The signature then holds the data for long-term validation and an archive time stamp, all inside the document itself.
Other files
Section titled “Other files”Keep the service’s response (.tsr) with the file, under the same name (document.pdf and document.pdf.tsr). After
stamping, the file must not change by a single byte: the time stamp is valid only for exactly that content.
When to renew the time stamp
Section titled “When to renew the time stamp”Every time stamp holds the certificate of the service that issued it (if you sent the request with -cert or
certReq). You can check the certificate’s expiry date as follows:
openssl ts -reply -in document.pdf.tsr -token_out | openssl pkcs7 -inform DER -print_certs | openssl x509 -noout -subject -enddateRequest a new time stamp well before that date, and earlier if the hash algorithm is no longer considered secure.
How to renew the time stamp
Section titled “How to renew the time stamp”Request the new time stamp for the document together with all the earlier time stamps, so that it confirms them too:
cat document.pdf document.pdf.tsr | openssl ts -query -sha256 -cert -out renewal.tsqcurl --fail -u 'USER_NAME:PASSWORD' \ -H 'Content-Type: application/timestamp-query' \ --data-binary @renewal.tsq \ -o document.pdf.2.tsr \ 'SERVICE_ADDRESS'At the next renewal, add document.pdf.2.tsr to the input as well, always in the same order. Keep all the time stamps
and record the order in which you joined them: without it the chain cannot be verified. For larger archives the same
principle applies to groups of documents (an evidence record as in RFC 4998).
Verifying a time stamp
Section titled “Verifying a time stamp”You verify a time stamp with the certificate chain of AKD’s time-stamping service, for example:
openssl ts -verify -data document.pdf -in document.pdf.tsr -CAfile akd-tsa-chain.pemVerification: OK means that the time stamp belongs to that document and that a service from the chain signed it. AKD
is a qualified trust service provider, so its services and certificates are also listed in the EU Trusted List.