Zilliqa / marketplace-contracts

GNU General Public License v3.0
2 stars 4 forks source link

RequireAllowedUser to check dest #23

Closed bb111189 closed 2 years ago

bb111189 commented 2 years ago
transition Bid(
  token_address: ByStr20 with contract 
    field royalty_recipient: ByStr20, 
    field royalty_fee_bps: Uint128, 
    field spenders: Map Uint256 ByStr20, 
    field token_owners: Map Uint256 ByStr20 
  end,
  token_id: Uint256,
  amount: Uint128,
  (* `dest` enables buyers to set an address to receive the asset when fulfilling a sell order. *)
  dest: ByStr20
  )
  RequireNotPaused;
  RequireAllowedUser _sender;

I think we should also RequireAllowedUser dest to prevent user from using onramp to bypass the whitelist

ghost commented 2 years ago

nice catch!