|
IAIK CMS/SMIME Toolkit Demo API Documentation
Version 6.1 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectdemo.smime.DumpMessage
public class DumpMessage
Simple utility for dumping a message to System.out.
The parts of the message are recursively dumped.
Note that this utility is not thread-safe (i.e. only
one private key can be statically
set to decrypt an encrypted content part.
| Constructor Summary | |
|---|---|
DumpMessage()
Default constructor. |
|
| Method Summary | |
|---|---|
void |
dump(java.lang.Object o)
Dumps the given object (message, part,...) to System.out. |
void |
dumpAuthEncrypted(iaik.smime.AuthEncryptedContent ec,
iaik.cms.KeyIdentifier recipientKeyId)
Dumps the given authenticated encrypted content. |
void |
dumpEncrypted(iaik.smime.EncryptedContent ec,
iaik.cms.KeyIdentifier recipientKeyId)
Dumps the given encrypted content. |
void |
dumpEncrypted(iaik.smime.EncryptedContent ec,
iaik.cms.KeyIdentifier recipientKeyId,
java.security.PrivateKey recipientKey)
Dumps the given encrypted content for the recipient identified by the given recipient key id using the given private recipient decryption key. |
static void |
dumpEncryptedMessage(javax.mail.Message msg)
Dumps the given encrypted message and decrypts the content for the several recipients. |
void |
dumpEnvelope(javax.mail.Message m)
Prints the envelope of a message. |
static void |
dumpMsg(javax.mail.Message msg)
Dumps the given message to System.out. |
void |
dumpPKCS10(iaik.smime.PKCS10Content pkcs10)
Dumps the given PKCS#10 content. |
void |
dumpReceiptContent(iaik.smime.ess.ReceiptContent rc)
Dumps the given signed receipt. |
void |
dumpSigned(iaik.smime.SignedContent sc)
Dumps the given signed content. |
iaik.x509.X509Certificate[] |
getSignerCerts()
Gets the certificates of the signer included in a signed message. |
void |
setRecipientKey(java.security.PrivateKey recipientKey)
Sets the private recipient key to be used to decrypt an encrypted message. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DumpMessage()
| Method Detail |
|---|
public static void dumpMsg(javax.mail.Message msg)
throws java.lang.Exception
msg - the message to be dumped
java.lang.Exception - if an error occurs
public static void dumpEncryptedMessage(javax.mail.Message msg)
throws java.lang.Exception
msg - the message to be dumped
java.lang.Exception - if an error occurspublic void setRecipientKey(java.security.PrivateKey recipientKey)
CMSKeyStore used by the demos
is CMSKeyStore#getRecipientCert(KeyIdentifier) searched
for a recipient decryption key based on the recipient key identifier.
recipientKey - the private key of the recipientpublic iaik.x509.X509Certificate[] getSignerCerts()
null otherwise.
public void dump(java.lang.Object o)
throws java.lang.Exception
o - the object to be dumped
java.lang.Exception - if an error occurs
public void dumpEncrypted(iaik.smime.EncryptedContent ec,
iaik.cms.KeyIdentifier recipientKeyId)
throws java.lang.Exception
ec - the EncryptedContent to be dumpedrecipientKeyId - the id of the recipient key to be used for decrypting the content
java.lang.Exception - if an error occurs
public void dumpEncrypted(iaik.smime.EncryptedContent ec,
iaik.cms.KeyIdentifier recipientKeyId,
java.security.PrivateKey recipientKey)
throws java.lang.Exception
ec - the EncryptedContent to be dumpedrecipientKeyId - the id of the recipient key to be used for decrypting the contentrecipientKey - the private key of the recipient
java.lang.Exception - if an error occurs
public void dumpAuthEncrypted(iaik.smime.AuthEncryptedContent ec,
iaik.cms.KeyIdentifier recipientKeyId)
throws java.lang.Exception
ec - the AuthEncryptedContent to be dumpedrecipientKeyId - the id of the recipient key to be used for decrypting the content
java.lang.Exception - if an error occurs
public void dumpSigned(iaik.smime.SignedContent sc)
throws java.lang.Exception
sc - the SignedContent to be dumped
java.lang.Exception - if an error occurs
public void dumpPKCS10(iaik.smime.PKCS10Content pkcs10)
throws java.lang.Exception
pkcs10 - the PKCS10Content to be dumped
java.lang.Exception - if an error occurs
public void dumpReceiptContent(iaik.smime.ess.ReceiptContent rc)
throws java.lang.Exception
rc - the signed receipt to be dumped
java.lang.Exception - if an error occurs
public void dumpEnvelope(javax.mail.Message m)
throws javax.mail.MessagingException
m - the message
javax.mail.MessagingException - if an error occurs
|
IAIK CMS/SMIME Toolkit Demo API Documentation
Version 6.1 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
|
v6.1 (c) 2002 IAIK, (c) 2003 - 2025 SIC |
|