Top Inners Fields Constructors Methods
org.bouncycastle.mls

public Class KeyScheduleEpoch

extends Object
Class Inheritance
Imports
java.io.IOException, java.nio.charset.StandardCharsets, java.security.SecureRandom, java.util.ArrayList, .List, org.bouncycastle.crypto.AsymmetricCipherKeyPair, org.bouncycastle.crypto.hpke.HPKEContext, .HPKEContextWithEncapsulation, org.bouncycastle.crypto.params.AsymmetricKeyParameter, org.bouncycastle.mls.codec.MLSOutputStream, .PreSharedKeyID, org.bouncycastle.mls.crypto.MlsCipherSuite, .Secret, org.bouncycastle.util.Arrays

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
public static class
public static class

Field Summary

Modifier and TypeField and Description
public final Secret
public final Secret
public final Secret
public final Secret
pack-priv final AsymmetricCipherKeyPair
public final Secret
public final GroupKeySet
public final Secret
public Secret
public Secret
public final Secret
public Secret
pack-priv final MlsCipherSuite

Constructor Summary

AccessConstructor and Description
public
KeyScheduleEpoch(MlsCipherSuite suite, Secret initSecret, Secret senderDataSecret, Secret exporterSecret, Secret confirmationKey, Secret membershipKey, Secret resumptionPSK, Secret epochAuthenticator, Secret encryptionSecret, Secret externalSecret, AsymmetricCipherKeyPair externalKeyPair, GroupKeySet groupKeySet, Secret joinerSecret)

public
public
KeyScheduleEpoch(MlsCipherSuite suite, TreeSize treeSize, Secret epochSecret)

public
KeyScheduleEpoch(MlsCipherSuite suite, TreeSize treeSize, Secret joinerSecret, Secret pskSecret, byte[] context)

Method Summary

Modifier and TypeMethod and Description
public byte[]
confirmationTag(byte[] confirmedTranscriptHash)

public KeyScheduleEpoch
copy()

public boolean
equals(Object
the reference object with which to compare.
o
)

Overrides java.lang.Object.equals.

Indicates whether some other object is "equal to" this one.

public static KeyScheduleEpoch
forCreator(MlsCipherSuite suite, byte[] groupContext)

public static KeyScheduleEpoch
public static KeyScheduleEpoch
public static KeyScheduleEpoch
forExternalJoiner(MlsCipherSuite suite, TreeSize treeSize, KeyScheduleEpoch.ExternalInitParams externalInitParams, Secret commitSecret, List<KeyScheduleEpoch.PSKWithSecret> psks, byte[] context)

public GroupKeySet
public AsymmetricKeyParameter
public Secret
public static KeyScheduleEpoch
joiner(MlsCipherSuite suite, byte[] joinerSecret, List<KeyScheduleEpoch.PSKWithSecret> psks, byte[] context)

public byte[]
MLSExporter(String label, byte[] context, int length)

public KeyScheduleEpoch
next(TreeSize treeSize, byte[] externalInit, Secret commitSecret, List<KeyScheduleEpoch.PSKWithSecret> psks, byte[] context)

public byte[]
receiveExternalInit(byte[] kemOut)

public static KeyGeneration
senderDataKeys(MlsCipherSuite suite, byte[] senderDataSecretBytes, byte[] ciphertext)

public void
setJoinerSecret(Secret joinerSecret)

public KeyScheduleEpoch.JoinSecrets
startCommit(Secret commitSecret, List<KeyScheduleEpoch.PSKWithSecret> psks, byte[] context)

public static Secret
Inherited from java.lang.Object:
clonefinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

confirmationKeyback to summary
public final Secret confirmationKey
encryptionSecretback to summary
public final Secret encryptionSecret
epochAuthenticatorback to summary
public final Secret epochAuthenticator
exporterSecretback to summary
public final Secret exporterSecret
externalKeyPairback to summary
pack-priv final AsymmetricCipherKeyPair externalKeyPair
externalSecretback to summary
public final Secret externalSecret
groupKeySetback to summary
public final GroupKeySet groupKeySet
initSecretback to summary
public final Secret initSecret
joinerSecretback to summary
public Secret joinerSecret
membershipKeyback to summary
public Secret membershipKey
resumptionPSKback to summary
public final Secret resumptionPSK
senderDataSecretback to summary
public Secret senderDataSecret
suiteback to summary
pack-priv final MlsCipherSuite suite

Constructor Detail

KeyScheduleEpochback to summary
public KeyScheduleEpoch(MlsCipherSuite suite, Secret initSecret, Secret senderDataSecret, Secret exporterSecret, Secret confirmationKey, Secret membershipKey, Secret resumptionPSK, Secret epochAuthenticator, Secret encryptionSecret, Secret externalSecret, AsymmetricCipherKeyPair externalKeyPair, GroupKeySet groupKeySet, Secret joinerSecret)
KeyScheduleEpochback to summary
public KeyScheduleEpoch(MlsCipherSuite suite) throws IOException, IllegalAccessException
KeyScheduleEpochback to summary
public KeyScheduleEpoch(MlsCipherSuite suite, TreeSize treeSize, Secret epochSecret) throws IOException, IllegalAccessException
KeyScheduleEpochback to summary
public KeyScheduleEpoch(MlsCipherSuite suite, TreeSize treeSize, Secret joinerSecret, Secret pskSecret, byte[] context) throws IOException, IllegalAccessException

Method Detail

confirmationTagback to summary
public byte[] confirmationTag(byte[] confirmedTranscriptHash)
copyback to summary
public KeyScheduleEpoch copy()
equalsback to summary
public boolean equals(Object o)

Overrides java.lang.Object.equals.

Doc from java.lang.Object.equals.

Indicates whether some other object is "equal to" this one.

The equals method implements an equivalence relation on non-null object references:

  • It is reflexive: for any non-null reference value x, x.equals(x) should return true.
  • It is symmetric: for any non-null reference values x and y, x.equals(y) should return true if and only if y.equals(x) returns true.
  • It is transitive: for any non-null reference values x, y, and z, if x.equals(y) returns true and y.equals(z) returns true, then x.equals(z) should return true.
  • It is consistent: for any non-null reference values x and y, multiple invocations of x.equals(y) consistently return true or consistently return false, provided no information used in equals comparisons on the objects is modified.
  • For any non-null reference value x, x.equals(null) should return false.

An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes.

Parameters
o:Object

the reference object with which to compare.

Returns:boolean

true if this object is the same as the obj argument; false otherwise.

Annotations
@Override
forCreatorback to summary
public static KeyScheduleEpoch forCreator(MlsCipherSuite suite, byte[] groupContext) throws IOException, IllegalAccessException
forCreatorback to summary
public static KeyScheduleEpoch forCreator(MlsCipherSuite suite) throws IOException, IllegalAccessException
forCreatorback to summary
public static KeyScheduleEpoch forCreator(MlsCipherSuite suite, SecureRandom rng) throws IOException, IllegalAccessException
forExternalJoinerback to summary
public static KeyScheduleEpoch forExternalJoiner(MlsCipherSuite suite, TreeSize treeSize, KeyScheduleEpoch.ExternalInitParams externalInitParams, Secret commitSecret, List<KeyScheduleEpoch.PSKWithSecret> psks, byte[] context) throws IOException, IllegalAccessException
getEncryptionKeysback to summary
public GroupKeySet getEncryptionKeys(TreeSize size) throws IOException, IllegalAccessException
getExternalPublicKeyback to summary
public AsymmetricKeyParameter getExternalPublicKey()
getJoinerSecretback to summary
public Secret getJoinerSecret()
joinerback to summary
public static KeyScheduleEpoch joiner(MlsCipherSuite suite, byte[] joinerSecret, List<KeyScheduleEpoch.PSKWithSecret> psks, byte[] context) throws IOException, IllegalAccessException
MLSExporterback to summary
public byte[] MLSExporter(String label, byte[] context, int length) throws IOException
nextback to summary
public KeyScheduleEpoch next(TreeSize treeSize, byte[] externalInit, Secret commitSecret, List<KeyScheduleEpoch.PSKWithSecret> psks, byte[] context) throws IOException, IllegalAccessException
receiveExternalInitback to summary
public byte[] receiveExternalInit(byte[] kemOut) throws IOException
senderDataKeysback to summary
public static KeyGeneration senderDataKeys(MlsCipherSuite suite, byte[] senderDataSecretBytes, byte[] ciphertext) throws IOException
setJoinerSecretback to summary
public void setJoinerSecret(Secret joinerSecret)
startCommitback to summary
public KeyScheduleEpoch.JoinSecrets startCommit(Secret commitSecret, List<KeyScheduleEpoch.PSKWithSecret> psks, byte[] context) throws IOException
welcomeSecretback to summary
public static Secret welcomeSecret(MlsCipherSuite suite, byte[] joinerSecret, List<KeyScheduleEpoch.PSKWithSecret> psk) throws IOException
org.bouncycastle.mls back to summary

public Class KeyScheduleEpoch.ExternalInitParams

extends Object
Class Inheritance

Field Summary

Modifier and TypeField and Description
public Secret
public byte[]

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Secret
public byte[]
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

initSecretback to summary
public Secret initSecret
kemOutputback to summary
public byte[] kemOutput

Constructor Detail

ExternalInitParamsback to summary
public ExternalInitParams(MlsCipherSuite suite, AsymmetricKeyParameter externalPub)

Method Detail

getInitSecretback to summary
public Secret getInitSecret()
getKEMOutputback to summary
public byte[] getKEMOutput()
org.bouncycastle.mls back to summary

public Class KeyScheduleEpoch.JoinSecrets

extends Object
Class Inheritance

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class

Field Summary

Modifier and TypeField and Description
public final Secret
private Secret
private final MlsCipherSuite
public Secret
public Secret
public Secret

Constructor Summary

AccessConstructor and Description
public
public
JoinSecrets(MlsCipherSuite suite, Secret joinerSecret, Secret pskSecret)

Method Summary

Modifier and TypeMethod and Description
public KeyScheduleEpoch
complete(TreeSize treeSize, byte[] context)

public static KeyScheduleEpoch.JoinSecrets
forMember(MlsCipherSuite suite, Secret initSecret, Secret commitSecret, Secret pskSecret, byte[] context)

public void
public static Secret
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

joinerSecretback to summary
public final Secret joinerSecret
memberSecretback to summary
private Secret memberSecret
suiteback to summary
private final MlsCipherSuite suite
welcomeKeyback to summary
public Secret welcomeKey
welcomeNonceback to summary
public Secret welcomeNonce
welcomeSecretback to summary
public Secret welcomeSecret

Constructor Detail

JoinSecretsback to summary
public JoinSecrets(MlsCipherSuite suite, Secret joinerSecret, List<KeyScheduleEpoch.PSKWithSecret> psks) throws IOException
JoinSecretsback to summary
public JoinSecrets(MlsCipherSuite suite, Secret joinerSecret, Secret pskSecret) throws IOException

Method Detail

completeback to summary
public KeyScheduleEpoch complete(TreeSize treeSize, byte[] context) throws IOException, IllegalAccessException
forMemberback to summary
public static KeyScheduleEpoch.JoinSecrets forMember(MlsCipherSuite suite, Secret initSecret, Secret commitSecret, Secret pskSecret, byte[] context) throws IOException
injectPskSecretback to summary
public void injectPskSecret(Secret pskSecret) throws IOException
pskSecretback to summary
public static Secret pskSecret(MlsCipherSuite suite, List<KeyScheduleEpoch.PSKWithSecret> psks) throws IOException
org.bouncycastle.mls back to summary

pack-priv Class KeyScheduleEpoch.JoinSecrets.PSKLabel

extends Object
implements Writable
Class Inheritance
All Implemented Interfaces
org.bouncycastle.mls.codec.MLSOutputStream.Writable

Field Summary

Modifier and TypeField and Description
pack-priv short
pack-priv PreSharedKeyID
pack-priv short

Constructor Summary

AccessConstructor and Description
public
PSKLabel(PreSharedKeyID id, short index, short count)

Field Detail

countback to summary
pack-priv short count
idback to summary
pack-priv PreSharedKeyID id
indexback to summary
pack-priv short index

Constructor Detail

PSKLabelback to summary
public PSKLabel(PreSharedKeyID id, short index, short count)

Method Detail

writeToback to summary
public void writeTo(MLSOutputStream stream) throws IOException

Implements org.bouncycastle.mls.codec.MLSOutputStream.Writable.writeTo.

Annotations
@Override
org.bouncycastle.mls back to summary

public Class KeyScheduleEpoch.PSKWithSecret

extends Object
Class Inheritance

Field Summary

Modifier and TypeField and Description
public PreSharedKeyID
public Secret

Constructor Summary

AccessConstructor and Description
public

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

idback to summary
public PreSharedKeyID id
secretback to summary
public Secret secret

Constructor Detail

PSKWithSecretback to summary
public PSKWithSecret(PreSharedKeyID id, Secret secret)