Package COSE

Class EncryptMessage


  • public class EncryptMessage
    extends EncryptCommon
    Author:
    jimsch
    • Constructor Detail

      • EncryptMessage

        public EncryptMessage()
      • EncryptMessage

        public EncryptMessage​(boolean emitTag)
    • Method Detail

      • addRecipient

        public void addRecipient​(Recipient recipient)
      • getRecipient

        public Recipient getRecipient​(int iRecipient)
      • getRecipientCount

        public int getRecipientCount()
      • DecodeFromCBORObject

        public void DecodeFromCBORObject​(com.upokecenter.cbor.CBORObject obj)
                                  throws CoseException
        Description copied from class: Message
        Given a CBOR tree, parse the message. This is an abstract function that is implemented for each different supported COSE message.
        Specified by:
        DecodeFromCBORObject in class Message
        Parameters:
        obj - CBORObject to be converted to a message.
        Throws:
        CoseException - Internal COSE Exception
      • EncodeCBORObject

        protected com.upokecenter.cbor.CBORObject EncodeCBORObject()
                                                            throws CoseException
        Description copied from class: Message
        Encode the COSE message object to a CBORObject tree. This function call will force cryptographic operations to be executed as needed. This is an internal function, as such it does not add the tag on the front and is implemented on a per message object.
        Specified by:
        EncodeCBORObject in class Message
        Returns:
        CBORObject representing the message.
        Throws:
        CoseException - Internal COSE Exception