Approval for NFT transfers is not removed after transfer
The Visor contract's transferERC721 function does not clear the approval for an NFT after transferring it. An approved delegatee can move the NFT out of the contract once, and if the NFT is later re-deposited, the same delegatee can steal it again.
Submitted by cmichel, also found by gpersoon, and pauliax
The Visor.transferERC721 does not reset the approval for the NFT.
An approved delegatee can move the NFT out of the contract once. It could be moved to a market and bought by someone else who then deposits it again to the same vault. The first delegatee can steal the NFT and move it out of the contract a second time.
Recommend resetting the approval on transfer.
We will be mitigating this issue for our next release and before these experimental features are introduced in platform. PR pending
duplicate of above ones and fixed
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
Likely the transfer function failed to reset the approval after moving the NFT, leaving a lingering permission.
Impact
An approved delegatee could steal the NFT a second time if it is re-deposited into the same vault.
What the attacker needed
Approved delegatee; NFT re-deposited into vault
The fix
The approval should be reset on transfer; the project confirmed it was fixed.
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.
When you approve someone to move your NFT, that permission stays until you revoke it. Here, the contract approved a delegatee but never revoked it after moving the NFT, so the delegatee could later take the NFT again if it came back to the contract.
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.