| 102 | } |
| 103 | |
| 104 | void fromwire_pubkey(const u8 **cursor, size_t *max, struct pubkey *pubkey) |
| 105 | { |
| 106 | u8 der[PUBKEY_CMPR_LEN]; |
| 107 | |
| 108 | if (!fromwire(cursor, max, der, sizeof(der))) |
| 109 | return; |
| 110 | |
| 111 | if (!pubkey_from_der(der, sizeof(der), pubkey)) { |
| 112 | SUPERVERBOSE("not a valid point"); |
| 113 | fromwire_fail(cursor, max); |
| 114 | } |
| 115 | } |
| 116 | |
| 117 | void towire_pubkey(u8 **pptr, const struct pubkey *pubkey) |
| 118 | { |
no test coverage detected