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

Recusion / AVM trace is unlimited #5026

Open
Rumata888 opened this issue May 13, 2024 · 0 comments
Open

Recusion / AVM trace is unlimited #5026

Rumata888 opened this issue May 13, 2024 · 0 comments
Labels
bug Something isn't working security

Comments

@Rumata888
Copy link
Collaborator

Aim

I was testing a function on an edgecase, but it kept running forever.

Expected Behavior

There should be a limit on the recursion and separately on the AVM trace length to avoid unbounded computation and draining resources.

Bug

Computation is unbounded.

To Reproduce

The following code allows to DoS the prover.

unconstrained fn recurse() {
        recurse();
    }
    #[test]
    fn test_recurse() {
        recurse();
    }

Run this test

Project Impact

Nice-to-have

Impact Context

No response

Workaround

None

Workaround Description

No response

Additional Context

No response

Installation Method

Compiled from source

Nargo Version

nargo version = 0.29.0 noirc version = 0.29.0+b776d287db096b657e3afa12da9ae18a803a72ea (git version hash: e7e0fa5, is dirty: true)

NoirJS Version

No response

Would you like to submit a PR for this Issue?

None

Support Needs

No response

@Rumata888 Rumata888 added bug Something isn't working security labels May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working security
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant