Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MiMC can't be instantiated with bls12_377 #1308

Open
mkobelt opened this issue May 9, 2023 · 0 comments
Open

MiMC can't be instantiated with bls12_377 #1308

mkobelt opened this issue May 9, 2023 · 0 comments

Comments

@mkobelt
Copy link

mkobelt commented May 9, 2023

Description

Compiling a program using MiMC and bls12_377 as the curve choice fails with

$ZOKRATES_STDLIB/hashes/mimc7/mimc7.zok:1:1
	Expression `20888961410941983456478427210666206549300505294776164667214940546594746570981` of type `{integer}` cannot be assigned to constant `C` of type `field[91]`

because the integer can't be represented in the curve's scalar field.

Environment

  • Compiler version: 0.8.7
  • Operating system: Manjaro

Steps to Reproduce

from "hashes/mimc7/mimc7" import main as mimc;

def main(private field preImage) -> field {
    return mimc::<10>(preImage, 0);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant