org.webdocwf.util.smime.cms
Class RecipientInfos

java.lang.Object
  |
  +--org.webdocwf.util.smime.der.DERObject
        |
        +--org.webdocwf.util.smime.der.DERSetPr
              |
              +--org.webdocwf.util.smime.cms.RecipientInfos

public class RecipientInfos
extends DERSetPr

RecipientInfos class is DER encoded container, represented in ASN.1 notation according to RFC2630, used for storing individual information needed for all recipients of encrypted message. This information, beside other information, contain specifically encrypted symmetric key for all particular recipients.

RecipientInfos ::= SET OF RecipientInfo

RecipientInfo ::= CHOICE {
ktri KeyTransRecipientInfo,
kari [1] KeyAgreeRecipientInfo,
kekri [2] KEKRecipientInfo }

KeyTransRecipientInfo ::= SEQUENCE {
version CMSVersion, -- always set to 0 or 2
rid RecipientIdentifier,
keyEncryptionAlgorithm KeyEncryptionAlgorithmIdentifier,
encryptedKey EncryptedKey }


Constructor Summary
RecipientInfos(byte[] symKey0)
          Input information for all recipients is the same: symmetric key.
 
Method Summary
 void addRecipient(java.security.cert.X509Certificate cert0)
          Adds Recipient via Key Transport Recipient Infos.
 
Methods inherited from class org.webdocwf.util.smime.der.DERSetPr
addContent
 
Methods inherited from class org.webdocwf.util.smime.der.DERObject
getContentOctets, getContentPartSize, getDEREncoded, getIdentifierOctet, getLengthOctets, getLengthPartSize, getTagClassType, getTagComplexity, getTagTypeNumber, getTotalSize
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RecipientInfos

public RecipientInfos(byte[] symKey0)
               throws SMIMEException
Input information for all recipients is the same: symmetric key. This constructor is advisable to use.
Parameters:
symKey0 - symmetric key represented as byte array
Throws:
SMIMEException - thrown by super class constructor.
Method Detail

addRecipient

public void addRecipient(java.security.cert.X509Certificate cert0)
                  throws SMIMEException
Adds Recipient via Key Transport Recipient Infos. X509 certificate is used to obtain all information needed for construction and organise information about particular recipient of encrypted message.
Parameters:
cert0 - X509 certificate of partial recipient
Throws:
SMIMEException - thrown in super class addContent method.


Copyright © 2002-2002 Together Teamlösungen. All Rights Reserved.