Compute the Kronecker symbol (a/b), a generalization of the Jacobi symbol.

Synopsis

Declared in <openssl/bn.h>

int
BN_kronecker(
    BIGNUM const* a,
    BIGNUM const* b,
    BN_CTX* ctx);

Return Value

‐1, 0, or 1 for a valid symbol, or ‐2 on error.

Parameters

Name

Description

a

Numerator.

b

Denominator.

ctx

BN_CTX scratch space.

Created with MrDocs