Class BlindedPath


  • public class BlindedPath
    extends Object
    Onion messages and payments can be sent and received to blinded paths, which serve to hide the identity of the recipient.
    • Method Detail

      • hash

        public long hash()
        Generates a non-cryptographic 64-bit hash of the BlindedPath.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • eq

        public boolean eq​(BlindedPath b)
        Checks if two BlindedPaths contain equal inner contents. This ignores pointers and is_owned flags and looks at the values in fields. Two objects with NULL inner values will be considered "equal" here.
      • new_for_message

        public static Result_BlindedPathNoneZ new_for_message​(byte[][] node_pks,
                                                              EntropySource entropy_source)
        Create a blinded path for an onion message, to be forwarded along `node_pks`. The last node pubkey in `node_pks` will be the destination node. Errors if less than two hops are provided or if `node_pk`(s) are invalid.
      • write

        public byte[] write()
        Serialize the BlindedPath object into a byte array which can be read by BlindedPath_read