MCPcopy Create free account
hub / github.com/docknetwork/crypto / randomize

Method randomize

delegatable_credentials/src/set_commitment.rs:358–366  ·  view source on GitHub ↗

Randomize the set commitment and the corresponding opening

(
        mut self,
        mut opening: SetCommitmentOpening<E>,
        randomness: E::ScalarField,
    )

Source from the content-addressed store, hash-verified

356
357 /// Randomize the set commitment and the corresponding opening
358 pub fn randomize(
359 mut self,
360 mut opening: SetCommitmentOpening<E>,
361 randomness: E::ScalarField,
362 ) -> (Self, SetCommitmentOpening<E>) {
363 self.0 = self.0.mul_bigint(randomness.into_bigint()).into_affine();
364 opening.randomize(randomness);
365 (self, opening)
366 }
367
368 /// Create a KZG polynomial commitment to the set in group G1
369 fn commit_in_P1(

Callers 1

checkFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected