moznion's tech blog

moznion's technical memo

Published proxy-protocol-js

(Japanese article is here: )

I had published a library that is named proxy-protocol-js.

This library recognizes the PROXY protocol and has responsibilities for building and parsing the protocol for JavaScript and TypeScript (for details of PROXY protocol, please refer to the following the spec: ).

This library's strengths are the following:

  • Supports V1 (text protocol) and V2 (binary protocol)
  • Supports multipurpose functions
    • To build a protocol payload
    • To parse a protocol payload
    • To identify the protocol version according to a protocol payload
  • Better performance than existing implementations
  • Supports TypeScript (i.e. this library is written in TypeScript)
  • No extra dependencies