public class TSAservice
extends Object
TSAservice
is used as a singleton for making 3161 timestamp
requests, and has configuration provided by CertHandler
and
ConfigManager
.Modifier and Type | Field and Description |
---|---|
static String |
COPYRIGHT_NOTICE |
static org.bouncycastle.asn1.ASN1ObjectIdentifier |
POLICY_BP256 |
static org.bouncycastle.asn1.ASN1ObjectIdentifier |
POLICY_BP512 |
static org.bouncycastle.asn1.ASN1ObjectIdentifier |
POLICY_NIST256 |
static org.bouncycastle.asn1.ASN1ObjectIdentifier |
POLICY_NIST521 |
static org.bouncycastle.asn1.ASN1ObjectIdentifier |
POLICY_RSA2048
constant definition of various DigiStamp TSA policy options.
|
static org.bouncycastle.asn1.ASN1ObjectIdentifier |
POLICY_RSA4096 |
static String |
VERSION |
Constructor and Description |
---|
TSAservice()
This is the recommended constructor.
|
TSAservice(Properties config)
Constructs theTSAservice without using
ConfigManager . |
Modifier and Type | Method and Description |
---|---|
Properties |
getConfiguration()
Returns a copy of the
Properties current TSA Configuration. |
TsResponse |
getTimestamp(TsRequest request)
Use the default configuration for this TSA service
|
TsResponse |
getTimestamp(TsRequest request,
String user,
String password)
set the user / password combination for this particular transaction.
|
ArrayList<String> |
getTSAs()
Returns a list of all TSAs the TSAservice is configured to try
|
void |
setConfiguration(Properties newDefault)
Set the current
Properties TSA Configuration. |
void |
setTSAs(ArrayList<String> tsaSubdomains)
The API toolkit handles TSA selection for you.
|
String |
toString()
Dumps the configuration of theTSAservice to a String
|
public static final String COPYRIGHT_NOTICE
public static final org.bouncycastle.asn1.ASN1ObjectIdentifier POLICY_BP256
public static final org.bouncycastle.asn1.ASN1ObjectIdentifier POLICY_BP512
public static final org.bouncycastle.asn1.ASN1ObjectIdentifier POLICY_NIST256
public static final org.bouncycastle.asn1.ASN1ObjectIdentifier POLICY_NIST521
public static final org.bouncycastle.asn1.ASN1ObjectIdentifier POLICY_RSA2048
public static final org.bouncycastle.asn1.ASN1ObjectIdentifier POLICY_RSA4096
public static final String VERSION
public TSAservice()
public TSAservice(Properties config) throws IOException
ConfigManager
. For
example, if you did not want to read the property file
com.digistamp.properties
from disk then instead you could
supply those properties on this constructor.IOException
public Properties getConfiguration()
Properties
current TSA Configuration.
By default, this would be the API toolkit defaults, overlaid with
configuration in file com.digistamp.properties if it was found.public TsResponse getTimestamp(TsRequest request)
public TsResponse getTimestamp(TsRequest request, String user, String password) throws IOException
IOException
public ArrayList<String> getTSAs()
public void setConfiguration(Properties newDefault) throws IOException
Properties
TSA Configuration.IOException
public void setTSAs(ArrayList<String> tsaSubdomains)
tsaSubdomains
- (e.g. "www" or "tsa1")public String toString()
toString
in class Object