Interface SecretSplitter
-
- All Known Implementing Classes:
ShamirSecretSplitter
public interface SecretSplitterSecret sharing (also called secret splitting) refers to methods for distributing a secret among a group. In this process, no individual holds any intelligible information about the secret. However, when a sufficient number of individuals combine their 'shares', the secret can be reconstructed.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description SplitSecretresplit(byte[] secret, int m, int n)Creates secret shares from a given secret.SplitSecretsplit(int m, int n)Creates secret shares.SplitSecretsplitAround(SecretShare s, int m, int n)Creates secret shares from a given secret share.
-
-
-
Method Detail
-
split
SplitSecret split(int m, int n)
Creates secret shares. The secret will be divided into shares, where the secret has a length of L bytes.- Parameters:
m- A threshold number of sharesn- Total number of shares- Returns:
- An array of
byte[][]representing the generated secret shares for m users with l bytes each.
-
splitAround
SplitSecret splitAround(SecretShare s, int m, int n) throws java.io.IOException
Creates secret shares from a given secret share. The secret will be divided into shares, where the secret has a length of L bytes.- Parameters:
m- A threshold number of sharesn- Total number of shares- Returns:
- An array of
byte[][]representing the generated secret shares for m users with l bytes each. - Throws:
java.io.IOException
-
resplit
SplitSecret resplit(byte[] secret, int m, int n)
Creates secret shares from a given secret. The secret will be divided into shares, where the secret has a length of L bytes.- Parameters:
m- A threshold number of sharesn- Total number of shares- Returns:
- An array of
byte[][]representing the generated secret shares for m users with l bytes each.
-
-