C# 클래스 MpcLib.SecretSharing.BigShamirSharing

Implemenets the threshold secret sharing scheme based on Adi Shamir's method on BigIntegers.
파일 보기 프로젝트 열기: mahdiz/mpclib 1 사용 예제들

공개 메소드들

메소드 설명
GenerateCommitment ( int numShares, BigZp coeffs, System.Numerics.BigInteger prime, MG &witnesses, PolyCommit polyCommit ) : MG
Recombine ( IList sharedSecrets, int polyDeg, System.Numerics.BigInteger prime ) : BigZp
Recombine ( IList sharedSecrets, int polyDeg, System.Numerics.BigInteger prime, bool usePrimitiveRecombine ) : BigZp

Recombines (interpolate) the secret from secret shares.

Share ( BigZp secret, int numPlayers, int polyDeg ) : IList

Calculates the shares of a secret with polynomial of degree t and numPlayers players.

Share ( BigZp secret, int numPlayers, int polyDeg, IList &coeffs ) : IList

Calculates the shares of a secret with polynomial of degree t and numPlayers players. The method also returns the array of coefficients of the polynomial.

비공개 메소드들

메소드 설명
Share ( BigZp secret, int numPlayers, int polyDeg, bool usePrimitiveShare, IList &coeffs ) : IList

Evaluates the shares of secret with polynomial of degree 'polynomDeg' and 'numPlayers' players.

SimpleRecombine ( IList sharedSecrets, int polyDeg, System.Numerics.BigInteger prime ) : BigZp
TruncateVector ( BigZp vector, int toSize ) : BigZp[]

메소드 상세

GenerateCommitment() 공개 정적인 메소드

public static GenerateCommitment ( int numShares, BigZp coeffs, System.Numerics.BigInteger prime, MG &witnesses, PolyCommit polyCommit ) : MG
numShares int
coeffs BigZp
prime System.Numerics.BigInteger
witnesses MG
polyCommit PolyCommit
리턴 MG

Recombine() 공개 정적인 메소드

public static Recombine ( IList sharedSecrets, int polyDeg, System.Numerics.BigInteger prime ) : BigZp
sharedSecrets IList
polyDeg int
prime System.Numerics.BigInteger
리턴 BigZp

Recombine() 공개 정적인 메소드

Recombines (interpolate) the secret from secret shares.
public static Recombine ( IList sharedSecrets, int polyDeg, System.Numerics.BigInteger prime, bool usePrimitiveRecombine ) : BigZp
sharedSecrets IList
polyDeg int
prime System.Numerics.BigInteger
usePrimitiveRecombine bool
리턴 BigZp

Share() 공개 정적인 메소드

Calculates the shares of a secret with polynomial of degree t and numPlayers players.
public static Share ( BigZp secret, int numPlayers, int polyDeg ) : IList
secret BigZp
numPlayers int
polyDeg int
리턴 IList

Share() 공개 정적인 메소드

Calculates the shares of a secret with polynomial of degree t and numPlayers players. The method also returns the array of coefficients of the polynomial.
public static Share ( BigZp secret, int numPlayers, int polyDeg, IList &coeffs ) : IList
secret BigZp
numPlayers int
polyDeg int
coeffs IList
리턴 IList