Files
bitcoin/src
Sebastian Falbesoner 100e8a75bf rpc: check and throw specific pubkey parsing errors in HexToPubKey
In the helper `HexToPubKey`, check for three different causes of legacy
public key parsing errors (in this order):

    - pubkey is not a hex string
    - pubkey doesn't have a valid length (33 or 65 bytes) [NEW]
    - pubkey is cryptographically invalid, i.e. not on curve
      (`IsFullyValid` check)

and throw a specific error message for each one. Note that the error
code is identical for all of them (-5), so this doesn't break RPC API
compatibility.

The helper is currently used for the RPCs `createmultisig` and
`addmultisigaddress`. The length checks can be removed from the
call-sites and error message checks in the functional tests are adapted.
2024-02-09 13:35:23 +01:00
..
2024-02-01 13:52:05 +01:00
2024-01-05 11:22:31 +01:00
2023-12-11 18:22:13 +01:00
2023-10-12 11:27:19 +02:00
2022-12-24 23:49:50 +00:00
2024-01-05 17:16:38 +00:00
2024-02-01 13:52:05 +01:00
2023-11-21 13:15:44 +00:00
2023-12-11 18:22:13 +01:00
2023-11-16 11:36:22 +10:00
2023-06-16 10:38:19 +01:00
2023-09-13 11:37:45 +01:00
2022-12-24 23:49:50 +00:00
2022-12-24 23:49:50 +00:00
2022-12-24 23:49:50 +00:00
2023-11-30 11:28:19 +01:00
2023-11-28 12:42:07 +01:00
2023-01-12 13:42:44 +00:00
2023-06-16 10:38:19 +01:00
2023-07-19 18:12:42 +02:00
2023-11-30 11:27:54 +01:00
2024-01-05 17:16:38 +00:00
2024-02-01 13:52:05 +01:00
2023-11-16 11:36:22 +10:00
2024-02-01 13:52:05 +01:00
2024-01-05 17:16:38 +00:00