abhinav-phi commented on PR #2127: URL: https://github.com/apache/stormcrawler/pull/2127#issuecomment-5601942356
Thanks — pushed 19106ee8 closing all three items: **Shipped policy gaps.** `http.filter.ipaddress.exclude` now includes `0.0.0.0/8` and `::/128` (value: `localhost,sitelocal,linklocal,100.64.0.0/10,0.0.0.0/8,fc00::/7,::/128`). `IPFilterRules.accept` returned true for `0.0.0.0`, `0.1.2.3` and `::` before — the regex blocks the literals but a hostname resolving into those ranges still reached them. I used `::/128` (the exact unspecified address) rather than a broad IPv6 range so no routable address is excluded. `CIDR` handles both: `contains()` short-circuits on the v4/v6 byte-length mismatch, and the mapped-address mask shift does not misfire on a `::/128`. **Fixture restored.** `core/src/test/resources/default-regex-filters.txt` is back to its upstream content (the earlier revert had been undone by a later checkout on this branch). This PR's archetype copy is the separate `default-regex-filters-archetype.txt`, loaded by the new test, so `RegexFilterTest`/`URLFilterBoltTest` keep their original fixture. **Test coverage.** The shipped-default test now pins every excluded range with its boundary addresses and public neighbours (9.255.255.255 / 11.0.0.0, 172.15/172.32, 192.167/192.169, 100.63/100.128, plus a public IPv6), and the explicit opt-out (`http.filter.ipaddress.exclude: ""`) is asserted to install no rules. The integration check is `HttpProtocolIPFilterTest`: fetching `http://localhost:<port>` (resolves to loopback) under the shipped list throws the interceptor's `Forbidden connection to IP address …` IOException, and the same fetch returns 200 once the exclude list is overridden to empty — so the policy is shown enforced by the real HTTP protocol path, not just the predicates. Full core suite green (441). The workflow run will need a maintainer's workflow approval. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
