diff --git a/src/abstract/modular.ts b/src/abstract/modular.ts index 3592cff..4265873 100644 --- a/src/abstract/modular.ts +++ b/src/abstract/modular.ts @@ -265,6 +265,11 @@ export function validateField(field: IField) { } // Generic field functions + +/** + * Same as `pow` but for Fp: non-constant-time. + * Unsafe in some contexts: uses ladder, so can expose bigint bits. + */ export function FpPow(f: IField, num: T, power: bigint): T { // Should have same speed as pow for bigints // TODO: benchmark!