Class PrivateMessage
java.lang.Object
org.bouncycastle.mls.codec.PrivateMessage
- All Implemented Interfaces:
MLSInputStream.Readable, MLSOutputStream.Writable
public class PrivateMessage
extends Object
implements MLSInputStream.Readable, MLSOutputStream.Writable
-
Constructor Summary
ConstructorsConstructorDescriptionPrivateMessage(byte[] group_id, long epoch, ContentType content_type, byte[] authenticated_data, byte[] encrypted_sender_data, byte[] ciphertext) -
Method Summary
Modifier and TypeMethodDescriptionstatic PrivateMessageprotect(AuthenticatedContent auth, MlsCipherSuite suite, GroupKeySet keys, byte[] senderDataSecretBytes, int paddingSize) unprotect(MlsCipherSuite suite, GroupKeySet keys, byte[] senderDataSecretBytes) voidwriteTo(MLSOutputStream stream)
-
Constructor Details
-
PrivateMessage
public PrivateMessage(byte[] group_id, long epoch, ContentType content_type, byte[] authenticated_data, byte[] encrypted_sender_data, byte[] ciphertext)
-
-
Method Details
-
protect
public static PrivateMessage protect(AuthenticatedContent auth, MlsCipherSuite suite, GroupKeySet keys, byte[] senderDataSecretBytes, int paddingSize) throws IOException, IllegalAccessException, org.bouncycastle.crypto.InvalidCipherTextException - Throws:
IOExceptionIllegalAccessExceptionorg.bouncycastle.crypto.InvalidCipherTextException
-
unprotect
public AuthenticatedContent unprotect(MlsCipherSuite suite, GroupKeySet keys, byte[] senderDataSecretBytes) throws Exception - Throws:
Exception
-
writeTo
- Specified by:
writeToin interfaceMLSOutputStream.Writable- Throws:
IOException
-