Filter
Exclude
Time range
-
Near
Interesting point about reentrancy attacks, but I would point out that it is inherently too limiting to ask for one smart contract to finish all of its execution before going to the other. I think they are better ways to do it. Also, I think the whole design of token standards made the reentrancy issues worse, like having tokens as SmartContracts and every transfer or action is mandatory to call a SC, which internally can do anything, is certainly the biggest enabler of reentrancy attacks. SCs need to call other SCs in their execution, like it is so common to do it in any software environment. But you need a smart way to do it, and a safe environment for developers. There are a few ways to limit or completely eliminate reentrancy attacks. If you have native assets and transfers do not call another SC, then you resolve 95% of the cases. If you have storageLocks for critical places, then you solve for every single other thing. That’s how it is done in other software environments. StorageV2 on SpaceCraftSDK is going to have native storage locks and inheritance model, baked in, to make contracts secure mathematically as well. SpaceVM and MultiversX has native assets and atomic multitransfer capabilities as the foundation, and there was zero reentrancy attacks on the chain.
A race condition is a situation where two threads access the same value in memory at the same timemutably and non-atomically. Mutably means each thread may change the value. Non-atomically means the mutation consists of multiple steps that can be interrupted in the middle. If thread 1 is interrupted in the middle of mutating the value, and the CPU switches to thread 2, then thread 2 is given an unfinalized, invalid state of that value, which leads to undefined behavior. I realized this is the same as reentrancy while watching in this video youtu.be/QAzuAn3nFGo?t=255 where it presents a "naive" way of mitigating race conditions, that appears to me as identical to OpenZeppelin's ReentrencyGuard (github.com/OpenZeppelin/open…). An EVM contract (let's call it "A") may call into another contract ("B"); this is equivalent to a CPU switches to a different thread. Contract B may then call back to contract A; this is equivalent to thread 2 accessing the same memory value as thread 1 was mutating. If contract A calls B while in the middle of mutating a value in its own state, it exposes the value to B in an unfinalized, invalid state. In real hardware, it's not possible to prevent race conditions with purely software-level solutions. This is because modern compilers and CPUs may apply optimizations to software code, such as reordering instructions, that breaks the solution. Instead, hardware-level solutions such as atomic instructions are necessary. However in specific blockchain VMs, e.g. EVM which executes instructions sequentially without reordering, purely software solutions are possible. Other VMs, such as @CosmWasm, and our grug-vm that @dango is based on, a contract is not allowed to call another contract (i.e. "switching to another thread") until is finishes mutating its own state and fully exits. Thus, reentrancy is fundamentally impossible.
4
30
2,171
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2EomWpW #Storage #StorageLocks #StorageUnit #Padlocks #SecureLocks

2
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2iPaC8j #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

1
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2Ab5bqv #CyberMonday #CyberMondayDeals #BestStorageLocks #StorageLocks

1
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2zm9qk5 #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

10 Best Storage Locks To Secure Your Storage Unit buff.ly/2mMmskG #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

1
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2zzO1D6 #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

1
3
Here at QuikStor Self Storage, security is important! Check out the Best Storage Locks to Secure your Storage Units! #QuikStorSelfStorage #selfstorage #storagelocks bit.ly/2yKeSIZ

10 Best Storage Locks To Secure Your Storage Unit buff.ly/2xK9DwD #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

10 Best Storage Locks To Secure Your Storage Unit buff.ly/2ysaH6V #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

1
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2yswlbw #Storage #StorageUnit #StorageLocks #Stanley #MulTLock #Abus

1
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2yrjSmv #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

1
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2wZkZbt #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

1
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2wEqP2R #Storage #StorageUnit #StorageLocks #Stanley #MulTLock #Abus

1
2
10 Best Storage Locks To Secure Your Storage Unit buff.ly/2gDgIDP #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

10 Best Storage Locks To Secure Your Storage Unit buff.ly/2vXyg4F #StorageUnit #Padlocks #StorageLocks #StorageSecurity #Storage

1
1
NEW POST!! 10 Best Storage Locks To Secure Your Storage Unit buff.ly/2fmsp4I #StorageUnit #Padlocks #StorageLocks #StorageSecurity

1
Selecting #storagelocks - a guide: ow.ly/nkkF302oCYw
1
2