OpenTechne / Smartrental-hackaton-eth-prague-2024

The Ultimate Gateway to On-Chain Rentals - Built at ETHPrague 2024
0 stars 1 forks source link

Monthly payment must be bigger than 0. #8

Closed Ethanol48 closed 5 months ago

Ethanol48 commented 5 months ago

If the contract has the value 0, the tenant can abuse this, the contract can't be liquidate it, because of a 0 division error the tenant could pay 0 every month, leaving the landlord without the capacity of liquidating the contract or if ending the contract the tenant will always gain, in case of normal rental period, the tenant will receive the down payment or in case of cancelling the contract by the landlord the tenant will receive the down payment and a compensation.

With the current structure of the contract the tenant could deploy a contract assigning an arbitrary landlord, and creating a contract, that is accepted by himself and gives the possibility for the landlord loose funds.

Ethanol48 commented 5 months ago

The structure of the contract was changed making it necessary for the landlord to accept the contract