Commit 69a7663
Fix validation of 0/8 IPv4 addresses
0.0.0.0/8 IPv4 addresses are not illegal, just "reserved." This change
brings `InetAddressUtils` in line with the JDK's `InetAddress`
implementation, which accepts these addresses without issue, e.g.:
```java
InetAddress.getByAddress(new byte[]{ 0, 10, 25, 68 });
InetAddress.getByName("0.10.25.68");
```1 parent a70a62c commit 69a7663
File tree
2 files changed
+2
-3
lines changed- httpcore5/src
- main/java/org/apache/hc/core5/net
- test/java/org/apache/hc/core5/net
2 files changed
+2
-3
lines changedLines changed: 1 addition & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
63 | | - | |
| 62 | + | |
64 | 63 | | |
65 | 64 | | |
66 | 65 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| |||
48 | 49 | | |
49 | 50 | | |
50 | 51 | | |
51 | | - | |
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| |||
0 commit comments