1

我的程序之前能够制作原始事务并将其发送到 geth v1.3.3,但是在我升级到 geth v1.4.0 之后,sendRawTransaction通过 RPC 调用总是返回invalid sender错误。

事务序列化(即 RLP)是否以某种方式从 v1.3.3 更改为 v1.4.0?这是触发invalid user错误的原始事务转储:

0x0000:   F8 CA 80 85 0B A4 3B 74   00 83 01 5F 90 94 08 BE    ......;t..._....
0x0010:   24 CD 8D CF 73 F8 FA 5D   B4 2B 85 5B 43 70 BD 5C    $...s..].+.[Cp.\
0x0020:   44 8B 80 B8 64 B0 70 B9   BA 00 00 00 00 00 00 00    D...d.p.........
0x0030:   00 00 00 00 00 00 00 00   00 00 00 00 00 00 00 00    ................
0x0040:   00 00 00 00 00 00 00 00   01 87 44 2E B8 96 6A 07    ..........D...j.
0x0050:   0C 31 C1 E8 AE A3 60 F5   35 32 47 81 13 34 31 D4    .1....`.52G..41.
0x0060:   4B FA 0A 0B 1B 9F 13 C6   F5 00 00 00 00 00 00 00    K...............
0x0070:   00 00 00 00 00 00 00 00   00 00 00 00 00 00 00 00    ................
0x0080:   00 00 00 00 00 00 00 00   00 1B A0 DE A4 6B 8C E8    .............k..
0x0090:   72 5A 31 49 92 EC 6B 6F   C6 89 8C BB D7 A4 B9 8A    rZ1I..ko........
0x00A0:   10 D2 F7 9E CE 6B D5 0F   C5 19 E9 A0 8F 74 57 C2    .....k.......tW.
0x00B0:   1C DA CB 7D 7A 2B 46 58   98 53 31 C3 4B CF 50 1F    ...}z+FX.S1.K.P.
0x00C0:   17 CE 16 80 95 30 38 9B   98 3C 5B B8                .....08..<[.

我的交易更机器可读的版本是:

F8CA80850BA43B740083015F909408BE24CD8DCF73F8FA5DB42B855B4370BD5C448B80B864B070B9BA000000000000000000000000000000000000000000000000000000000000000187442EB8966A070C31C1E8AEA360F535324781133431D44BFA0A0B1B9F13C6F500000000000000000000000000000000000000000000000000000000000000001BA0DEA46B8CE8725A314992EC6B6FC6898CBBD7A4B98A10D2F79ECE6BD50FC519E9A08F7457C21CDACB7D7A2B4658985331C34BCF501F17CE16809530389B983C5BB8

来自geth的日志给出

I0504 20:22:27.392581    9768 types.go:106] Generated response: *shared.ErrorResponse &{%!s(float64=1) 2.0 %!s(*shared.ErrorObject=&{-32603 Invalid sender})}
I0504 20:22:27.392886    9768 http.go:157] Sending payload: {
        "id": 1,
        "jsonrpc": "2.0",
        "error": {
                "code": -32603,
                "message": "Invalid sender"
        }
}
4

1 回答 1

1

我相信 JSON RPC 的东西在 geth v1.4.0 中发生了变化。如果没有看到您正在调用的完整 sendRawTransaction,我无法说出为什么会发生这种情况,但请查看文档:https ://github.com/ethereum/wiki/wiki/JSON-RPC#eth_sendtransaction

此外,这应该迁移到https://ethereum.stackexchange.com/

于 2016-05-05T03:31:56.187 回答