latest.ipv8.attestation.wallet.irmaexact.gabi.builder

Copyright (c) 2016, Maarten Everts All rights reserved.

This source code has been ported from https://github.com/privacybydesign/gabi The authors of this file are not -in any way- affiliated with the original authors or organizations.

Module Contents

Classes

Issuer

A signature issuer.

IssueCommitmentMessage

JWT commitment information.

IssueSignatureMessage

Issued signature information.

CredentialBuilder

Helper class to create credentials.

Functions

GetProofU(...)

Get the i'th (starting at 0) ProofU instance from a list of proof instances.

GetFirstProofU(...)

Get the first ProofU from a given list of proofs.

challengeContributions(→ list[int])

Aggregate all challenge contributions of a given proof list.

Verify(→ bool)

Verify a list of proofs for a list of public keys.

Challenge(→ int)

Create a challenge.

BuildDistributedProofList(...)

Create a proof list from multiple partial proofs.

BuildProofList(...)

Create a list of U proofs without distributed partial proofs.

commitmentToSecret(→ tuple[int, int])

Create a commitment for a given value.

class latest.ipv8.attestation.wallet.irmaexact.gabi.builder.Issuer(Sk: latest.ipv8.attestation.wallet.irmaexact.gabi.keys.PrivateKey, Pk: latest.ipv8.attestation.wallet.irmaexact.gabi.keys.PublicKey, Context: int)

A signature issuer.

IssueSignature(U: int, attributes: list[int], nonce2: int) IssueSignatureMessage

Generate an issued signature message.

signCommitmentAndAttributes(U: int, attributes: list[int]) latest.ipv8.attestation.wallet.irmaexact.gabi.keys.CLSignature

Sign the commitment to the U value and given attribute values.

randomElementMultiplicativeGroup(modulus: int) int

Generate a random number that is relatively coprime to the modulus.

proveSignature(signature: latest.ipv8.attestation.wallet.irmaexact.gabi.keys.CLSignature, nonce2: int) latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofS

Create a proof of signature issuance.

latest.ipv8.attestation.wallet.irmaexact.gabi.builder.GetProofU(pl: list, n: int) latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofU | None

Get the i’th (starting at 0) ProofU instance from a list of proof instances.

latest.ipv8.attestation.wallet.irmaexact.gabi.builder.GetFirstProofU(pl: list) latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofU | None

Get the first ProofU from a given list of proofs.

latest.ipv8.attestation.wallet.irmaexact.gabi.builder.challengeContributions(pl: list, publicKeys: list[latest.ipv8.attestation.wallet.irmaexact.gabi.keys.PublicKey], context: int, nonce: int) list[int]

Aggregate all challenge contributions of a given proof list.

latest.ipv8.attestation.wallet.irmaexact.gabi.builder.Verify(pl: list, publicKeys: list[latest.ipv8.attestation.wallet.irmaexact.gabi.keys.PublicKey], context: int, nonce: int, issig: bool, keyshareServers: list | None = None) bool

Verify a list of proofs for a list of public keys.

latest.ipv8.attestation.wallet.irmaexact.gabi.builder.Challenge(builders: list[CredentialBuilder], context: int, nonce: int, issig: bool) int

Create a challenge.

latest.ipv8.attestation.wallet.irmaexact.gabi.builder.BuildDistributedProofList(builders: list[CredentialBuilder], challenge: int, proofPs: list[latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofP]) list[latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofU] | None

Create a proof list from multiple partial proofs.

latest.ipv8.attestation.wallet.irmaexact.gabi.builder.BuildProofList(builders: list[CredentialBuilder], context: int, nonce: int, issig: bool) list[latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofU] | None

Create a list of U proofs without distributed partial proofs.

class latest.ipv8.attestation.wallet.irmaexact.gabi.builder.IssueCommitmentMessage(U: int | None, Proofs: list[latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofU] | None, Nonce2: int, ProofPjwt: None = None, ProofPjwts: None = None)

JWT commitment information.

class latest.ipv8.attestation.wallet.irmaexact.gabi.builder.IssueSignatureMessage(Signature: latest.ipv8.attestation.wallet.irmaexact.gabi.keys.CLSignature, Proof: latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofS)

Issued signature information.

latest.ipv8.attestation.wallet.irmaexact.gabi.builder.commitmentToSecret(pk: latest.ipv8.attestation.wallet.irmaexact.gabi.keys.PublicKey, secret: int) tuple[int, int]

Create a commitment for a given value.

class latest.ipv8.attestation.wallet.irmaexact.gabi.builder.CredentialBuilder(pk: latest.ipv8.attestation.wallet.irmaexact.gabi.keys.PublicKey, context: int, secret: int, nonce2: int)

Helper class to create credentials.

CommitToSecretAndProve(nonce1: int) IssueCommitmentMessage

Create a commitment and associated message.

CreateIssueCommitmentMessage(proofs: list[latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofU]) IssueCommitmentMessage

Create the associated message for given U commitments.

ConstructCredential(msg: IssueSignatureMessage, attributes: list[int]) latest.ipv8.attestation.wallet.irmaexact.gabi.credential.Credential | None

Create a credential from the given signature message and our attributes.

proveCommitment(U: int, nonce1: int) latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofU

Create a proof for the commitment to U.

MergeProofPCommitment(commitment: latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofPCommitment) None

Merge in a given commitment to a ProofP.

PublicKey() latest.ipv8.attestation.wallet.irmaexact.gabi.keys.PublicKey

Our public key.

Commit(skRandomizer: int) list[int]

Create a new commitment for the given randomizer value.

CreateProof(challenge: int) latest.ipv8.attestation.wallet.irmaexact.gabi.proofs.ProofU

Create a new proof for U for the given challenge.