tx · 3JjgjmLLPQ7C9SyYbvFAXKVPw6uadU7qGoVNfmW2bMdS 3NAGTtZz6WpupSN89NZD5rMZwwziZEg4Kx4: -0.01400000 Waves 2021.04.14 23:06 [1482578] smart account 3NAGTtZz6WpupSN89NZD5rMZwwziZEg4Kx4 > SELF 0.00000000 Waves
{ "type": 13, "id": "3JjgjmLLPQ7C9SyYbvFAXKVPw6uadU7qGoVNfmW2bMdS", "fee": 1400000, "feeAssetId": null, "timestamp": 1618430824961, "version": 2, "chainId": 84, "sender": "3NAGTtZz6WpupSN89NZD5rMZwwziZEg4Kx4", "senderPublicKey": "5CqqMkmtXXt35KRH9LdWA3ap6TffPvTT5SHQzYrVFbBw", "proofs": [ "2bbfVwBchQC56UsbNFyWup336m1iR6y5W7iFZ2mhj3tMQYjTYrwdE3N6rvLyVyoaSPXDZzP2kJaXGJYVLFkwFNHC" ], "script": "base64:AAIEAAAAAAAAAAIIAgAAAAgAAAAAEWdvdmVybmFuY2VBZGRyZXNzCQEAAAAHQWRkcmVzcwAAAAEBAAAAGgFUcfFVgbQTJcWNlHB+frBs1+VvhcIsEzy/AAAAAA5mYXJtaW5nQWRkcmVzcwkBAAAAB0FkZHJlc3MAAAABAQAAABoBVCnPuY1cs6Yc+wrxHZMThlFbSyWhkjBpIQAAAAANb3JhY2xlQWRkcmVzcwkBAAAAB0FkZHJlc3MAAAABAQAAABoBVBfZTOgGKCvAkhITbti12MPHuaZxMGcpTwAAAAALYWRtaW5JbnZva2UBAAAAIATPdeVk0MEPTme5HxNkxBoN6oQkQjF9M5BdQFgKnZNKAAAAAAxhZG1pblB1YktleTEBAAAAIATPdeVk0MEPTme5HxNkxBoN6oQkQjF9M5BdQFgKnZNKAAAAAAxhZG1pblB1YktleTIBAAAAIATPdeVk0MEPTme5HxNkxBoN6oQkQjF9M5BdQFgKnZNKAAAAAAxhZG1pblB1YktleTMBAAAAIATPdeVk0MEPTme5HxNkxBoN6oQkQjF9M5BdQFgKnZNKAAAAABFrZXlQcm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eGNoYW5nZUNhbGwGBQAAAA1pc0FpcmRyb3BDYWxsCQAAAAAAAAIJAAGQAAAAAQgFAAAABmludm9rZQAAAAhwYXltZW50cwAAAAAAAAAAAQcGAwMFAAAAE2lzVXBkYXRlV2VpZ2h0c0NhbGwGBQAAABRpc1VwZGF0ZVBvb2xJbnRlcmVzdAkAAAAAAAACCQABkAAAAAEIBQAAAAZpbnZva2UAAAAIcGF5bWVudHMAAAAAAAAAAAAHCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleZkJ6OI=", "height": 1482578, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: DYphfWfjJXVu3wCLucbzkzmWXC3D9aC8Ks2xos3uFBDg Next: CjqbT5fuKrCyNB32MTJ4VNzZorHre1f7wLsKjDTyy64Y Diff:
Old | New | Differences | |
---|---|---|---|
30 | 30 | let isUpdateWeightsCall = if ((invoke.dApp == governanceAddress)) | |
31 | 31 | then (invoke.function == "updateWeights") | |
32 | 32 | else false | |
33 | - | let isUpdatePoolInterest = if ((invoke.dApp == | |
33 | + | let isUpdatePoolInterest = if ((invoke.dApp == governanceAddress)) | |
34 | 34 | then (invoke.function == "updatePoolInterest") | |
35 | 35 | else false | |
36 | 36 | let signedByAdmin = sigVerify(tx.bodyBytes, tx.proofs[0], adminInvoke) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 4 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let governanceAddress = Address(base58'3MzJZEn6jzxCPaHEfkrXd7FhbjTyVjdRPLS') | |
5 | 5 | ||
6 | 6 | let farmingAddress = Address(base58'3MsjAKkxKjxVU4gC1BpJ1jKmAZyRufUCErC') | |
7 | 7 | ||
8 | 8 | let oracleAddress = Address(base58'3Mr6BddWEDfzKwNabpYbyd8Qos8LGEAAUvi') | |
9 | 9 | ||
10 | 10 | let adminInvoke = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
11 | 11 | ||
12 | 12 | let adminPubKey1 = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
13 | 13 | ||
14 | 14 | let adminPubKey2 = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
15 | 15 | ||
16 | 16 | let adminPubKey3 = base58'Kn7NpzaG12dLZgcHf2ipUftU6hbJygmrhFqQYE4B7ZK' | |
17 | 17 | ||
18 | 18 | let keyPrefixPoolName = "pool_" | |
19 | 19 | ||
20 | 20 | ||
21 | 21 | @Verifier(tx) | |
22 | 22 | func verify () = match tx { | |
23 | 23 | case invoke: InvokeScriptTransaction => | |
24 | 24 | let isExchangeCall = if (isDefined(getString(oracleAddress, (keyPrefixPoolName + toString(addressFromRecipient(invoke.dApp)))))) | |
25 | 25 | then (invoke.function == "exchange") | |
26 | 26 | else false | |
27 | 27 | let isAirdropCall = if ((invoke.dApp == governanceAddress)) | |
28 | 28 | then (invoke.function == "airDrop") | |
29 | 29 | else false | |
30 | 30 | let isUpdateWeightsCall = if ((invoke.dApp == governanceAddress)) | |
31 | 31 | then (invoke.function == "updateWeights") | |
32 | 32 | else false | |
33 | - | let isUpdatePoolInterest = if ((invoke.dApp == | |
33 | + | let isUpdatePoolInterest = if ((invoke.dApp == governanceAddress)) | |
34 | 34 | then (invoke.function == "updatePoolInterest") | |
35 | 35 | else false | |
36 | 36 | let signedByAdmin = sigVerify(tx.bodyBytes, tx.proofs[0], adminInvoke) | |
37 | 37 | if (if (if (isExchangeCall) | |
38 | 38 | then true | |
39 | 39 | else isAirdropCall) | |
40 | 40 | then (size(invoke.payments) == 1) | |
41 | 41 | else false) | |
42 | 42 | then true | |
43 | 43 | else if (if (isUpdateWeightsCall) | |
44 | 44 | then true | |
45 | 45 | else isUpdatePoolInterest) | |
46 | 46 | then (size(invoke.payments) == 0) | |
47 | 47 | else false | |
48 | 48 | case _ => | |
49 | 49 | sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
50 | 50 | } | |
51 | 51 |
github/deemru/w8io/026f985 53.58 ms ◑