tx · 8CpaQCAme6hnohpxa8WakW6bb8FtYJCx2GvJrBJ7AQpX 3N666c9jMPp2LgthP7QpdaHbfcyCXp6pfk2: -0.01400000 Waves 2020.07.15 09:20 [1088059] smart account 3N666c9jMPp2LgthP7QpdaHbfcyCXp6pfk2 > SELF 0.00000000 Waves
{ "type": 13, "id": "8CpaQCAme6hnohpxa8WakW6bb8FtYJCx2GvJrBJ7AQpX", "fee": 1400000, "feeAssetId": null, "timestamp": 1594794081050, "version": 1, "sender": "3N666c9jMPp2LgthP7QpdaHbfcyCXp6pfk2", "senderPublicKey": "2K3zsM6XaqxaedbuC6dRB8cVX8TcnGRAXSkRyUmXiSAj", "proofs": [ "yih1u3Znu8hp7wJ13b3vGR5GMvz4yYYSTESow4QVGvdJPTRxEacJPTN7cQqgSRiVk4i6VnK28vQT8D6QpWPTsMZ" ], "script": "base64:AAIDAAAAAAAAAA8IARIECgICCBIFCgMICAEAAAARAAAAAAVXQVZFUwIAAAAFV0FWRVMBAAAADmdldE51bWJlckJ5S2V5AAAAAQAAAANrZXkEAAAAByRtYXRjaDAJAAQaAAAAAgUAAAAEdGhpcwUAAAADa2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAANJbnQEAAAAAXYFAAAAByRtYXRjaDAFAAAAAXYAAAAAAAAAAAABAAAADWdldEJ5dGVzQnlLZXkAAAABAAAAA2tleQQAAAAHJG1hdGNoMAkABBwAAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAACkJ5dGVWZWN0b3IEAAAAAXYFAAAAByRtYXRjaDAFAAAAAXYBAAAAA9AAAAEAAAAOZ2V0U3RyaW5nQnlLZXkAAAABAAAAA2tleQQAAAAHJG1hdGNoMAkABB0AAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAABlN0cmluZwQAAAABdgUAAAAHJG1hdGNoMAUAAAABdgIAAAAAAQAAABhnZXRTdHJpbmdCeUFkZH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GkAAAAAQUAAAAHdkhlaWdodAIAAAAACQAAAgAAAAECAAAADmludmFsaWQgaGVpZ2h0AwkBAAAAAiE9AAAAAgkAAfUAAAABCQABmgAAAAEFAAAAAXYJAAJZAAAAAQkBAAAADmdldFN0cmluZ0J5S2V5AAAAAQkAAaQAAAABBQAAAAd2SGVpZ2h0CQAAAgAAAAEJAAEsAAAAAgIAAAAZaW52YWxpZCBrZWNjYWsyNTYodmFsdWUpIAkAAaQAAAABBQAAAAF2BgY1hhGn", "chainId": 84, "height": 1088059, "spentComplexity": 0 } View: original | compacted Prev: xFw7bKdZ1FREz1vDSaK9RqPBue9sf61ZphBRZEDsUsE Next: FCdpLwjPTJggzk2kV7cacvM5f3tfLBNewUD2gS8HvzGX Diff:
Old | New | Differences | |
---|---|---|---|
15 | 15 | ||
16 | 16 | ||
17 | 17 | func f (c) = { | |
18 | + | let d = getBinary(this, c) | |
19 | + | if ($isInstanceOf(d, "ByteVector")) | |
20 | + | then { | |
21 | + | let e = d | |
22 | + | e | |
23 | + | } | |
24 | + | else base58'2CsAf' | |
25 | + | } | |
26 | + | ||
27 | + | ||
28 | + | func g (c) = { | |
18 | 29 | let d = getString(this, c) | |
19 | 30 | if ($isInstanceOf(d, "String")) | |
20 | 31 | then { | |
25 | 36 | } | |
26 | 37 | ||
27 | 38 | ||
28 | - | func | |
29 | - | let d = getString( | |
39 | + | func h (i,c) = { | |
40 | + | let d = getString(i, c) | |
30 | 41 | if ($isInstanceOf(d, "String")) | |
31 | 42 | then { | |
32 | 43 | let e = d | |
36 | 47 | } | |
37 | 48 | ||
38 | 49 | ||
39 | - | let | |
50 | + | let j = "oracles" | |
40 | 51 | ||
41 | - | let | |
52 | + | let k = "consuls" | |
42 | 53 | ||
43 | - | let | |
54 | + | let l = "subscriber_address" | |
44 | 55 | ||
45 | - | let | |
56 | + | let m = "gravity_contract" | |
46 | 57 | ||
47 | - | let | |
58 | + | let n = "bft_coefficient" | |
48 | 59 | ||
49 | - | let | |
60 | + | let o = "last_round" | |
50 | 61 | ||
51 | - | let | |
62 | + | let p = split(g(j), ",") | |
52 | 63 | ||
53 | - | let | |
64 | + | let q = b(n) | |
54 | 65 | ||
55 | - | let | |
66 | + | let r = addressFromStringValue(g(m)) | |
56 | 67 | ||
57 | - | let | |
68 | + | let s = split(h(r, k), ",") | |
58 | 69 | ||
59 | - | let | |
70 | + | let t = g(l) | |
60 | 71 | ||
61 | - | func | |
62 | - | then if (sigVerify( | |
72 | + | func u (v,w,x) = if ((w != "nil")) | |
73 | + | then if (sigVerify(v, fromBase58String(w), fromBase58String(x))) | |
63 | 74 | then 1 | |
64 | 75 | else 0 | |
65 | 76 | else 0 | |
66 | 77 | ||
67 | 78 | ||
68 | - | @Callable( | |
69 | - | func confirmData ( | |
70 | - | let | |
71 | - | let | |
72 | - | if (( | |
79 | + | @Callable(y) | |
80 | + | func confirmData (v,z) = { | |
81 | + | let A = split(z, ",") | |
82 | + | let B = ((((u(v, A[0], p[0]) + u(v, A[1], p[1])) + u(v, A[2], p[2])) + u(v, A[3], p[3])) + u(v, A[4], p[4])) | |
83 | + | if ((B > q)) | |
73 | 84 | then throw("invalid bft count") | |
74 | - | else if ((f(toString(height)) != | |
85 | + | else if ((f(toString(height)) != base58'2CsAf')) | |
75 | 86 | then throw("data is exist") | |
76 | - | else WriteSet([DataEntry(toString(height), | |
87 | + | else WriteSet([DataEntry(toString(height), v)]) | |
77 | 88 | } | |
78 | 89 | ||
79 | 90 | ||
80 | 91 | ||
81 | - | @Callable( | |
82 | - | func setSortedOracles ( | |
83 | - | let | |
84 | - | let | |
85 | - | if (( | |
92 | + | @Callable(y) | |
93 | + | func setSortedOracles (C,D,E) = { | |
94 | + | let z = split(D, ",") | |
95 | + | let B = ((((u(toBytes(C), z[0], s[0]) + u(toBytes(C), z[1], s[1])) + u(toBytes(C), z[2], s[2])) + u(toBytes(C), z[3], s[3])) + u(toBytes(C), z[4], s[4])) | |
96 | + | if ((B > q)) | |
86 | 97 | then throw("invalid bft count") | |
87 | - | else WriteSet([DataEntry( | |
98 | + | else WriteSet([DataEntry(j, C), DataEntry(((o + "_") + toString(E)), E)]) | |
88 | 99 | } | |
89 | 100 | ||
90 | 101 | ||
91 | - | @Verifier( | |
92 | - | func | |
93 | - | let d = | |
102 | + | @Verifier(y) | |
103 | + | func F () = { | |
104 | + | let d = y | |
94 | 105 | if ($isInstanceOf(d, "InvokeScriptTransaction")) | |
95 | 106 | then { | |
96 | - | let | |
107 | + | let G = d | |
97 | 108 | let e = { | |
98 | - | let | |
99 | - | if ($isInstanceOf( | |
109 | + | let H = G.args[0] | |
110 | + | if ($isInstanceOf(H, "Int")) | |
100 | 111 | then { | |
101 | - | let e = | |
112 | + | let e = H | |
102 | 113 | e | |
103 | 114 | } | |
104 | 115 | else throw("invalid args[0] type") | |
105 | 116 | } | |
106 | - | let | |
107 | - | let | |
108 | - | if ($isInstanceOf( | |
117 | + | let I = { | |
118 | + | let H = G.args[1] | |
119 | + | if ($isInstanceOf(H, "Int")) | |
109 | 120 | then { | |
110 | - | let | |
111 | - | | |
121 | + | let I = H | |
122 | + | I | |
112 | 123 | } | |
113 | 124 | else throw("invalid args[1] type") | |
114 | 125 | } | |
115 | - | if (( | |
126 | + | if ((G.dApp != addressFromStringValue(t))) | |
116 | 127 | then throw("invalid dapp address") | |
117 | - | else if (( | |
128 | + | else if ((g(toString(I)) == "")) | |
118 | 129 | then throw("invalid height") | |
119 | - | else if ((keccak256(toBytes(e)) != fromBase58String( | |
130 | + | else if ((keccak256(toBytes(e)) != fromBase58String(g(toString(I))))) | |
120 | 131 | then throw(("invalid keccak256(value) " + toString(e))) | |
121 | 132 | else true | |
122 | 133 | } |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "WAVES" | |
5 | 5 | ||
6 | 6 | func b (c) = { | |
7 | 7 | let d = getInteger(this, c) | |
8 | 8 | if ($isInstanceOf(d, "Int")) | |
9 | 9 | then { | |
10 | 10 | let e = d | |
11 | 11 | e | |
12 | 12 | } | |
13 | 13 | else 0 | |
14 | 14 | } | |
15 | 15 | ||
16 | 16 | ||
17 | 17 | func f (c) = { | |
18 | + | let d = getBinary(this, c) | |
19 | + | if ($isInstanceOf(d, "ByteVector")) | |
20 | + | then { | |
21 | + | let e = d | |
22 | + | e | |
23 | + | } | |
24 | + | else base58'2CsAf' | |
25 | + | } | |
26 | + | ||
27 | + | ||
28 | + | func g (c) = { | |
18 | 29 | let d = getString(this, c) | |
19 | 30 | if ($isInstanceOf(d, "String")) | |
20 | 31 | then { | |
21 | 32 | let e = d | |
22 | 33 | e | |
23 | 34 | } | |
24 | 35 | else "" | |
25 | 36 | } | |
26 | 37 | ||
27 | 38 | ||
28 | - | func | |
29 | - | let d = getString( | |
39 | + | func h (i,c) = { | |
40 | + | let d = getString(i, c) | |
30 | 41 | if ($isInstanceOf(d, "String")) | |
31 | 42 | then { | |
32 | 43 | let e = d | |
33 | 44 | e | |
34 | 45 | } | |
35 | 46 | else "" | |
36 | 47 | } | |
37 | 48 | ||
38 | 49 | ||
39 | - | let | |
50 | + | let j = "oracles" | |
40 | 51 | ||
41 | - | let | |
52 | + | let k = "consuls" | |
42 | 53 | ||
43 | - | let | |
54 | + | let l = "subscriber_address" | |
44 | 55 | ||
45 | - | let | |
56 | + | let m = "gravity_contract" | |
46 | 57 | ||
47 | - | let | |
58 | + | let n = "bft_coefficient" | |
48 | 59 | ||
49 | - | let | |
60 | + | let o = "last_round" | |
50 | 61 | ||
51 | - | let | |
62 | + | let p = split(g(j), ",") | |
52 | 63 | ||
53 | - | let | |
64 | + | let q = b(n) | |
54 | 65 | ||
55 | - | let | |
66 | + | let r = addressFromStringValue(g(m)) | |
56 | 67 | ||
57 | - | let | |
68 | + | let s = split(h(r, k), ",") | |
58 | 69 | ||
59 | - | let | |
70 | + | let t = g(l) | |
60 | 71 | ||
61 | - | func | |
62 | - | then if (sigVerify( | |
72 | + | func u (v,w,x) = if ((w != "nil")) | |
73 | + | then if (sigVerify(v, fromBase58String(w), fromBase58String(x))) | |
63 | 74 | then 1 | |
64 | 75 | else 0 | |
65 | 76 | else 0 | |
66 | 77 | ||
67 | 78 | ||
68 | - | @Callable( | |
69 | - | func confirmData ( | |
70 | - | let | |
71 | - | let | |
72 | - | if (( | |
79 | + | @Callable(y) | |
80 | + | func confirmData (v,z) = { | |
81 | + | let A = split(z, ",") | |
82 | + | let B = ((((u(v, A[0], p[0]) + u(v, A[1], p[1])) + u(v, A[2], p[2])) + u(v, A[3], p[3])) + u(v, A[4], p[4])) | |
83 | + | if ((B > q)) | |
73 | 84 | then throw("invalid bft count") | |
74 | - | else if ((f(toString(height)) != | |
85 | + | else if ((f(toString(height)) != base58'2CsAf')) | |
75 | 86 | then throw("data is exist") | |
76 | - | else WriteSet([DataEntry(toString(height), | |
87 | + | else WriteSet([DataEntry(toString(height), v)]) | |
77 | 88 | } | |
78 | 89 | ||
79 | 90 | ||
80 | 91 | ||
81 | - | @Callable( | |
82 | - | func setSortedOracles ( | |
83 | - | let | |
84 | - | let | |
85 | - | if (( | |
92 | + | @Callable(y) | |
93 | + | func setSortedOracles (C,D,E) = { | |
94 | + | let z = split(D, ",") | |
95 | + | let B = ((((u(toBytes(C), z[0], s[0]) + u(toBytes(C), z[1], s[1])) + u(toBytes(C), z[2], s[2])) + u(toBytes(C), z[3], s[3])) + u(toBytes(C), z[4], s[4])) | |
96 | + | if ((B > q)) | |
86 | 97 | then throw("invalid bft count") | |
87 | - | else WriteSet([DataEntry( | |
98 | + | else WriteSet([DataEntry(j, C), DataEntry(((o + "_") + toString(E)), E)]) | |
88 | 99 | } | |
89 | 100 | ||
90 | 101 | ||
91 | - | @Verifier( | |
92 | - | func | |
93 | - | let d = | |
102 | + | @Verifier(y) | |
103 | + | func F () = { | |
104 | + | let d = y | |
94 | 105 | if ($isInstanceOf(d, "InvokeScriptTransaction")) | |
95 | 106 | then { | |
96 | - | let | |
107 | + | let G = d | |
97 | 108 | let e = { | |
98 | - | let | |
99 | - | if ($isInstanceOf( | |
109 | + | let H = G.args[0] | |
110 | + | if ($isInstanceOf(H, "Int")) | |
100 | 111 | then { | |
101 | - | let e = | |
112 | + | let e = H | |
102 | 113 | e | |
103 | 114 | } | |
104 | 115 | else throw("invalid args[0] type") | |
105 | 116 | } | |
106 | - | let | |
107 | - | let | |
108 | - | if ($isInstanceOf( | |
117 | + | let I = { | |
118 | + | let H = G.args[1] | |
119 | + | if ($isInstanceOf(H, "Int")) | |
109 | 120 | then { | |
110 | - | let | |
111 | - | | |
121 | + | let I = H | |
122 | + | I | |
112 | 123 | } | |
113 | 124 | else throw("invalid args[1] type") | |
114 | 125 | } | |
115 | - | if (( | |
126 | + | if ((G.dApp != addressFromStringValue(t))) | |
116 | 127 | then throw("invalid dapp address") | |
117 | - | else if (( | |
128 | + | else if ((g(toString(I)) == "")) | |
118 | 129 | then throw("invalid height") | |
119 | - | else if ((keccak256(toBytes(e)) != fromBase58String( | |
130 | + | else if ((keccak256(toBytes(e)) != fromBase58String(g(toString(I))))) | |
120 | 131 | then throw(("invalid keccak256(value) " + toString(e))) | |
121 | 132 | else true | |
122 | 133 | } | |
123 | 134 | else true | |
124 | 135 | } | |
125 | 136 |
github/deemru/w8io/169f3d6 75.08 ms ◑