Ejemplo n.º 1
0
 public static Statement ShowCredentialStmt(CredentialPresentation c, GroupElement Z, CoordinatorParameters iparams)
 => new Statement(new GroupElement[, ]
 {
     // public                     Witness terms:
     // point      z               z0              t               a               r
     { Z, iparams.I, O, O, O, O },
     { c.Cx1, Generators.Gx1, Generators.Gx0, c.Cx0, O, O },
     { c.Ca, Generators.Ga, O, O, Generators.Gg, Generators.Gh },
     { c.S, O, O, O, O, Generators.Gs }
 });
Ejemplo n.º 2
0
 public static Knowledge ShowCredential(CredentialPresentation presentation, Scalar z, Credential credential, CoordinatorParameters iparams)
 => new Knowledge(
     ShowCredentialStmt(presentation, z * iparams.I, iparams),
     new ScalarVector(z, (credential.Mac.T * z).Negate(), credential.Mac.T, credential.Amount, credential.Randomness));