ristretto255_scalar_reduce example


        $h = array_fill(0, 64, 0);
        $h_be = self::stringToIntArray(
            self::h2c_string_to_hash(
                self::HASH_SC_L, $ctx$msg$hash_alg
            )
        );

        for ($i = 0; $i < self::HASH_SC_L; ++$i) {
            $h[$i] = $h_be[self::HASH_SC_L - 1 - $i];
        }
        return self::ristretto255_scalar_reduce(self::intArrayToString($h));
    }

    /** * @param string $s * @return string */
    public static function ristretto255_scalar_reduce($s)
    {
        return self::sc_reduce($s);
    }

    

if (!is_callable('sodium_crypto_core_ristretto255_scalar_reduce')) {
    /** * @see ParagonIE_Sodium_Compat::ristretto255_scalar_reduce() * * @param string $s * @return string * @throws SodiumException */
    function sodium_crypto_core_ristretto255_scalar_reduce($s)
    {
        return ParagonIE_Sodium_Compat::ristretto255_scalar_reduce($s, true);
    }
}
if (!is_callable('sodium_crypto_core_ristretto255_scalar_sub')) {
    /** * @see ParagonIE_Sodium_Compat::ristretto255_scalar_sub() * * @param string $x * @param string $y * @return string * @throws SodiumException */
    
Home | Imprint | This part of the site doesn't use cookies.