(ip)
| 59 | } |
| 60 | |
| 61 | function ipToInt(ip) { |
| 62 | const octets = ip.split('.'); |
| 63 | let result = 0; |
| 64 | for (let i = 0; i < octets.length; i++) { |
| 65 | result = (result << 8) + NumberParseInt(octets[i]); |
| 66 | } |
| 67 | // Force unsigned 32-bit result |
| 68 | return result >>> 0; |
| 69 | } |
| 70 | |
| 71 | // There are two factors in play when proxying the request: |
| 72 | // 1. What the request protocol is, that is, whether users are sending it via |
no test coverage detected
searching dependent graphs…