IAIK CMS/SMIME Toolkit Demo API Documentation
Version 6.1

demo.cms.tsp
Class TSPServer

java.lang.Object
  extended by demo.cms.tsp.TSPServer

public class TSPServer
extends java.lang.Object

A simple TSP server. Used by the TimeStampDemo.

Version:
File Revision 12
See Also:
TimeStampDemo

Field Summary
static iaik.asn1.ObjectID TSA_POLICY_ID
          TSA policy id.
 
Constructor Summary
TSPServer()
          Creates a TSP server for listening on time stamp requests on port 3188.
TSPServer(int port, java.security.PrivateKey privateKey, iaik.x509.X509Certificate[] certChain, iaik.asn1.structures.AlgorithmID signatureAlgorithm, iaik.asn1.structures.AlgorithmID hashAlgorithm)
          Creates a TSP server.
 
Method Summary
 int getPort()
          Gets the port number the server is listening on.
static void setDebugStream(java.io.OutputStream os)
          Sets a stream to which debugging information shall be printed.
 void start()
          Starts the TSP Server.
 void stop()
          Stops the TSP Server.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TSA_POLICY_ID

public static final iaik.asn1.ObjectID TSA_POLICY_ID
TSA policy id.

Constructor Detail

TSPServer

public TSPServer()
Creates a TSP server for listening on time stamp requests on port 3188. Server key (for response signing) and certificate are read from the IAIK-CMS demo test keystore ("cms.keystore") which can be created by running the SetupCMSKeyStore program.


TSPServer

public TSPServer(int port,
                 java.security.PrivateKey privateKey,
                 iaik.x509.X509Certificate[] certChain,
                 iaik.asn1.structures.AlgorithmID signatureAlgorithm,
                 iaik.asn1.structures.AlgorithmID hashAlgorithm)
Creates a TSP server.

Parameters:
port - the port to listen on (default 3188)
privateKey - the private key of the tsp server to be used for signing the tsp response
certChain - the certificate chain of the server (to be included in the response, if requested)
signatureAlgorithm - the algorithm used for signing the response
hashAlgorithm - algorithm to be used for calculating the signature hash
Method Detail

start

public void start()
Starts the TSP Server.


stop

public void stop()
Stops the TSP Server.


getPort

public int getPort()
Gets the port number the server is listening on.


setDebugStream

public static void setDebugStream(java.io.OutputStream os)
Sets a stream to which debugging information shall be printed.

Parameters:
os - the stream to which to print debugging information or null if no debugging information shall be printed

IAIK CMS/SMIME Toolkit Demo API Documentation
Version 6.1

v6.1
(c) 2002 IAIK, (c) 2003 - 2025 SIC