Skip to content
Access control Audit finding Beginner

The owner can mint all of the NFTs.

The teamSummon function allows the contract owner to mint an unlimited number of NFTs, contrary to the documented intended limits. If the owner's private key were compromised, an attacker could mint almost all NFTs and destroy the set's value.

Kulk0 Follow

Originally disclosed on Code4rena

Submitted by Kulk0, also found by 0x1f8b, 0xDjango, BowTiedWardens, broccolirob, defsec, Dinddle, dirk_y, hyh, rajatbeladiya, Ruhum, throttle, and unforgiven

ForgottenRunesWarriorsMinter.sol#L257

In ForgottenRunesWarriorsMinter.teamSummon() the owner can mint unrestricted amount of NFTs. This is more of a design issue than an actual bug in my opinion.

Proof of Concept

If the private keys were compromised during the launch the attacker could mint almost all of the NFTs. Normally I wouldn’t say this is an issue but from your documentation, I understand that you are not planning to use a multi-sig wallet for the owner of the contracts. I definitely don’t want to say that you are incompetent and you can’t store your private keys safely but private keys are getting compromised very often in this space.

Recommended Mitigation Steps

Limit how many NFTs can the owner mint. So even if the private keys were compromised the attacker couldn’t destroy the entire set by minting thousands of the NFTs to himself making the entire set worth nothing.

I also think this will help with the trust of the protocol since the buyers will know exactly how many NFTs can the Dev Team mint for themselves.

cryppadotta (Forgotten Runes) acknowledged and commented:

This is true, but by design. It’s a risk for minters, but it would be obvious, so we’re economically disincentivized to do this. Acknowledged, but not changing it.

gzeon (judge) marked as Invalid and commented:

Sponsor acknowledged centralization risk in README.

dmitriia (warden) commented:

Centralization risk in general is one thing, the ability for unlimited mint, which is easily fixable, is another.

A kind of a boundary state here in my opinion, having ‘acknowledged’ and ‘invalid’ flags in the same time poses some contradiction.

gzeon (judge) reassessed as Medium severity and commented:

Judging this as Med Risk since there are specified amounts of teamSummon in the doc

Forgotten Council DAO Creators Fund (teamSummon): ~333 Team & Partners (teamSummon): ~325 Community Honoraries and Contests (teamSummon): ~50

which is not enforced in the teamSummon function.


The original report as published on Code4rena, by Kulk0. Images and videos are our own copies; raw HTML is shown as text. View it on Code4rena.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

The teamSummon function lacks a cap on the number of NFTs the owner can mint, despite documented intended limits.

Impact

If the owner's private key were compromised, an attacker could mint almost all NFTs, making the entire set worth nothing; the project acknowledged this as a centralization risk but did not change it.

What the attacker needed

Owner's private key compromised

The fix

The teamSummon function should enforce a maximum number of NFTs the owner can mint, matching the documented limits.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

In this NFT project, a special function lets the owner create new tokens. The code does not limit how many the owner can create, even though the project's documentation says there should be a cap. If someone stole the owner's private key, they could create a huge number of tokens and make everyone else's tokens worthless.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More from Forgotten Runes Warrior Guild contest

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.