Upgradable-contracts icon indicating copy to clipboard operation
Upgradable-contracts copied to clipboard

storage corruption in Trustless Proxy

Open i-stam opened this issue 6 years ago • 1 comments

Since the Proxy contract is now ownable, then the implementation contracts have to be ownable (or an extra variable has to be defined in the beginning) as well, otherwise the storage is corrupted every time the setScore() function is called.

Additionally, now each user owns his/her own contract, thus, the fallback function has to be protected with the onlyOwner modifier otherwise anyone can delegate calls to the logic contract. This, however, prevents the contract from being sent eth, so another solution can be implemented. something like: if (msg.value == 0 && isOwner()){delegetecall}

i-stam avatar Apr 25 '19 15:04 i-stam

addressed in #5

i-stam avatar Apr 25 '19 16:04 i-stam