4 ms·
> If you send an invalid signature from a non-guardian, the condition also resolves to true. Huh? That resolves to false && false, which equals false.
by theli0nheart 5y ago
> If you send an invalid signature from a non-guardian, the condition also resolves to true.
Huh? That resolves to false && false, which equals false.
- bvanheu 5y agoI think dannyw meant something like this: # This function is defined by the system def validSignature(sig): return false # This function is defined by the system def isSignaturefromGuardian(sig): if sig.validator == "guardian": return true return false # A bug in the system compared both return values if validSignature(tx.sig) == signatureFromGuardian(tx.sig): approve() ```