Function makeNoiseHandler

  • Parameters

    • __namedParameters: {
          NOISE_HEADER: Uint8Array;
          keyPair: KeyPair;
          logger: Logger<LoggerOptions>;
          routingInfo?: Buffer;
      }
      • NOISE_HEADER: Uint8Array
      • keyPair: KeyPair
      • logger: Logger<LoggerOptions>
      • Optional routingInfo?: Buffer

    Returns {
        authenticate: ((data) => void);
        decodeFrame: ((newData, onFrame) => Promise<void>);
        decrypt: ((ciphertext) => Buffer);
        encodeFrame: ((data) => Buffer);
        encrypt: ((plaintext) => Buffer);
        finishInit: (() => void);
        mixIntoKey: ((data) => void);
        processHandshake: ((__namedParameters, noiseKey) => Buffer);
    }

    • authenticate: ((data) => void)
        • (data): void
        • Parameters

          • data: Uint8Array

          Returns void

    • decodeFrame: ((newData, onFrame) => Promise<void>)
        • (newData, onFrame): Promise<void>
        • Parameters

          • newData: Uint8Array | Buffer
          • onFrame: ((buff) => void)
              • (buff): void
              • Parameters

                Returns void

          Returns Promise<void>

    • decrypt: ((ciphertext) => Buffer)
        • (ciphertext): Buffer
        • Parameters

          • ciphertext: Uint8Array

          Returns Buffer

    • encodeFrame: ((data) => Buffer)
        • (data): Buffer
        • Parameters

          • data: Uint8Array | Buffer

          Returns Buffer

    • encrypt: ((plaintext) => Buffer)
        • (plaintext): Buffer
        • Parameters

          • plaintext: Uint8Array

          Returns Buffer

    • finishInit: (() => void)
        • (): void
        • Returns void

    • mixIntoKey: ((data) => void)
        • (data): void
        • Parameters

          • data: Uint8Array

          Returns void

    • processHandshake: ((__namedParameters, noiseKey) => Buffer)
        • (__namedParameters, noiseKey): Buffer
        • Parameters

          Returns Buffer

Generated using TypeDoc