tx · 7XLScQ29pXMkqHTw6ufUuSYViALYvGzS74qUESaqB5Lz 3N3BYKYYK6TKoHtPLZYU8JRn8PcHTnauS9z: -0.02000000 Waves 2021.12.15 15:47 [1835393] smart account 3N3BYKYYK6TKoHtPLZYU8JRn8PcHTnauS9z > SELF 0.00000000 Waves
{ "type": 13, "id": "7XLScQ29pXMkqHTw6ufUuSYViALYvGzS74qUESaqB5Lz", "fee": 2000000, "feeAssetId": null, "timestamp": 1639572428670, "version": 2, "chainId": 84, "sender": "3N3BYKYYK6TKoHtPLZYU8JRn8PcHTnauS9z", "senderPublicKey": "FsjTCE3KV2vD2r7Du9D3J6Ea2T643E6zxzn6y24outXr", "proofs": [ "4Yn5EXq3M3qizqKBxmGQb9vY7KHgCykjfRzy4kPPtcjcZnog1S4DfEPDAyn65pFMc3sziY2i5io8dVekiPWgU7Du" ], "script": "base64:AAIDAAAAAAAABwoIARIFCgMBAQESBAoCCAIaDwoBQRIKcmFuZHNDb3VudBoTCgFCEg5yZW1haW5pbmdSYW5kcxoSCgFDEg1kYXRhS2V5c0NvdW50GhEKAUQSDGRhdGFEb25lVHhJZBoPCgFFEgpsYXN0T2Zmc2V0Gg0KAUYSCHNsb3dJZHgxGg0KAUcSCHNsb3dJZHgyGg0KAUgSCGZhc3RJZHgxGg0KAUkSCGZhc3RJZHgyGhAKAUoSC3JhbmRPckVtcHR5GhEKAUsSDGZ1bGxTdGF0ZVN0choYCgFMEhNleHRyYWN0R2FtZURhdGFMaXN0Gg4KAU0SCXNlc3Npb25JZBoPCgFOEgpyYXdEYXRhU3RyGg0KAU8SCG5leHRSYW5kGggKAVASA2RpdhoICgFREgNtaW4aEQoBUhIMY3VyclJhbmRzU3RyGhIKAVMSDXJlbWFpbmluZ0hhc2gaEAoBVBILbmV4dFJhbmRJbnQaEAoBVRILbmV4dFJhbmRTdHIaDgoBVhIJZHVwbGljYXRlGhEKAVcSDGdlbmVyYXRlUmFuZBoJCgFYEgRmcm9tGgcKAVkSAnRvGgw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ECQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIFAAAAAU0CAAAABnRlc3QtMgIAAAACZHMFAAAAA25pbAAAAABBbsP2", "height": 1835393, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 44mqXyrhGCGN16GAczGDEKpFaKUPhnwNhKTtVi4YVKF1 Next: 3XK6M7LVrqCt8ibtUXQt8Eix4muLWgwnXrtWbhE48PFS Diff:
Old | New | Differences | |
---|---|---|---|
76 | 76 | then [0, (currSlowIdx1 + 1), (currSlowIdx2 + 1), 0, 1] | |
77 | 77 | else [0, currSlowIdx1, currSlowIdx2, (currFastIdx1 + 1), (currFastIdx2 + 1)] | |
78 | 78 | else [(lastOffsetBytes + 1), currSlowIdx1, currSlowIdx2, currFastIdx1, currFastIdx2] | |
79 | - | let newOffsetBytes = 3 | |
80 | - | let newSlowIdx1 = 4 | |
81 | - | let newSlowIdx2 = 5 | |
82 | - | let newFastIdx1 = 6 | |
83 | - | let newFastIdx2 = 7 | |
84 | - | let byteVect = (((((((take(drop(rsaSign, newSlowIdx1), 1) + take(drop(rsaSign, 1), 1)) + take(drop(rsaSign, newFastIdx1), 1)) + take(drop(rsaSign, 3), 1)) + take(drop(rsaSign, newSlowIdx2), 1)) + take(drop(rsaSign, 5), 1)) + take(drop(rsaSign, 6), 1)) + take(drop(rsaSign, newFastIdx2), 1)) | |
85 | - | byteVect | |
79 | + | ((((newIncList[0] + newIncList[1]) + newIncList[2]) + newIncList[3]) + newIncList[4]) | |
86 | 80 | } | |
87 | 81 | ||
88 | 82 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let RSAPUBLIC = fromBase64String("base64:LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlHZk1BMEdDU3FHU0liM0RRRUJBUVVBQTRHTkFEQ0JpUUtCZ1FDR25Hd3ZVbG1mTG5ZTkdyRSszczR2QTZRZAowa29PNzdZUjJDdTZpOWQvalE2OVJkU0hHRFlwb3hKM1gvSS84MmtpS1JRcHlwcWJjUS9UY3IxV1VRM1RDQmk1CnFmYyt4ZWVyOS9ncnhUOExJazEvVFhXVEZBQzA2M3R3V1dPbVpXcGNPN3kyZlRuUklkSFRlaUs0T1pzSyt1Z2UKOTdGS3BTbWoxcmpFVDFmM0F3SURBUUFCCi0tLS0tRU5EIFBVQkxJQyBLRVktLS0tLQ==") | |
5 | 5 | ||
6 | 6 | let SERVER = addressFromStringValue("3N4vdqMsEsAZSJWfwYJcaCgUzASJTC2BWsP") | |
7 | 7 | ||
8 | 8 | let WAVELET = ((100 * 1000) * 1000) | |
9 | 9 | ||
10 | 10 | let SESSIONIDFIXSIZE = 44 | |
11 | 11 | ||
12 | 12 | let RANDCYCLEPRICE = ((5 * WAVELET) / 1000) | |
13 | 13 | ||
14 | 14 | let MAXRANDSPERCYCLE = 14 | |
15 | 15 | ||
16 | 16 | let STATEINIT = "INIT" | |
17 | 17 | ||
18 | 18 | let DATADONE = "READY" | |
19 | 19 | ||
20 | 20 | let STATEFINISHED = "FINISHED" | |
21 | 21 | ||
22 | 22 | let IdxState = 0 | |
23 | 23 | ||
24 | 24 | let IdxOrganizerPub = 1 | |
25 | 25 | ||
26 | 26 | let IdxRandFrom = 2 | |
27 | 27 | ||
28 | 28 | let IdxRandTo = 3 | |
29 | 29 | ||
30 | 30 | let IdxRandsCount = 4 | |
31 | 31 | ||
32 | 32 | let IdxRemainRandsCount = 5 | |
33 | 33 | ||
34 | 34 | let IdxDataKeysCount = 6 | |
35 | 35 | ||
36 | 36 | let IdxDataDoneTxId = 7 | |
37 | 37 | ||
38 | 38 | let IdxLastOffset = 8 | |
39 | 39 | ||
40 | 40 | let IdxCurrRands = 13 | |
41 | 41 | ||
42 | 42 | func abs (val) = if ((0 > val)) | |
43 | 43 | then -(val) | |
44 | 44 | else val | |
45 | 45 | ||
46 | 46 | ||
47 | 47 | func formatStateDataStr (drawState,organizerPubKey58,randFrom,randTo,randsCount,remainingRands,dataKeysCount,dataDoneTxId,lastOffset,slowIdx1,slowIdx2,fastIdx1,fastIdx2,randOrEmpty) = { | |
48 | 48 | let fullStateStr = ((((((((((((((((((((((((drawState + "_") + organizerPubKey58) + "_") + randFrom) + "_") + randTo) + "_") + randsCount) + "_") + remainingRands) + "_") + dataKeysCount) + "_") + dataDoneTxId) + "_") + lastOffset) + "_") + slowIdx1) + "_") + slowIdx2) + "_") + fastIdx1) + "_") + fastIdx2) | |
49 | 49 | if ((randOrEmpty == "")) | |
50 | 50 | then ((fullStateStr + "_") + "-") | |
51 | 51 | else ((fullStateStr + "_") + randOrEmpty) | |
52 | 52 | } | |
53 | 53 | ||
54 | 54 | ||
55 | 55 | func extractGameDataList (sessionId) = { | |
56 | 56 | let rawDataStr = getStringValue(this, sessionId) | |
57 | 57 | split(rawDataStr, "_") | |
58 | 58 | } | |
59 | 59 | ||
60 | 60 | ||
61 | 61 | func nextRand (div,min,currRandsStr,remainingRands,remainingHash) = { | |
62 | 62 | let nextRandInt = ((abs(toInt(remainingHash)) % div) + min) | |
63 | 63 | let nextRandStr = toString(nextRandInt) | |
64 | 64 | let duplicate = isDefined(indexOf(currRandsStr, nextRandStr)) | |
65 | 65 | if (if (!(duplicate)) | |
66 | 66 | then (remainingRands > 0) | |
67 | 67 | else false) | |
68 | 68 | then [((currRandsStr + "-") + nextRandStr), "yes"] | |
69 | 69 | else [currRandsStr, ""] | |
70 | 70 | } | |
71 | 71 | ||
72 | 72 | ||
73 | 73 | func generateRand (sessionId,from,to,rsaSign,currRandsStr,remainingRands,lastOffsetBytes,currSlowIdx1,currSlowIdx2,currFastIdx1,currFastIdx2) = { | |
74 | 74 | let newIncList = if (((lastOffsetBytes + 1) > 87)) | |
75 | 75 | then if ((currFastIdx2 > 241)) | |
76 | 76 | then [0, (currSlowIdx1 + 1), (currSlowIdx2 + 1), 0, 1] | |
77 | 77 | else [0, currSlowIdx1, currSlowIdx2, (currFastIdx1 + 1), (currFastIdx2 + 1)] | |
78 | 78 | else [(lastOffsetBytes + 1), currSlowIdx1, currSlowIdx2, currFastIdx1, currFastIdx2] | |
79 | - | let newOffsetBytes = 3 | |
80 | - | let newSlowIdx1 = 4 | |
81 | - | let newSlowIdx2 = 5 | |
82 | - | let newFastIdx1 = 6 | |
83 | - | let newFastIdx2 = 7 | |
84 | - | let byteVect = (((((((take(drop(rsaSign, newSlowIdx1), 1) + take(drop(rsaSign, 1), 1)) + take(drop(rsaSign, newFastIdx1), 1)) + take(drop(rsaSign, 3), 1)) + take(drop(rsaSign, newSlowIdx2), 1)) + take(drop(rsaSign, 5), 1)) + take(drop(rsaSign, 6), 1)) + take(drop(rsaSign, newFastIdx2), 1)) | |
85 | - | byteVect | |
79 | + | ((((newIncList[0] + newIncList[1]) + newIncList[2]) + newIncList[3]) + newIncList[4]) | |
86 | 80 | } | |
87 | 81 | ||
88 | 82 | ||
89 | 83 | func validateDtxKey (sessionId,dataKeysCount,data) = { | |
90 | 84 | let dataKeyInfo = split(data.key, "_") | |
91 | 85 | if ((size(dataKeyInfo) != 2)) | |
92 | 86 | then throw("Invalid data key format. It must follow to ${sessionId}_${num}") | |
93 | 87 | else { | |
94 | 88 | let keySessionId = dataKeyInfo[0] | |
95 | 89 | let keyPostfix = dataKeyInfo[1] | |
96 | 90 | if ((sessionId != keySessionId)) | |
97 | 91 | then throw(((("Several data keys have different sessionId: " + sessionId) + " and ") + keySessionId)) | |
98 | 92 | else if (isDefined(getString(this, data.key))) | |
99 | 93 | then throw(("One of the data keys has already presented in account state: key=" + data.key)) | |
100 | 94 | else if ((size(keyPostfix) > 4)) | |
101 | 95 | then throw("Invalid data key format. It must follow to ${sessionId}_${num} where ${num} length couldn't be greater than 4") | |
102 | 96 | else if ((take(keyPostfix, 1) == "0")) | |
103 | 97 | then throw("Invalid data key format. It must follow to ${sessionId}_${num} where ${num} couldn't start from 0") | |
104 | 98 | else { | |
105 | 99 | let keyPostfixIntOpt = parseInt(keyPostfix) | |
106 | 100 | if (isDefined(keyPostfixIntOpt)) | |
107 | 101 | then { | |
108 | 102 | let keyPostfixInt = extract(keyPostfixIntOpt) | |
109 | 103 | if (if ((1 > keyPostfixInt)) | |
110 | 104 | then true | |
111 | 105 | else (keyPostfixInt > dataKeysCount)) | |
112 | 106 | then throw((((("Invalid data key format. It must follow to ${sessionId}_${num}" + " where ${num} must be a valid int value from 1 to ") + toString(dataKeysCount)) + " but actualNum=") + toString(keyPostfixInt))) | |
113 | 107 | else match data.value { | |
114 | 108 | case str: String => | |
115 | 109 | true | |
116 | 110 | case _ => | |
117 | 111 | throw((sessionId + " draw: only String type is accepted for data transactions")) | |
118 | 112 | } | |
119 | 113 | } | |
120 | 114 | else throw((("Invalid data key format. It must follow to ${sessionId}_${num}" + " where ${num} must be a valid int value from 1 to 31250 but actualNum=") + keyPostfix)) | |
121 | 115 | } | |
122 | 116 | } | |
123 | 117 | } | |
124 | 118 | ||
125 | 119 | ||
126 | 120 | func validateAndGetRandsPmt (randsCount,pmt,minDataPmt) = { | |
127 | 121 | let bound1 = 1000 | |
128 | 122 | let basePrice1 = ((13 * WAVELET) / 100) | |
129 | 123 | let div1 = 50 | |
130 | 124 | let diff1 = ((8 * WAVELET) / 100) | |
131 | 125 | let bound2 = 5000 | |
132 | 126 | let basePrice2 = ((297 * WAVELET) / 100) | |
133 | 127 | let div2 = 1000 | |
134 | 128 | let diff2 = ((143 * WAVELET) / 100) | |
135 | 129 | let bound3 = 50000 | |
136 | 130 | let basePrice3 = ((1427 * WAVELET) / 100) | |
137 | 131 | let div3 = 5000 | |
138 | 132 | let diff3 = ((705 * WAVELET) / 100) | |
139 | 133 | let minRandsPmt = if ((bound1 > randsCount)) | |
140 | 134 | then (basePrice1 + ((randsCount / div1) * diff1)) | |
141 | 135 | else if ((bound2 > randsCount)) | |
142 | 136 | then (basePrice2 + (((randsCount / div2) - 1) * diff2)) | |
143 | 137 | else if ((bound3 > randsCount)) | |
144 | 138 | then (basePrice3 + (((randsCount / div3) - 1) * diff3)) | |
145 | 139 | else throw("Please contact our sales team to generate more than 50k rands") | |
146 | 140 | let minPmt = (minRandsPmt + minDataPmt) | |
147 | 141 | if (isDefined(pmt.assetId)) | |
148 | 142 | then throw("Only WAVES can be used as a payment for rands generation") | |
149 | 143 | else if ((minPmt > pmt.amount)) | |
150 | 144 | then throw(((((("Attached payment is to small to generate " + toString(randsCount)) + " unique randoms numbers and upload at least 1 data tx: actualPmt=") + toString(pmt.amount)) + " but minPmt is ") + toString(minPmt))) | |
151 | 145 | else minRandsPmt | |
152 | 146 | } | |
153 | 147 | ||
154 | 148 | ||
155 | 149 | @Callable(i) | |
156 | 150 | func initDraw (randFrom,randTo,randsCount) = { | |
157 | 151 | let sessionId = toBase58String(i.transactionId) | |
158 | 152 | let rangeLength = ((randTo - randFrom) + 1) | |
159 | 153 | let maxRangeLength = (rangeLength / 2) | |
160 | 154 | let randToLen = size(toString((randTo - 1))) | |
161 | 155 | let randsCountLen = size(toString(randsCount)) | |
162 | 156 | let dynamicStatusLen = (((2 * randToLen) + (2 * randsCountLen)) + 4) | |
163 | 157 | let maxRandsCount = (((5120 - 175) - dynamicStatusLen) / (randToLen + 1)) | |
164 | 158 | if (if ((0 >= randFrom)) | |
165 | 159 | then true | |
166 | 160 | else (0 >= randTo)) | |
167 | 161 | then throw("randFrom and randTo must be greater than 0") | |
168 | 162 | else if ((randFrom >= randTo)) | |
169 | 163 | then throw("randFrom must be strict less then randTo") | |
170 | 164 | else if ((randsCount > rangeLength)) | |
171 | 165 | then throw(((((((("Impossible to generate " + toString(randsCount)) + " unique numbers for provided random range [") + toString(randFrom)) + ", ") + toString(randTo)) + "] with actual size ") + toString(rangeLength))) | |
172 | 166 | else if ((randsCount > maxRangeLength)) | |
173 | 167 | then throw(((((((((("randsCount must be less then 50% of passed range length: range=[" + toString(randFrom)) + ", ") + toString(randTo)) + "], rangeLength=") + toString(rangeLength)) + " randsCount=") + toString(randsCount)) + " allowedRandsCount=") + toString(maxRangeLength))) | |
174 | 168 | else if ((randsCount > maxRandsCount)) | |
175 | 169 | then throw(((((("randsCount couldn't be kept in 1 data entry: 1_randNumSpace=" + toString((randToLen + 1))) + " maxAllowedRandsCount=") + toString(maxRandsCount)) + " actualRandsCount=") + toString(randsCount))) | |
176 | 170 | else if (!(isDefined(i.payment))) | |
177 | 171 | then throw("Please provide payment to generate unique random numbers") | |
178 | 172 | else { | |
179 | 173 | let pmt = extract(i.payment) | |
180 | 174 | let minDataPmt = ((((WAVELET * 1) / 1000) * 33) + ((WAVELET * 4) / 1000)) | |
181 | 175 | let randsPmt = validateAndGetRandsPmt(randsCount, pmt, minDataPmt) | |
182 | 176 | let dataPmt = (pmt.amount - randsPmt) | |
183 | 177 | let dataTxCount = (dataPmt / minDataPmt) | |
184 | 178 | let dataKeysCount = if ((31250 >= (dataTxCount * 5))) | |
185 | 179 | then (dataTxCount * 5) | |
186 | 180 | else 31250 | |
187 | 181 | let organizerPubKey58 = toBase58String(i.callerPublicKey) | |
188 | 182 | let randsCountStr = toString(randsCount) | |
189 | 183 | let initState = formatStateDataStr(DATADONE, organizerPubKey58, toString(randFrom), toString(randTo), randsCountStr, randsCountStr, toString(dataKeysCount), toBase58String(i.transactionId), "0", "0", "1", "0", "1", "") | |
190 | 184 | ScriptResult(WriteSet([DataEntry(sessionId, initState)]), TransferSet([ScriptTransfer(SERVER, randsPmt, unit)])) | |
191 | 185 | } | |
192 | 186 | } | |
193 | 187 | ||
194 | 188 | ||
195 | 189 | ||
196 | 190 | @Callable(i) | |
197 | 191 | func random (sessionId,rsaSign) = { | |
198 | 192 | let drawParamsList = extractGameDataList(sessionId) | |
199 | 193 | let drawState = drawParamsList[IdxState] | |
200 | 194 | let organizerPubKey58 = drawParamsList[IdxOrganizerPub] | |
201 | 195 | let randsCountStr = drawParamsList[IdxRandsCount] | |
202 | 196 | let remainRandsCount = parseIntValue(drawParamsList[IdxRemainRandsCount]) | |
203 | 197 | let lastOffsetBytes = parseIntValue(drawParamsList[IdxLastOffset]) | |
204 | 198 | let currRandsStr = drawParamsList[IdxCurrRands] | |
205 | 199 | let fromStr = drawParamsList[IdxRandFrom] | |
206 | 200 | let toStr = drawParamsList[IdxRandTo] | |
207 | 201 | let dataDoneTxId = drawParamsList[IdxDataDoneTxId] | |
208 | 202 | let slowIdx1 = parseIntValue(drawParamsList[9]) | |
209 | 203 | let slowIdx2 = parseIntValue(drawParamsList[10]) | |
210 | 204 | let fastIdx1 = parseIntValue(drawParamsList[11]) | |
211 | 205 | let fastIdx2 = parseIntValue(drawParamsList[12]) | |
212 | 206 | let from = parseIntValue(fromStr) | |
213 | 207 | let to = parseIntValue(toStr) | |
214 | 208 | let organizerPubKey = fromBase58String(organizerPubKey58) | |
215 | 209 | if ((drawState != DATADONE)) | |
216 | 210 | then throw((sessionId + " draw: it must be in READY state to generate random numbers")) | |
217 | 211 | else if (false) | |
218 | 212 | then throw("Invalid RSA signature") | |
219 | 213 | else { | |
220 | 214 | let randGenInfo = generateRand(sessionId, from, to, rsaSign, currRandsStr, remainRandsCount, lastOffsetBytes, slowIdx1, slowIdx2, fastIdx1, fastIdx2) | |
221 | 215 | WriteSet([DataEntry("byteVect", randGenInfo), DataEntry((sessionId + "test"), (toBytes(sessionId) + toBytes(dataDoneTxId))), DataEntry((sessionId + "test-2"), "ds")]) | |
222 | 216 | } | |
223 | 217 | } | |
224 | 218 | ||
225 | 219 |
github/deemru/w8io/169f3d6 51.49 ms ◑