| Modifier and Type | Method and Description |
|---|---|
void |
Attribute.addAttribute(com.upokecenter.cbor.CBORObject label,
com.upokecenter.cbor.CBORObject value,
int where)
Set an attribute in the COSE object.
|
void |
Attribute.addAttribute(HeaderKeys label,
byte[] value,
int where)
Set an attribute in the COSE object.
|
void |
Attribute.addAttribute(HeaderKeys label,
com.upokecenter.cbor.CBORObject value,
int where)
Set an attribute in the COSE object.
|
void |
Attribute.AddProtected(com.upokecenter.cbor.CBORObject label,
com.upokecenter.cbor.CBORObject value)
Deprecated.
As of COSE 0.9.0, use addAttribute(CBORObject, CBORObject, Attribute.PROTECTED);
|
void |
Attribute.AddProtected(HeaderKeys label,
byte[] value)
Deprecated.
As of COSE 0.9.0, use addAttribute(HeaderKeys, byte[], Attribute.PROTECTED);
|
void |
Attribute.AddProtected(HeaderKeys label,
com.upokecenter.cbor.CBORObject value)
Deprecated.
As of COSE 0.9.0, use addAttribute(HeaderKeys, CBORObject, Attribute.PROTECTED);
|
void |
MACMessage.addRecipient(Recipient recipient) |
void |
Attribute.AddUnprotected(com.upokecenter.cbor.CBORObject label,
com.upokecenter.cbor.CBORObject value)
Deprecated.
As of COSE 0.9.1, use addAttribute(HeaderKeys, byte[], Attribute.UNPROTECTED);
|
void |
Attribute.AddUnprotected(HeaderKeys label,
byte[] value)
Deprecated.
As of COSE 0.9.1, use addAttribute(HeaderKeys, byte[], Attribute.UNPROTECTED);
|
void |
Attribute.AddUnprotected(HeaderKeys label,
com.upokecenter.cbor.CBORObject value)
Deprecated.
As of COSE 0.9.1, use addAttribute(HeaderKeys, byte[], Attribute.UNPROTECTED);
|
protected byte[] |
MacCommon.AES_CBC_MAC(AlgorithmID alg,
byte[] rgbKey) |
PrivateKey |
OneKey.AsPrivateKey()
Return a java.security.PrivateKey that is the same as the OneKey key
|
PublicKey |
OneKey.AsPublicKey()
Return a java.security.PublicKey that is the same as the OneKey key
|
void |
MACMessage.Create() |
void |
MAC0Message.Create(byte[] rgbKey) |
protected void |
MacCommon.CreateWithKey(byte[] rgbKey) |
static Message |
Message.DecodeFromBytes(byte[] rgbData)
Decode a COSE message object.
|
void |
CounterSign.DecodeFromBytes(byte[] rgb) |
static Message |
Message.DecodeFromBytes(byte[] rgbData,
MessageTag defaultTag)
Decode a COSE message object.
|
protected void |
SignMessage.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject obj)
Internal function used in creating a SignMessage object from a byte string.
|
protected void |
Signer.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject obj)
Internal function used in creating a Sign1Message object from a byte string.
|
protected void |
Sign1Message.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject messageObject)
Internal function used in creating a Sign1Message object from a byte string.
|
void |
Recipient.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject objRecipient) |
protected abstract void |
Message.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject messageObject)
Given a CBOR tree, parse the message.
|
void |
MACMessage.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject obj) |
void |
MAC0Message.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject obj) |
void |
EncryptMessage.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject obj) |
void |
Encrypt0Message.DecodeFromCBORObject(com.upokecenter.cbor.CBORObject obj) |
byte[] |
Recipient.decrypt(AlgorithmID algCEK,
Recipient recip) |
byte[] |
Encrypt0Message.decrypt(byte[] rgbKey)
Decrypt the message using the passed in key.
|
byte[] |
EncryptMessage.decrypt(Recipient whom) |
protected byte[] |
EncryptCommon.decryptWithKey(byte[] rgbKey) |
protected com.upokecenter.cbor.CBORObject |
SignMessage.EncodeCBORObject()
Internal function used to create a serialization of a COSE_Sign message
|
protected com.upokecenter.cbor.CBORObject |
Sign1Message.EncodeCBORObject()
Internal function used to create a serialization of a COSE_Sign1 message
|
protected com.upokecenter.cbor.CBORObject |
Recipient.EncodeCBORObject() |
protected abstract com.upokecenter.cbor.CBORObject |
Message.EncodeCBORObject()
Encode the COSE message object to a CBORObject tree.
|
protected com.upokecenter.cbor.CBORObject |
MACMessage.EncodeCBORObject() |
protected com.upokecenter.cbor.CBORObject |
MAC0Message.EncodeCBORObject() |
protected com.upokecenter.cbor.CBORObject |
EncryptMessage.EncodeCBORObject() |
protected com.upokecenter.cbor.CBORObject |
Encrypt0Message.EncodeCBORObject()
Internal function used to construct the CBORObject
|
static byte[] |
ASN1.EncodePKCS8(byte[] oid,
byte[] keyBytes,
byte[] spki) |
static byte[] |
ASN1.EncodeSignature(byte[] r,
byte[] s) |
static byte[] |
ASN1.EncodeSubjectPublicKeyInfo(byte[] oid,
byte[] keyBytes)
Encode a subject public key info structure from an oid and the data bytes
for the key
|
byte[] |
Message.EncodeToBytes()
Encode the message to a byte array.
|
byte[] |
CounterSign.EncodeToBytes() |
protected com.upokecenter.cbor.CBORObject |
Signer.EncodeToCBORObject()
Internal function used to create a serialization of a COSE_Sign1 message
|
com.upokecenter.cbor.CBORObject |
Message.EncodeToCBORObject()
Encode the COSE message object to a CBORObject tree.
|
void |
Recipient.encrypt() |
void |
EncryptMessage.encrypt() |
void |
Encrypt0Message.encrypt(byte[] rgbKey)
Encrypt the message using the passed in key.
|
static AlgorithmID |
AlgorithmID.FromCBOR(com.upokecenter.cbor.CBORObject obj) |
static MessageTag |
MessageTag.FromInt(int i) |
static OneKey |
OneKey.generateKey(AlgorithmID algorithm) |
static OneKey |
OneKey.generateKey(com.upokecenter.cbor.CBORObject curve) |
com.upokecenter.cbor.CBORObject |
OneKey.get(com.upokecenter.cbor.CBORObject keyValue) |
ECGenParameterSpec |
OneKey.GetCurve2() |
byte[] |
EncryptCommon.getEncryptedContent()
Used to obtain the encrypted content for the cases where detached content
is requested.
|
byte[] |
Recipient.getKey(AlgorithmID algCEK) |
int |
Recipient.getRecipientType() |
void |
Attribute.removeAttribute(com.upokecenter.cbor.CBORObject label)
Remove an attribute from the set of all attribute maps.
|
void |
Attribute.removeAttribute(HeaderKeys label)
Remove an attribute from the set of all attribute maps.
|
void |
Recipient.SetKey(com.upokecenter.cbor.CBORObject key)
Deprecated.
In COSE 0.9.1, use SetKey(OneKey)
|
void |
Signer.setKey(OneKey keyIn)
Set a key object on a signer
|
void |
Recipient.SetSenderKey(com.upokecenter.cbor.CBORObject key)
Deprecated.
|
void |
SignMessage.sign()
Causes a signature to be created for every signer that does not already have one.
|
void |
Signer.sign(byte[] rgbBodyProtected,
byte[] rgbContent) |
void |
CounterSign.Sign(Message message) |
void |
Sign1Message.sign(OneKey key)
Create a signature for the message if one does not exist.
|
protected boolean |
MacCommon.Validate(byte[] rgbKey) |
boolean |
MAC0Message.Validate(byte[] rgbKey) |
boolean |
Signer.validate(byte[] rgbBodyProtected,
byte[] rgbContent) |
boolean |
CounterSign.Validate(Message message) |
boolean |
Sign1Message.validate(OneKey cnKey)
Validate the signature on the message using the passed in key.
|
boolean |
MACMessage.Validate(Recipient recipientToUse) |
boolean |
SignMessage.validate(Signer signerToUse)
Validate the signature on a message for a specific signer.
|
| Constructor and Description |
|---|
CounterSign(byte[] rgb) |
OneKey(com.upokecenter.cbor.CBORObject keyData) |
COSE for Java documentation, generatedin 2018.