Skip to content

Latest commit

 

History

History
52 lines (38 loc) · 2.6 KB

requesting-a-timestamp-token.adoc

File metadata and controls

52 lines (38 loc) · 2.6 KB

1. Requesting a timestamp token in DSS

Timestamping is essential when creating digital signatures that need to be preserved. Refer to section [Timestamps] for information about the general principles of the timestamping process. The following sections present how a timestamp token can be requested in DSS.

1.1. Configuring timestamp sources

The DSS framework proposes a TSPSource interface to implement the communication with a Time Stamp Authority (see section [TSA] for more information on Time Stamp Authorities). The class OnlineTSPSource is the default implementation of TSPSource using a HTTP(S) communication layer.

The following snippet of Java code illustrates how you might use this class:

OnlineTSPSource use
link:../../../test/java/eu/europa/esig/dss/cookbook/example/sources/OnlineTSPSourceTest.java[role=include]

1.1.1. Timestamp policy

A time-stamp policy is a "named set of rules that indicates the applicability of a time-stamp token to a particular community and/or class of application with common security requirements". A TSA may define its own policy which enhances the policy defined in RFC 3628. Such a policy shall incorporate or further constrain the requirements identified in RFC 3628. The user may request the TSA to issue a timestamp under a specific time-stamp policy that is supported by the TSA.

Timestamp policy
link:../../../test/java/eu/europa/esig/dss/cookbook/example/sources/OnlineTSPSourceTest.java[role=include]

1.1.2. Composite TSP sources

Sometimes timestamping servers may encounter interruptions (e.g. restart, configuration issues, etc.). To avoid failing signature augmentation, DSS allows a user to configure several TSP Sources. DSS will try one source after the other until getting a usable timestamp token.

Configuration of a CompositeTSPSource
link:../../../test/java/eu/europa/esig/dss/cookbook/example/sources/CompositeTSPSourceTest.java[role=include]

1.1.3. KeyEntity TSP source

Starting from version 5.13 DSS provides a KeyEntityTSPSource implementation allowing to create timestamps using a local key store. The implementation is provided mainly for test purposes and creation of local timestamps.

Configuration of a KeyEntityTSPSource
link:../../../test/java/eu/europa/esig/dss/cookbook/example/sources/KeyEntityTSPSourceTest.java[role=include]