tx · GB65haHgcZnco5YZgUL753whqTt9uoKjU53b3L2Xk7dp
3MyXEmrjz8G5z2Q8xiyBnucF9LUyggiChiP: -0.01400000 Waves
2019.12.14 21:52 [808925] smart account 3MyXEmrjz8G5z2Q8xiyBnucF9LUyggiChiP > SELF 0.00000000 Waves
{
"type": 13,
"id": "GB65haHgcZnco5YZgUL753whqTt9uoKjU53b3L2Xk7dp",
"fee": 1400000,
"feeAssetId": null,
"timestamp": 1576349543304,
"version": 1,
"sender": "3MyXEmrjz8G5z2Q8xiyBnucF9LUyggiChiP",
"senderPublicKey": "GRSgAjHJFmqVyE1sdnUmweBHV962Q1MyURh4frCUS1My",
"proofs": [
"3fou73DAphGrzAnWKeiok7ZPF7XyYfM3qyD7DgPnt33xLMgpED6k3riDDMQgCTTkk6cE6PxT9yRBFjyc2Yjq24z9"
],
"script": "base64:AAIDAAAAAAAAAAwIARIICgYICAgICAgAAAAAAAAAAQAAAAFpAQAAAAphZGREZXBvc2l0AAAABgAAAARoYXNoAAAAB2FjY291bnQAAAAGYW1vdW50AAAAA3NlcQAAAAlnZW5lcmF0b3IAAAAJc2lnbmF0dXJlBAAAAAdtZXNzYWdlCQABmwAAAAEJAAEsAAAAAgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgkAASwAAAACCQABLAAAAAIFAAAABGhhc2gCAAAAASwFAAAAB2FjY291bnQCAAAAASwFAAAABmFtb3VudAIAAAABLAUAAAADc2VxBAAAAAttZXNzYWdlSGFzaAkAAfUAAAABBQAAAAdtZXNzYWdlBAAAABVtZXNzYWdlSGFzaFdpdGhQcmVmaXgJAADLAAAAAgkAAMsAAAACAQAAAAEZCQABmwAAAAECAAAAG0V0aGVyZXVtIFNpZ25lZCBNZXNzYWdlOgozMgUAAAALbWVzc2FnZUhhc2gDCQEAAAABIQAAAAEJAAH0AAAAAwUAAAAVbWVzc2FnZUhhc2hXaXRoUHJlZml4CQACXQAAAAEFAAAACXNpZ25hdHVyZQkAAl0AAAABBQAAAAlnZW5lcmF0b3IJAAACAAAAAQkAAlwAAAABBQAAABVtZXNzYWdlSGFzaFdpdGhQcmVmaXgEAAAADmNhbGN1bGF0ZWRIYXNoCQAB9QAAAAEJAADLAAAAAgkAAMsAAAACCQACXQAAAAEFAAAAB2FjY291bnQJAAJdAAAAAQUAAAAGYW1vdW50CQACXQAAAAEFAAAAA3NlcQMJAQAAAAIhPQAAAAIFAAAADmNhbGN1bGF0ZWRIYXNoCQACXQAAAAEFAAAABGhhc2gJAAACAAAAAQIAAAANaGFzaCBtaXNtYXRjaAkBAAAACFdyaXRlU2V0AAAAAQUAAAADbmlsAAAAAE9uQ/Y=",
"chainId": 84,
"height": 808925,
"spentComplexity": 0
}
View: original | compacted
Prev: 4aMeDa7MaAZ6BRwtACRqZi5y9VyPotAFbE1BG6cfY6ya
Next: 67TbWEaU4iYThF98rBahJBJtPerCVRQkHt1LCtfWhH8F
Diff:
Old | New | | Differences |
---|
10 | 10 | | let messageHashWithPrefix = ((base58'S' + toBytes("Ethereum Signed Message: |
---|
11 | 11 | | 32")) + messageHash) |
---|
12 | 12 | | if (!(sigVerify(messageHashWithPrefix, fromBase16String(signature), fromBase16String(generator)))) |
---|
13 | | - | then throw("sign") |
---|
| 13 | + | then throw(toBase16String(messageHashWithPrefix)) |
---|
14 | 14 | | else { |
---|
15 | 15 | | let calculatedHash = keccak256(((fromBase16String(account) + fromBase16String(amount)) + fromBase16String(seq))) |
---|
16 | 16 | | if ((calculatedHash != fromBase16String(hash))) |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 3 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | 4 | | |
---|
5 | 5 | | |
---|
6 | 6 | | @Callable(i) |
---|
7 | 7 | | func addDeposit (hash,account,amount,seq,generator,signature) = { |
---|
8 | 8 | | let message = toBytes(((((((hash + ",") + account) + ",") + amount) + ",") + seq)) |
---|
9 | 9 | | let messageHash = keccak256(message) |
---|
10 | 10 | | let messageHashWithPrefix = ((base58'S' + toBytes("Ethereum Signed Message: |
---|
11 | 11 | | 32")) + messageHash) |
---|
12 | 12 | | if (!(sigVerify(messageHashWithPrefix, fromBase16String(signature), fromBase16String(generator)))) |
---|
13 | | - | then throw("sign") |
---|
| 13 | + | then throw(toBase16String(messageHashWithPrefix)) |
---|
14 | 14 | | else { |
---|
15 | 15 | | let calculatedHash = keccak256(((fromBase16String(account) + fromBase16String(amount)) + fromBase16String(seq))) |
---|
16 | 16 | | if ((calculatedHash != fromBase16String(hash))) |
---|
17 | 17 | | then throw("hash mismatch") |
---|
18 | 18 | | else WriteSet(nil) |
---|
19 | 19 | | } |
---|
20 | 20 | | } |
---|
21 | 21 | | |
---|
22 | 22 | | |
---|