at.knowcenter.wag.egov.egiz.sig.connectors.moa
Class EnvelopingBase64MOAConnector

java.lang.Object
  extended byat.knowcenter.wag.egov.egiz.sig.connectors.moa.EnvelopingBase64MOAConnector
All Implemented Interfaces:
Connector

public class EnvelopingBase64MOAConnector
extends Object
implements Connector

Author:
wprinz

Nested Class Summary
static class EnvelopingBase64MOAConnector.Environment
          Holds environment configuration information like templates.
 
Field Summary
protected  EnvelopingBase64MOAConnector.Environment environment
          The environemnt configuration of this connector containing templates and other configurable elements.
protected  ConnectorParameters params
           
 
Constructor Summary
EnvelopingBase64MOAConnector(ConnectorParameters connectorParameters)
          Constructor that builds the configuration environment for this connector according to the given profile.
 
Method Summary
 SignSignatureObject analyzeSignResponse(Properties response_properties)
          Analyzes the sign response xml and extracts the signature data.
 SignatureResponse analyzeVerifyResponse(Properties response_properties)
          Analyzes the verify response string.
 SignSignatureObject doSign(SignatureData data)
          Performs a sign.
 SignatureResponse doVerify(SignatureData data, SignSignatureObject so)
          Performs a verification.
protected  String prepareSignRequest(SignatureData data)
          Prepares the sign request xml to be sent using the sign request template.
 String prepareVerifyRequest(SignatureData data, SignSignatureObject so)
          Prepares the verify request xml to be sent using the verify request template.
 String prepareXMLContent(SignatureData data, SignSignatureObject so)
          Prepares the XML content the holds the actual signature data.
protected  Properties sendRequest(String url, String mode, String request_string)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

environment

protected EnvelopingBase64MOAConnector.Environment environment
The environemnt configuration of this connector containing templates and other configurable elements.


params

protected ConnectorParameters params
Constructor Detail

EnvelopingBase64MOAConnector

public EnvelopingBase64MOAConnector(ConnectorParameters connectorParameters)
                             throws ConnectorException
Constructor that builds the configuration environment for this connector according to the given profile.

If confuguration parameters are not defined on that profile, the default parameters defined in the configuration are used.

Throws:
ConnectorException - f.e.
Method Detail

doSign

public SignSignatureObject doSign(SignatureData data)
                           throws ConnectorException
Description copied from interface: Connector
Performs a sign.

Specified by:
doSign in interface Connector
Parameters:
data - The data to be signed.
Returns:
Returns the signature object containing the signature data.
Throws:
ConnectorException - Thrown if something goes wrong.
See Also:
Connector.doSign(at.knowcenter.wag.egov.egiz.sig.SignatureData)

doVerify

public SignatureResponse doVerify(SignatureData data,
                                  SignSignatureObject so)
                           throws ConnectorException
Description copied from interface: Connector
Performs a verification.

Specified by:
doVerify in interface Connector
Parameters:
data - The data to be verified.
so - The signature object with the signature information.
Returns:
Returns the SignatureResponse with the result of the verification.
Throws:
ConnectorException - Thrown if something goes wrong.
See Also:
Connector.doVerify(at.knowcenter.wag.egov.egiz.sig.SignatureData, at.knowcenter.wag.egov.egiz.sig.connectors.bku.SignSignatureObject)

sendRequest

protected Properties sendRequest(String url,
                                 String mode,
                                 String request_string)
                          throws ConnectorException
Throws:
ConnectorException

prepareSignRequest

protected String prepareSignRequest(SignatureData data)
                             throws ConnectorException
Prepares the sign request xml to be sent using the sign request template.

Parameters:
data - The SignatureData.
Returns:
Returns the sign request xml to be sent.
Throws:
ConnectorException - f.e.

prepareVerifyRequest

public String prepareVerifyRequest(SignatureData data,
                                   SignSignatureObject so)
                            throws ConnectorException
Prepares the verify request xml to be sent using the verify request template.

Parameters:
data - The SignatureData.
so - The signature information object.
Returns:
Returns the verify request xml to be sent.
Throws:
ConnectorException - f.e.

analyzeSignResponse

public SignSignatureObject analyzeSignResponse(Properties response_properties)
                                        throws ConnectorException
Analyzes the sign response xml and extracts the signature data.

Parameters:
response_properties - The response properties containing the response String and transport related information.
Returns:
Returns the extracted data encapsulated in a SignatureObject.
Throws:
ConnectorException - f.e.

analyzeVerifyResponse

public SignatureResponse analyzeVerifyResponse(Properties response_properties)
                                        throws ConnectorException
Analyzes the verify response string.

Parameters:
response_properties - The response properties containing the response XML.
Returns:
Returns the SignatureResponse containing the verification result.
Throws:
ConnectorException - f.e.

prepareXMLContent

public String prepareXMLContent(SignatureData data,
                                SignSignatureObject so)
                         throws ConnectorException
Prepares the XML content the holds the actual signature data.

This strongly rebuilds the XML content as retuned from a sign request.

Parameters:
data - The data.
so - The signature object containing the signature information.
Returns:
Returns the XML content.
Throws:
ConnectorException - f.e.


Copyright © 2006-2010. All Rights Reserved.