IP lookup: add the iCloud Private Relay list, with is_relay #237

Closed
opened 2026-11-10 10:15:09 +01:00 by clawbot · 1 comment
Collaborator

Part of #203, from item 3 of the proposal sneak agreed to (#203 (comment), #203 (comment)). Depends on the rename issue linked from the plan on that issue.

Change.

  1. internal/iplist/lists.go gains icloud_private_relay: https://mask-api.icloud.com/egress-ip-ranges.csv, once a day. Each line starts with a network; the other columns are country, region and city and are not read. Its parser goes in internal/iplist/parse.go.
  2. flags.is_relay is true when the address is on that list.
before: "flags": {"is_tor": false, "is_vpn": false, "is_bogon": false}
after:  "flags": {"is_tor": false, "is_vpn": false, "is_relay": true, "is_bogon": false}

Measure. The file holds about 285,000 ranges. Compare the process's memory with and without the list loaded and put the figure in the README's Memory section.

Tests. A fixture with documentation addresses, IPv4 and IPv6; a wrong document fails the parse; is_relay true and false.

Done when. A real download parses (one line on the PR saying how many ranges it gave); the README lists the source and the field.

Model: opus-5-5

Part of https://git.eeqj.de/sneak/routewatch/issues/203, from item 3 of the proposal sneak agreed to (https://git.eeqj.de/sneak/routewatch/issues/203#issuecomment-159864, https://git.eeqj.de/sneak/routewatch/issues/203#issuecomment-165190). Depends on the rename issue linked from the plan on that issue. **Change.** 1. `internal/iplist/lists.go` gains `icloud_private_relay`: https://mask-api.icloud.com/egress-ip-ranges.csv, once a day. Each line starts with a network; the other columns are country, region and city and are not read. Its parser goes in `internal/iplist/parse.go`. 2. `flags.is_relay` is true when the address is on that list. ```json before: "flags": {"is_tor": false, "is_vpn": false, "is_bogon": false} after: "flags": {"is_tor": false, "is_vpn": false, "is_relay": true, "is_bogon": false} ``` **Measure.** The file holds about 285,000 ranges. Compare the process's memory with and without the list loaded and put the figure in the README's Memory section. **Tests.** A fixture with documentation addresses, IPv4 and IPv6; a wrong document fails the parse; `is_relay` true and false. **Done when.** A real download parses (one line on the PR saying how many ranges it gave); the README lists the source and the field. Model: opus-5-5
clawbot self-assigned this 2026-11-10 10:15:09 +01:00
Author
Collaborator

Built in #250: the icloud_private_relay list and flags.is_relay, with the memory figure in the README's Memory section.

Model: opus-5-5

Built in https://git.eeqj.de/sneak/routewatch/pulls/250: the `icloud_private_relay` list and `flags.is_relay`, with the memory figure in the README's Memory section. Model: opus-5-5
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/routewatch#237