tx · 9C4gGthmGKvhoxvs8yyUPaz3HeKn3i8JVJugy81xNkwz

3NC28hSivrmsTUXaYD1x6L362J4ZpUnoTdB:  -0.01000000 Waves

2023.01.21 12:47 [2414577] smart account 3NC28hSivrmsTUXaYD1x6L362J4ZpUnoTdB > SELF 0.00000000 Waves

{ "type": 13, "id": "9C4gGthmGKvhoxvs8yyUPaz3HeKn3i8JVJugy81xNkwz", "fee": 1000000, "feeAssetId": null, "timestamp": 1674294517344, "version": 2, "chainId": 84, "sender": "3NC28hSivrmsTUXaYD1x6L362J4ZpUnoTdB", "senderPublicKey": "Gd5NihbWQoWuTnSvq25TuV2BYZG4U1e9KDqZn9zBPix7", "proofs": [ "4WMeciEHA9NQ7uQwKkes1HUNFpEoNyYqJdezgQiwe22fmxKxzyomscFnzPUeJvN8WTQDy6ZwmjThmzofgzvKzmc3" ], "script": "base64:BgIgCAISBAoCCAgSBwoFCAgICAgSBAoCCAgSABIFCgMIAQQUAQ5nZXRTdHJpbmdCeUtleQEDa2V5CQELdmFsdWVPckVsc2UCCQCdCAIFBHRoaXMFA2tleQIAAA9zdG9yYWdlVmVyaWZpZXIJAQV2YWx1ZQEJAKYIAQkBDmdldFN0cmluZ0J5S2V5AQITY29uZl9vcmFjbGVfYWRkcmVzcwAEYmFuawkBDmdldFN0cmluZ0J5S2V5AQIZY29uZl9mZWVfcmVjZWl2ZXJfYWRkcmVzcwANYWNjZXB0ZWRUb2tlbgkBDmdldFN0cmluZ0J5S2V5AQIWY29uZl9hY2NlcHRlZF90b2tlbl9pZAAGdXNkbklECQEOZ2V0U3RyaW5nQnlLZXkBAgxjb25mX3VzZG5faWQABWNocmlzCQEOZ2V0U3RyaW5nQnlLZXkBAhJjb25mX2FkbWluX2FkZHJlc3MAB1ZFUlNJT04CBTEuMS45ABRzdG9yYWdlRmVlTXVsdGlwbGllcgABAQpjaGVja0VudHJ5AgZwcmVmaXgEdXVpZAQHJG1hdGNoMAkAnQgCBQR0aGlzCQCsAgIFBnByZWZ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pb24JAAACCAUDaW52BGRBcHAFBHRoaXMHCQAAAggFA2ludgNmZWUAoMIeBwkAAAIIBQNpbnYKZmVlQXNzZXRJZAUEdW5pdAcJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAJANkEAQkBCGFzU3RyaW5nAQkAkQMCCAUDaW52BGFyZ3MAAQkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAgFAnR4D3NlbmRlclB1YmxpY0tleQkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAgFAnR4D3NlbmRlclB1YmxpY0tlee3X8to=", "height": 2414577, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 9icxqVkCNgA1qSm1mVQWWNScR6BHH27W9CnBgF9XbDXY Next: BL7MExiVzrNT1qQJr7noKatPqpJjgeC4nKpyK5DPh7Mr Diff:
OldNewDifferences
154154 else 1
155155 if ((0 > (callerIsWhiteListedNum - creditCost)))
156156 then throw("Not enough credit")
157- else [StringEntry(uuid, toBase58String(id)), StringEntry((hash + uuid), toBase58String(id)), StringEntry((title + uuid), toBase58String(id)), IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum - creditCost)), StringEntry(((("data_fc_" + toBase58String(id)) + "_") + callerAddress), data), ScriptTransfer(addressFromStringValue(callerAddress), 0, value(toBytes(acceptedToken)))]
157+ else [StringEntry(uuid, toBase58String(id)), StringEntry((hash + uuid), toBase58String(id)), StringEntry((title + uuid), toBase58String(id)), IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum - creditCost)), StringEntry(((("data_fc_" + toBase58String(id)) + "_") + callerAddress), data), ScriptTransfer(addressFromStringValue(callerAddress), 0, fromBase58String(acceptedToken))]
158158 }
159159 else if (!(callerIsDapp))
160160 then {
167167 let feeCost = if ((size(ipfs) != 0))
168168 then (currentPrice + (storageFeeMultiplier * currentPrice))
169169 else currentPrice
170- if ((value(toBytes(acceptedToken)) != paymentAssetId))
170+ if ((fromBase58String(acceptedToken) != paymentAssetId))
171171 then throw("This token is not accepted at the moment")
172172 else if (if ((amount != feeCost))
173173 then (0 >= callerIsWhiteListedNum)
207207 else if ((entryExist == "NONE"))
208208 then throw("You cannot change the status of this certification.")
209209 else if ((callerIsWhiteListedNum > 0))
210- then [IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum - 1)), StringEntry(("STATUS_FC_" + certificationId), ("REVOKED_" + toBase58String(id))), StringEntry(((("data_fc_" + certificationId) + "_") + callerAddress), newJson), ScriptTransfer(addressFromStringValue(callerAddress), 0, value(toBytes(acceptedToken)))]
210+ then [IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum - 1)), StringEntry(("STATUS_FC_" + certificationId), ("REVOKED_" + toBase58String(id))), StringEntry(((("data_fc_" + certificationId) + "_") + callerAddress), newJson), ScriptTransfer(addressFromStringValue(callerAddress), 0, fromBase58String(acceptedToken))]
211211 else if (!(callerIsDapp))
212212 then {
213213 let payment = value(invoke.payments[0])
216216 then value(payment.assetId)
217217 else throw("Waves is not accepted as payment")
218218 let currentPrice = getIntegerValue(storageVerifier, ("certification_fee_" + toBase58String(value(paymentAssetId))))
219- if ((value(toBytes(acceptedToken)) != paymentAssetId))
219+ if ((fromBase58String(acceptedToken) != paymentAssetId))
220220 then throw("This token is not accepted at the moment")
221221 else if (if ((amount != currentPrice))
222222 then (0 >= callerIsWhiteListedNum)
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 func getStringByKey (key) = valueOrElse(getString(this, key), "")
55
66
77 let storageVerifier = value(addressFromString(getStringByKey("conf_oracle_address")))
88
99 let bank = getStringByKey("conf_fee_receiver_address")
1010
1111 let acceptedToken = getStringByKey("conf_accepted_token_id")
1212
1313 let usdnID = getStringByKey("conf_usdn_id")
1414
1515 let chris = getStringByKey("conf_admin_address")
1616
1717 let VERSION = "1.1.9"
1818
1919 let storageFeeMultiplier = 1
2020
2121 func checkEntry (prefix,uuid) = match getString(this, (prefix + uuid)) {
2222 case a: String =>
2323 a
2424 case _ =>
2525 "NONE"
2626 }
2727
2828
2929 func checkEntryEmail (uuid,domain) = match getString(this, ((uuid + "@") + domain)) {
3030 case a: String =>
3131 a
3232 case _ =>
3333 "NONE"
3434 }
3535
3636
3737 func checkUUID (uuid) = match getString(this, uuid) {
3838 case a: String =>
3939 a
4040 case _ =>
4141 "NONE"
4242 }
4343
4444
4545 func checkIfWhiteListed (callerAddress) = match getInteger(this, ("addr_WHITELISTED_" + callerAddress)) {
4646 case a: Int =>
4747 a
4848 case _ =>
4949 0
5050 }
5151
5252
5353 func isAdress (addr) = if (if (if ((size(addr) == 35))
5454 then (take(addr, 2) == "3P")
5555 else false)
5656 then true
5757 else (take(addr, 2) == "3N"))
5858 then true
5959 else (take(addr, 2) == "3M")
6060
6161
6262 func countParties (accumulator,addr) = if ((size(addr) > 0))
6363 then (accumulator + 1)
6464 else (accumulator + 0)
6565
6666
6767 func checkIfPendingToSign (key) = match getString(this, key) {
6868 case a: String =>
6969 if ((a == "PENDING"))
7070 then true
7171 else false
7272 case _ =>
7373 false
7474 }
7575
7676
7777 func getValueString (json) = take(drop(json, 1), value(indexOf(drop(json, 1), "\"")))
7878
7979
8080 func getValue (json,key) = {
8181 let keyIndex = value(indexOf(json, (("\"" + key) + "\":")))
8282 let data = drop(json, ((keyIndex + size(key)) + 3))
8383 let jsonValue = getValueString(data)
8484 jsonValue
8585 }
8686
8787
8888 func getJsonBeforeValue (json,key) = {
8989 let keyIndex = value(indexOf(json, (("\"" + key) + "\":")))
9090 let data = take(json, ((keyIndex + size(key)) + 3))
9191 data
9292 }
9393
9494
9595 func getJsonAfterValue (json,key) = {
9696 let keyIndex = value(indexOf(json, (("\"" + key) + "\":")))
9797 let data = takeRight(json, (size(json) - ((((keyIndex + size(key)) + 3) + 0) + 2)))
9898 data
9999 }
100100
101101
102102 func asString (bv) = match bv {
103103 case bv0: String =>
104104 bv0
105105 case _ =>
106106 throw("Sponsored Public Key String expected")
107107 }
108108
109109
110110 @Callable(invoke)
111111 func setConf (key,val) = {
112112 let caller = toString(invoke.caller)
113113 if (containsElement([chris, toString(this)], caller))
114114 then if (contains(key, "conf_"))
115115 then [StringEntry(key, val)]
116116 else throw("Entries starting with conf_ only")
117117 else throw("You are not allowed to change this")
118118 }
119119
120120
121121
122122 @Callable(invoke)
123123 func fileCertification (hash,title,uuid,ipfs,signerPubKey) = {
124124 let id = value(invoke.transactionId)
125125 let entryExist = checkEntry(hash, uuid)
126126 let uuidExist = checkUUID(uuid)
127127 let callerIsDapp = (this == invoke.caller)
128128 let callerAddress = if (callerIsDapp)
129129 then toString(addressFromPublicKey(fromBase58String(signerPubKey)))
130130 else toBase58String(invoke.caller.bytes)
131131 let callerIsWhiteListedNum = checkIfWhiteListed(callerAddress)
132132 if ((entryExist != "NONE"))
133133 then throw("This entry already exist")
134134 else if ((uuidExist != "NONE"))
135135 then throw("This uuid already exist")
136136 else if ((size(uuid) != 36))
137137 then throw("Uuid should be 36 characters.")
138138 else if ((size(hash) != 64))
139139 then throw("Hash should be 64 characters.")
140140 else if ((size(title) > 100))
141141 then throw("Title is too long, 100 characters max.")
142142 else if (if (if (contains(hash, "\""))
143143 then true
144144 else contains(title, "\""))
145145 then true
146146 else contains(ipfs, "\""))
147147 then throw("No \" allowed")
148148 else {
149149 let data = (((((((("{\"hash\":\"" + hash) + "\",\"timestamp\":") + toString(lastBlock.timestamp)) + ",\"title\":\"") + title) + "\",\"ipfs\":\"") + ipfs) + "\"}")
150150 if ((callerIsWhiteListedNum > 0))
151151 then {
152152 let creditCost = if ((size(ipfs) != 0))
153153 then (1 + storageFeeMultiplier)
154154 else 1
155155 if ((0 > (callerIsWhiteListedNum - creditCost)))
156156 then throw("Not enough credit")
157- else [StringEntry(uuid, toBase58String(id)), StringEntry((hash + uuid), toBase58String(id)), StringEntry((title + uuid), toBase58String(id)), IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum - creditCost)), StringEntry(((("data_fc_" + toBase58String(id)) + "_") + callerAddress), data), ScriptTransfer(addressFromStringValue(callerAddress), 0, value(toBytes(acceptedToken)))]
157+ else [StringEntry(uuid, toBase58String(id)), StringEntry((hash + uuid), toBase58String(id)), StringEntry((title + uuid), toBase58String(id)), IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum - creditCost)), StringEntry(((("data_fc_" + toBase58String(id)) + "_") + callerAddress), data), ScriptTransfer(addressFromStringValue(callerAddress), 0, fromBase58String(acceptedToken))]
158158 }
159159 else if (!(callerIsDapp))
160160 then {
161161 let payment = value(invoke.payments[0])
162162 let amount = value(payment.amount)
163163 let paymentAssetId = if (isDefined(payment.assetId))
164164 then value(payment.assetId)
165165 else throw("Waves is not accepted as payment")
166166 let currentPrice = getIntegerValue(storageVerifier, ("certification_fee_" + toBase58String(value(paymentAssetId))))
167167 let feeCost = if ((size(ipfs) != 0))
168168 then (currentPrice + (storageFeeMultiplier * currentPrice))
169169 else currentPrice
170- if ((value(toBytes(acceptedToken)) != paymentAssetId))
170+ if ((fromBase58String(acceptedToken) != paymentAssetId))
171171 then throw("This token is not accepted at the moment")
172172 else if (if ((amount != feeCost))
173173 then (0 >= callerIsWhiteListedNum)
174174 else false)
175175 then throw("The price is wrong")
176176 else [StringEntry(uuid, toBase58String(id)), StringEntry((hash + uuid), toBase58String(id)), StringEntry((title + uuid), toBase58String(id)), StringEntry(((("data_fc_" + toBase58String(id)) + "_") + callerAddress), data), ScriptTransfer(addressFromStringValue(bank), feeCost, payment.assetId)]
177177 }
178178 else throw("You are not allowed to do that")
179179 }
180180 }
181181
182182
183183
184184 @Callable(invoke)
185185 func revokeCertification (certificationId,signerPubKey) = {
186186 let id = value(invoke.transactionId)
187187 let callerIsDapp = (this == invoke.caller)
188188 let callerAddress = if (callerIsDapp)
189189 then toString(addressFromPublicKey(fromBase58String(signerPubKey)))
190190 else toBase58String(invoke.caller.bytes)
191191 let entryExist = match getString(this, ((("data_fc_" + certificationId) + "_") + callerAddress)) {
192192 case a: String =>
193193 a
194194 case _ =>
195195 "NONE"
196196 }
197197 let isRevoked = match getString(this, ("STATUS_FC_" + certificationId)) {
198198 case a: String =>
199199 a
200200 case _ =>
201201 "NONE"
202202 }
203203 let callerIsWhiteListedNum = checkIfWhiteListed(callerAddress)
204204 let newJson = (((dropRight(entryExist, 1) + ",\"status\":\"REVOKED_") + toBase58String(id)) + "\"}")
205205 if ((isRevoked != "NONE"))
206206 then throw("This certification have already been revoked.")
207207 else if ((entryExist == "NONE"))
208208 then throw("You cannot change the status of this certification.")
209209 else if ((callerIsWhiteListedNum > 0))
210- then [IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum - 1)), StringEntry(("STATUS_FC_" + certificationId), ("REVOKED_" + toBase58String(id))), StringEntry(((("data_fc_" + certificationId) + "_") + callerAddress), newJson), ScriptTransfer(addressFromStringValue(callerAddress), 0, value(toBytes(acceptedToken)))]
210+ then [IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum - 1)), StringEntry(("STATUS_FC_" + certificationId), ("REVOKED_" + toBase58String(id))), StringEntry(((("data_fc_" + certificationId) + "_") + callerAddress), newJson), ScriptTransfer(addressFromStringValue(callerAddress), 0, fromBase58String(acceptedToken))]
211211 else if (!(callerIsDapp))
212212 then {
213213 let payment = value(invoke.payments[0])
214214 let amount = value(payment.amount)
215215 let paymentAssetId = if (isDefined(payment.assetId))
216216 then value(payment.assetId)
217217 else throw("Waves is not accepted as payment")
218218 let currentPrice = getIntegerValue(storageVerifier, ("certification_fee_" + toBase58String(value(paymentAssetId))))
219- if ((value(toBytes(acceptedToken)) != paymentAssetId))
219+ if ((fromBase58String(acceptedToken) != paymentAssetId))
220220 then throw("This token is not accepted at the moment")
221221 else if (if ((amount != currentPrice))
222222 then (0 >= callerIsWhiteListedNum)
223223 else false)
224224 then throw("The price is wrong")
225225 else [StringEntry(("STATUS_FC_" + certificationId), ("REVOKED_" + toBase58String(id))), StringEntry(((("data_fc_" + certificationId) + "_") + callerAddress), newJson), ScriptTransfer(addressFromStringValue(bank), amount, payment.assetId)]
226226 }
227227 else throw("You are not allowed to do that")
228228 }
229229
230230
231231
232232 @Callable(invoke)
233233 func usdnSignCredits () = {
234234 let payment = value(invoke.payments[0])
235235 let callerAddress = toBase58String(invoke.caller.bytes)
236236 let tokenId = value(payment.assetId)
237237 let amount = value(payment.amount)
238238 let numberOfCredits = ((amount * 2) / 1000000)
239239 let callerIsWhiteListedNum = checkIfWhiteListed(callerAddress)
240240 if ((toBase58String(tokenId) != usdnID))
241241 then throw("Only USDN can be exchanged")
242242 else if (if (((amount % 1000000) != 0))
243243 then ((amount % 1000000) != 500000)
244244 else false)
245245 then throw(((("You can only exchange multiple of 0.5, you sent:" + dropRight(toString(amount), 6)) + ".") + takeRight(toString(amount), 6)))
246246 else [IntegerEntry(("addr_WHITELISTED_" + callerAddress), (callerIsWhiteListedNum + numberOfCredits)), ScriptTransfer(addressFromStringValue(bank), amount, tokenId)]
247247 }
248248
249249
250250
251251 @Callable(i)
252252 func whitelistFreeCertifications (address,amount,addToCurrentAmount) = {
253253 let caller = toString(addressFromPublicKey(i.callerPublicKey))
254254 let id = toBase58String(i.transactionId)
255255 if (containsElement([chris], caller))
256256 then {
257257 let currentAmount = valueOrElse(getInteger(this, (address + "_free_txq")), 0)
258258 let newAmount = if (addToCurrentAmount)
259259 then (currentAmount + amount)
260260 else amount
261261 [IntegerEntry((address + "_free_txs"), newAmount)]
262262 }
263263 else throw("You are not authorized to whitelist txs")
264264 }
265265
266266
267267 @Verifier(tx)
268268 func verifier () = match tx {
269269 case inv: InvokeScriptTransaction =>
270270 if (if (if (if ((inv.function == "fileCertification"))
271271 then (inv.dApp == this)
272272 else false)
273273 then (inv.fee == 500000)
274274 else false)
275275 then (inv.feeAssetId == unit)
276276 else false)
277277 then sigVerify(tx.bodyBytes, tx.proofs[0], fromBase58String(asString(inv.args[4])))
278278 else if (if (if (if ((inv.function == "revokeCertification"))
279279 then (inv.dApp == this)
280280 else false)
281281 then (inv.fee == 500000)
282282 else false)
283283 then (inv.feeAssetId == unit)
284284 else false)
285285 then sigVerify(tx.bodyBytes, tx.proofs[0], fromBase58String(asString(inv.args[1])))
286286 else sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
287287 case _ =>
288288 sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
289289 }
290290

github/deemru/w8io/026f985 
43.19 ms