| 92 | } |
| 93 | |
| 94 | void pubkey_to_hash160(const struct pubkey *pk, struct ripemd160 *hash) |
| 95 | { |
| 96 | u8 der[PUBKEY_CMPR_LEN]; |
| 97 | struct sha256 h; |
| 98 | |
| 99 | pubkey_to_der(der, pk); |
| 100 | sha256(&h, der, sizeof(der)); |
| 101 | ripemd160(hash, h.u.u8, sizeof(h)); |
| 102 | } |
| 103 | |
| 104 | void fromwire_pubkey(const u8 **cursor, size_t *max, struct pubkey *pubkey) |
| 105 | { |
no test coverage detected