Skip to content

Update ipaddr.js to latest #65

Open

Description

@abhijeetsharma7

ipaddr.js is pinned at 1.9.1. The previous request (#23) was closed citing
ipaddr.js's "use 2.x for Node 10+, 1.x for older" policy. That rationale is
now stale:

  • Node 10 reached EOL in April 2021 (~5 years ago).
  • proxy-addr 2.0.0 dropped Node < 0.10 in Aug 2017; the floor is far below
    what 2.x ipaddr.js requires.
  • ipaddr.js 2.x is API-compatible with 1.x for proxy-addr's usage
    (parse, range, match).
  • 2.x ships additional reserved/special-purpose ranges (RFC7534, RFC7535,
    RFC7450, RFC6666, RFC5180, 198.18.0.0/15, 2001: blocks) that are
    security-relevant for trust-list matching.
  • A precedent: tinyhttp/proxy-addr@f891136 (Feb 2026) dropped ipaddr.js
    entirely in favour of the now-stable net.isIP + net.BlockList —
    another viable direction here.

Concrete asks (in order of effort):

  1. Bump dep to ^2.0.0.
  2. Or replace with native net.isIP + net.BlockList, like tinyhttp did.

Both eliminate the recurring FOSS-scan flag on consumers' trees.

Activity

  1. added and removed on Aug 18, 2026
  2. krzysdz commented on Aug 18, 2026

    @krzysdz

    proxy-addr 2.x still supports Node.js 0.10. Any change here would require a major version release (net.BlockList requires Node.js v15.0.0 or v14.18.0; ipaddr.js 2.x requires Node.js v10).

    • ipaddr.js 2.x is API-compatible with 1.x for proxy-addr's usage
      (parse, range, match).
    • 2.x ships additional reserved/special-purpose ranges (RFC7534, RFC7535,
      RFC7450, RFC6666, RFC5180, 198.18.0.0/15, 2001: blocks) that are
      security-relevant for trust-list matching.

    proxy-addr does not use .range(), so it'd be useful only if you use ipaddr.js 2.x and don't want duplicate dependencies.

    • A precedent: tinyhttp/proxy-addr@f891136 (Feb 2026) dropped ipaddr.js
      entirely in favour of the now-stable net.isIP + net.BlockList —
      another viable direction here.

    They reimplemented multiple ipaddr.js functions (e.g. related to IPv4 mapped addresses) - tinyhttp/tinyhttp#484. Their objective seems to be minimising the number of dependencies.

    ipaddr.js has some features in 2.x that could be useful (process, parseCIDR), so the update could be combined with/followed by some simplification on the proxy-addr side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions