Oracle Security Developer Tools CMS Java API Reference
10g Release 2 (10.1.2.0.2)

B15564-01


oracle.security.crypto.cms
Class CMSEnvelopedDataInputConnector

java.lang.Object
  extended byoracle.security.crypto.cms.CMSEnvelopedDataInputConnector

All Implemented Interfaces:
CMSInputConnector

public class CMSEnvelopedDataInputConnector
extends java.lang.Object
implements CMSInputConnector

A CMSEnvelopedDataInputConnector is used in place of a CMSEnvelopedDataInputStream when reading nested CMS objects containing enveloped-data structures.

A CMSEnvelopedDataInputConnector is essentially a input stream filter that unwraps the CMS enveloped-data structure from the data read in. A CMSEnvelopedDataInputConnector expects the Content field of the CMS ContentInfo structure i.e. the underlying input stream must be positioned just after the explicit [0] tag wrapper.

See Also:
CMSInputConnector, CMSEnvelopedDataInputStream

Constructor Summary
CMSEnvelopedDataInputConnector(CMSInputConnector conn, PrivateKey recipientPrivateKey, oracle.security.crypto.cert.X509 recipientCert)
Creates a CMSEnvelopedDataInputConnector.
CMSEnvelopedDataInputConnector(java.io.InputStream in, PrivateKey recipientPrivateKey, oracle.security.crypto.cert.X509 recipientCert)
Creates a CMSEnvelopedDataInputConnector.

Method Summary
ASN1ObjectID getEnclosedContentType()
Returns the content type of the encrypted content.
java.io.InputStream getInputStream()
Returns the input stream governing this input connector.

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

CMSEnvelopedDataInputConnector

public CMSEnvelopedDataInputConnector(java.io.InputStream in,
                                      PrivateKey recipientPrivateKey,
                                      oracle.security.crypto.cert.X509 recipientCert)
Creates a CMSEnvelopedDataInputConnector.
Parameters:
in - The underlying input stream.
recipientPrivateKey - The private key of the recipient.
recipientCert - The recipient's certificate.

CMSEnvelopedDataInputConnector

public CMSEnvelopedDataInputConnector(CMSInputConnector conn,
                                      PrivateKey recipientPrivateKey,
                                      oracle.security.crypto.cert.X509 recipientCert)
Creates a CMSEnvelopedDataInputConnector.
Parameters:
conn - The underlying input connector.
recipientPrivateKey - The private key of the recipient.
recipientCert - The recipient's certificate.

Method Detail

getEnclosedContentType

public ASN1ObjectID getEnclosedContentType()
                                    throws java.io.IOException
Returns the content type of the encrypted content.
Specified by:
getEnclosedContentType in interface CMSInputConnector
Returns:
The content type identifier.
Throws:
java.io.IOException - If the encoding is incorrect or an I/O error occurs.

getInputStream

public java.io.InputStream getInputStream()
Returns the input stream governing this input connector.
Specified by:
getInputStream in interface CMSInputConnector
Returns:
The underlying input stream.

Oracle Security Developer Tools CMS Java API Reference
10g Release 2 (10.1.2.0.2)

B15564-01


Copyright © 2005 , Oracle. All rights reserved.