tx · EcsnAj1TsrQm5wXivg71rTxMSXtjUKJYo63fNBExwZiN
3NCAHkQMZsVNJh9u15MjBDHjY8efFKNArX8: -0.00500000 Waves
2022.10.04 07:48 [2257132] smart account 3NCAHkQMZsVNJh9u15MjBDHjY8efFKNArX8 > SELF 0.00000000 Waves
{
"type": 13,
"id": "EcsnAj1TsrQm5wXivg71rTxMSXtjUKJYo63fNBExwZiN",
"fee": 500000,
"feeAssetId": null,
"timestamp": 1664858916219,
"version": 2,
"chainId": 84,
"sender": "3NCAHkQMZsVNJh9u15MjBDHjY8efFKNArX8",
"senderPublicKey": "83Eyw5Bn6vkLTM9RkbXMAx8DtYNoLRqmeba4WAMvYhzK",
"proofs": [
"3LaSE644wynUsvwAKnyvfbyAyb6Xi3NBn32aAbZkkBVwUzRhZ9ahGhCc948rcmFyKYyNKufUaVTEDUEApjQAWwNz"
],
"script": "base64:AAIFAAAAAAAAAAgIAhIECgIICAAAAAMAAAAACVJTQVBVQkxJQwIAAAGITUlJQklqQU5CZ2txaGtpRzl3MEJBUUVGQUFPQ0FROEFNSUlCQ2dLQ0FRRUFsZW1yOTVKMWpaVXM3Y0ptcm1tbE40em83WVZzQkp6SWVKZGs4TERGR2hVS1NJNnlmczIwWnlKZTIxKzZHSndObktVVTFVeW9jMTd3U1dNS2tyWjBNTXZZRStaNUFpaWp2Qks0c1NKM0lnR2pkVTgvTmhJOENCRHUwRit4Uk05cTNUQjNMTGJEeTVzQmR1ZFlmSGZzVU9jK01UdkFENjluMjdkYjJSaDgreVpRTXR1Ymt1VFFOcDg5c3BoSFFhTEd5UUZhTmxLL05hM2xGeDZvbXF6YWExZ2pvcGxVcjZydllLZ2ZBSUNVQjN6Vm1KU2hpRWk3dzdSMGhXbE5SRDNxY1pqQ1VPTlNwRm80V2J6a25HT2F6dzg0QitJTUlGbklwWFd6UUw4Ulgwdk5jZnNCdkxEZk02azJaYWNxd3lNS2FMTHFpZ2RCaUdkSjdXKzBsT1N0T1FJREFRQUIAAAAAAnJwCQACWwAAAAEFAAAACVJTQVBVQkxJQwEAAAABcgAAAAIAAAAEcnNiYgAAAAZnYW1lSWQEAAAABGJnaWQJAAGbAAAAAQUAAAAGZ2FtZUlkBAAAAANyc3YJAAooAAAABAUAAAAGU0hBMjU2BQAAAARiZ2lkBQAAAARyc2JiBQAAAAJycAMJAQAAAAEhAAAAAQUAAAADcnN2CQAAAgAAAAECAAAAFUludmFsaWQgUlNBIHNpZ25hdHVyZQQAAAAEcmFuZAkAAGoAAAACCQAEsQAAAAEJAAH3AAAAAQUAAAAEcnNiYgAAAAAAAAAABgkABEwAAAACCQEAAAALU3RyaW5nRW50cnkAAAACAgAAAANyc3YJAAGlAAAAAQUAAAADcnN2CQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACAgAAAARyYW5kBQAAAARyYW5kBQAAAANuaWwAAAABAAAAAWkBAAAABGNhbGwAAAACAAAAAnJzAAAABmdhbWVJZAQAAAADcnNiCQACWwAAAAEFAAAAAnJzCQEAAAABcgAAAAIFAAAAA3JzYgUAAAAGZ2FtZUlkAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkTJJ+x",
"height": 2257132,
"applicationStatus": "succeeded",
"spentComplexity": 0
}
View: original | compacted
Prev: ATjm3Cd5aApncRZK2ByaPJJnmvG7V6tUiyWcDoMXQ1Yc
Next: HK6ZZCkrQRCZkVeBFWJsuLhQaU8vrRxzZADr7Zv5BkwR
Diff:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 5 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | | - | let RSAPUBLIC = "base64:MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAlemr95J1jZUs7cJmrmmlN4zo7YVsBJzIeJdk8LDFGhUKSI6yfs20ZyJe21+6GJwNnKUU1Uyoc17wSWMKkrZ0MMvYE+Z5AiijvBK4sSJ3IgGjdU8/NhI8CBDu0F+xRM9q3TB3LLbDy5sBdudYfHfsUOc+MTvAD69n27db2Rh8+yZQMtubkuTQNp89sphHQaLGyQFaNlK/Na3lFx6omqzaa1gjoplUr6rvYKgfAICUB3zVmJShiEi7w7R0hWlNRD3qcZjCUONSpFo4WbzknGOazw84B+IMIFnIpXWzQL8RX0vNcfsBvLDfM6k2ZacqwyMKaLLqigdBiGdJ7W+0lOStOQIDAQAB" |
---|
| 4 | + | let RSAPUBLIC = "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAlemr95J1jZUs7cJmrmmlN4zo7YVsBJzIeJdk8LDFGhUKSI6yfs20ZyJe21+6GJwNnKUU1Uyoc17wSWMKkrZ0MMvYE+Z5AiijvBK4sSJ3IgGjdU8/NhI8CBDu0F+xRM9q3TB3LLbDy5sBdudYfHfsUOc+MTvAD69n27db2Rh8+yZQMtubkuTQNp89sphHQaLGyQFaNlK/Na3lFx6omqzaa1gjoplUr6rvYKgfAICUB3zVmJShiEi7w7R0hWlNRD3qcZjCUONSpFo4WbzknGOazw84B+IMIFnIpXWzQL8RX0vNcfsBvLDfM6k2ZacqwyMKaLLqigdBiGdJ7W+0lOStOQIDAQAB" |
---|
5 | 5 | | |
---|
6 | 6 | | let rp = fromBase64String(RSAPUBLIC) |
---|
7 | 7 | | |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 5 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | | - | let RSAPUBLIC = "base64:MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAlemr95J1jZUs7cJmrmmlN4zo7YVsBJzIeJdk8LDFGhUKSI6yfs20ZyJe21+6GJwNnKUU1Uyoc17wSWMKkrZ0MMvYE+Z5AiijvBK4sSJ3IgGjdU8/NhI8CBDu0F+xRM9q3TB3LLbDy5sBdudYfHfsUOc+MTvAD69n27db2Rh8+yZQMtubkuTQNp89sphHQaLGyQFaNlK/Na3lFx6omqzaa1gjoplUr6rvYKgfAICUB3zVmJShiEi7w7R0hWlNRD3qcZjCUONSpFo4WbzknGOazw84B+IMIFnIpXWzQL8RX0vNcfsBvLDfM6k2ZacqwyMKaLLqigdBiGdJ7W+0lOStOQIDAQAB" |
---|
| 4 | + | let RSAPUBLIC = "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAlemr95J1jZUs7cJmrmmlN4zo7YVsBJzIeJdk8LDFGhUKSI6yfs20ZyJe21+6GJwNnKUU1Uyoc17wSWMKkrZ0MMvYE+Z5AiijvBK4sSJ3IgGjdU8/NhI8CBDu0F+xRM9q3TB3LLbDy5sBdudYfHfsUOc+MTvAD69n27db2Rh8+yZQMtubkuTQNp89sphHQaLGyQFaNlK/Na3lFx6omqzaa1gjoplUr6rvYKgfAICUB3zVmJShiEi7w7R0hWlNRD3qcZjCUONSpFo4WbzknGOazw84B+IMIFnIpXWzQL8RX0vNcfsBvLDfM6k2ZacqwyMKaLLqigdBiGdJ7W+0lOStOQIDAQAB" |
---|
5 | 5 | | |
---|
6 | 6 | | let rp = fromBase64String(RSAPUBLIC) |
---|
7 | 7 | | |
---|
8 | 8 | | func r (rsbb,gameId) = { |
---|
9 | 9 | | let bgid = toBytes(gameId) |
---|
10 | 10 | | let rsv = rsaVerify_16Kb(SHA256, bgid, rsbb, rp) |
---|
11 | 11 | | if (!(rsv)) |
---|
12 | 12 | | then throw("Invalid RSA signature") |
---|
13 | 13 | | else { |
---|
14 | 14 | | let rand = (toInt(sha256(rsbb)) % 6) |
---|
15 | 15 | | [StringEntry("rsv", toString(rsv)), IntegerEntry("rand", rand)] |
---|
16 | 16 | | } |
---|
17 | 17 | | } |
---|
18 | 18 | | |
---|
19 | 19 | | |
---|
20 | 20 | | @Callable(i) |
---|
21 | 21 | | func call (rs,gameId) = { |
---|
22 | 22 | | let rsb = fromBase64String(rs) |
---|
23 | 23 | | r(rsb, gameId) |
---|
24 | 24 | | } |
---|
25 | 25 | | |
---|
26 | 26 | | |
---|
27 | 27 | | @Verifier(tx) |
---|
28 | 28 | | func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) |
---|
29 | 29 | | |
---|