hats-finance / SeeR-PM-0x899bc13919880db76edf4ccd72bdfa5dfa666fb7

1 stars 0 forks source link

The users can't repeat a question #23

Open hats-bug-reporter[bot] opened 1 month ago

hats-bug-reporter[bot] commented 1 month ago

Github username: -- Twitter username: -- Submission hash (on-chain): 0x29383166d2d8f7f23359fbdc95549c3065b02aae72f3b1b30050a09761eb8dab Severity: medium

Description: Description:

As we can see in the RealityETH_v3_0 documentation: "/// @param nonce A user-specified nonce used in the question ID. Change it to repeat a question."

A nonce is used to allow the user to repeat the same question, but within the MarketFactory contract the nonce in the function askRealityQuestion is hard-coded to uint256(0) disabling this option.

Attack Scenario:

The users can't repeat a question

xyzseer commented 1 month ago

if the question already exists, it's reused here https://github.com/seer-pm/demo/blob/4e56254cbd071b6f678a108ccdb8660951636d27/contracts/src/MarketFactory.sol#L383