(value)
| 138 | } |
| 139 | |
| 140 | function isLoopbackProxyUrl(value) { |
| 141 | var raw = String(value || '').trim().replace(/\/+$/, ''); |
| 142 | if (!raw) return false; |
| 143 | try { |
| 144 | var parsed = new URL(raw); |
| 145 | if (parsed.protocol !== 'http:') return false; |
| 146 | var host = parsed.hostname.toLowerCase(); |
| 147 | return host === '127.0.0.1' || host === 'localhost' || host === '::1' || host === '[::1]'; |
| 148 | } catch (_) { |
| 149 | return false; |
| 150 | } |
| 151 | } |
| 152 | |
| 153 | function readJsonFile(file) { |
| 154 | try { |
no outgoing calls
no test coverage detected