@node-lightning/wire
Version:
Lightning Network Wire Protocol
17 lines (16 loc) • 619 B
TypeScript
/// <reference types="node" />
/**
* Converts a buffer containing an IPv6 address into string notation.
* String notation consists of 8 sets of 16-bits each. Each group is
* written as four hexadecimal values separated by colons (:). This method
* follows RFC 5952 shortening.
*
* @remarks
* RFC 5952 https://tools.ietf.org/html/rfc5952
*
* The following shortening rules are applied:
* 1. Leading zeros are shorted as much as possible
* 2. Zero compression is from left to right and
* 3. Addresses are returned in lowercase.
*/
export declare function ipv6StringFromBuffer(buffer: Buffer): string;