@peac/net-node 0.12.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/LICENSE +190 -0
  2. package/README.md +736 -0
  3. package/dist/codes.d.ts +47 -0
  4. package/dist/codes.d.ts.map +1 -0
  5. package/dist/codes.js +53 -0
  6. package/dist/codes.js.map +1 -0
  7. package/dist/constants.d.ts +39 -0
  8. package/dist/constants.d.ts.map +1 -0
  9. package/dist/constants.js +39 -0
  10. package/dist/constants.js.map +1 -0
  11. package/dist/evidence-utils.d.ts +49 -0
  12. package/dist/evidence-utils.d.ts.map +1 -0
  13. package/dist/evidence-utils.js +109 -0
  14. package/dist/evidence-utils.js.map +1 -0
  15. package/dist/impl.d.ts +331 -0
  16. package/dist/impl.d.ts.map +1 -0
  17. package/dist/impl.js +1188 -0
  18. package/dist/impl.js.map +1 -0
  19. package/dist/index.d.ts +772 -0
  20. package/dist/index.d.ts.map +1 -0
  21. package/dist/index.js +1121 -0
  22. package/dist/index.js.map +1 -0
  23. package/dist/internal.d.ts +28 -0
  24. package/dist/internal.d.ts.map +1 -0
  25. package/dist/internal.js +59 -0
  26. package/dist/internal.js.map +1 -0
  27. package/dist/receipt-resolver.d.ts +65 -0
  28. package/dist/receipt-resolver.d.ts.map +1 -0
  29. package/dist/receipt-resolver.js +140 -0
  30. package/dist/receipt-resolver.js.map +1 -0
  31. package/dist/receipt-url-middleware.d.ts +87 -0
  32. package/dist/receipt-url-middleware.d.ts.map +1 -0
  33. package/dist/receipt-url-middleware.js +141 -0
  34. package/dist/receipt-url-middleware.js.map +1 -0
  35. package/dist/ssrf.d.ts +114 -0
  36. package/dist/ssrf.d.ts.map +1 -0
  37. package/dist/ssrf.js +214 -0
  38. package/dist/ssrf.js.map +1 -0
  39. package/dist/testing.d.ts +65 -0
  40. package/dist/testing.d.ts.map +1 -0
  41. package/dist/testing.js +103 -0
  42. package/dist/testing.js.map +1 -0
  43. package/package.json +79 -0
package/dist/impl.d.ts ADDED
@@ -0,0 +1,331 @@
1
+ /**
2
+ * Internal Implementation for @peac/net-node
3
+ *
4
+ * This module contains internal helper functions that are NOT part of the public API.
5
+ * These functions are used internally by index.ts and exposed ONLY via the testing subpath.
6
+ *
7
+ * IMPORTANT: This module is NOT listed in package.json exports, so it cannot be
8
+ * directly imported by consumers. Only the testing subpath re-exports from here.
9
+ *
10
+ * @internal
11
+ * @module @peac/net-node/impl
12
+ */
13
+ import ipaddr from 'ipaddr.js';
14
+ import { Agent } from 'undici';
15
+ import { type SSRFPolicy } from './ssrf.js';
16
+ import { SAFE_FETCH_ERROR_CODES } from './codes.js';
17
+ import { MAX_PENDING_AUDIT_EVENTS } from './constants.js';
18
+ export { MAX_PENDING_AUDIT_EVENTS };
19
+ import type { SafeFetchOptions, SafeFetchAuditHook, SafeFetchEvent, DnsResolutionResult, DnsResolutionError, DnsAnswer, DnsResolver, HttpClient, RedactedIpInfo, RedirectPolicy } from './index.js';
20
+ export type { DnsAnswer, RedactedIpInfo };
21
+ /**
22
+ * Happy Eyeballs connection timeout for first attempt (250ms)
23
+ */
24
+ export declare const HAPPY_EYEBALLS_FIRST_TIMEOUT_MS = 250;
25
+ /**
26
+ * Hop-by-hop headers that MUST NOT be forwarded (RFC 7230 Section 6.1)
27
+ * These are stripped from requests to prevent proxy confusion and smuggling
28
+ */
29
+ export declare const HOP_BY_HOP_HEADERS: Set<string>;
30
+ /**
31
+ * Blocked IPv4 range names from ipaddr.js
32
+ * These are always blocked (fail-closed security)
33
+ */
34
+ export declare const BLOCKED_IPV4_RANGES: Set<string>;
35
+ /**
36
+ * Additional IPv4 CIDR ranges to block (RFC 6890 compliance)
37
+ * Not covered by ipaddr.js range() but should be blocked
38
+ */
39
+ export declare const ADDITIONAL_BLOCKED_CIDRS_V4: Array<[ipaddr.IPv4, number]>;
40
+ /**
41
+ * Blocked IPv6 range names from ipaddr.js
42
+ */
43
+ export declare const BLOCKED_IPV6_RANGES: Set<string>;
44
+ /**
45
+ * Additional IPv6 CIDR ranges to block
46
+ */
47
+ export declare const ADDITIONAL_BLOCKED_CIDRS_V6: Array<[ipaddr.IPv6, number]>;
48
+ export { SAFE_FETCH_ERROR_CODES };
49
+ /**
50
+ * Hash an IP address for public evidence using SHA-256
51
+ *
52
+ * Returns a 0x-prefixed lowercase hex string for consistency with
53
+ * other PEAC cryptographic identifiers (e.g., EAS anchors).
54
+ *
55
+ * @param ip - Raw IP address string
56
+ * @returns SHA-256 hash as 0x-prefixed lowercase hex
57
+ * @internal
58
+ */
59
+ export declare function hashIpAddress(ip: string): string;
60
+ /**
61
+ * Create redacted IP info for public evidence
62
+ *
63
+ * @param ip - Raw IP address string
64
+ * @param options - Optional HMAC key for tenant mode
65
+ * @returns Redacted info with family and hash
66
+ * @internal
67
+ */
68
+ export declare function redactIp(ip: string, options?: {
69
+ key?: Uint8Array;
70
+ keyId?: string;
71
+ }): RedactedIpInfo;
72
+ /**
73
+ * Header input type (compatible with RequestInit.headers)
74
+ * Using a type alias to avoid dependency on DOM types
75
+ */
76
+ type HeaderInput = Headers | Record<string, string> | Array<[string, string]> | undefined;
77
+ /**
78
+ * Case-insensitive header presence check
79
+ *
80
+ * Works with any header input type (Headers, array, object).
81
+ * The Fetch API's Headers object is case-insensitive by spec, but this helper
82
+ * provides explicit case-insensitive checking for any input format.
83
+ *
84
+ * @param headers - Headers, array of [name, value] pairs, or plain object
85
+ * @param name - Header name to check (case-insensitive)
86
+ * @returns true if header exists (any casing)
87
+ * @internal
88
+ */
89
+ export declare function hasHeaderCaseInsensitive(headers: HeaderInput, name: string): boolean;
90
+ /**
91
+ * Parse a CIDR string into an ipaddr.js address and prefix length
92
+ * @internal
93
+ */
94
+ export declare function parseCidr(cidrStr: string): [ipaddr.IPv4 | ipaddr.IPv6, number] | null;
95
+ /**
96
+ * Check if an IP address matches any CIDR in a list
97
+ * @internal
98
+ */
99
+ export declare function matchesAnyCidr(addr: ipaddr.IPv4 | ipaddr.IPv6, cidrStrings: string[]): boolean;
100
+ /**
101
+ * Check if a CIDR string overlaps with any dangerous/private ranges
102
+ * Uses robust range-based overlap detection (conservative - false positives OK)
103
+ * @internal
104
+ */
105
+ export declare function cidrOverlapsDangerousRanges(cidrStr: string): boolean;
106
+ /**
107
+ * Check if an IP address is private/reserved using RFC 6890-grade classification
108
+ * @internal
109
+ */
110
+ export declare function isPrivateIP(ip: string, policy?: SSRFPolicy): boolean;
111
+ /**
112
+ * Validate that allowCidrs has proper acknowledgment if it contains dangerous ranges
113
+ * @internal
114
+ */
115
+ export declare function validateAllowCidrsAck(policy?: SSRFPolicy): {
116
+ valid: boolean;
117
+ error?: string;
118
+ };
119
+ /**
120
+ * Check if a hostname contains an IPv6 zone identifier
121
+ *
122
+ * Zone identifiers (e.g., %eth0, %25eth0) are used for link-local addresses
123
+ * and MUST be rejected to prevent SSRF bypasses via interface binding.
124
+ *
125
+ * @param hostname - Raw hostname from URL
126
+ * @returns true if zone ID is present
127
+ * @internal
128
+ */
129
+ export declare function hasIPv6ZoneId(hostname: string): boolean;
130
+ /**
131
+ * Normalize IPv4-mapped IPv6 address to IPv4
132
+ *
133
+ * IPv4-mapped IPv6 addresses (::ffff:a.b.c.d) can bypass IPv4 blocklists
134
+ * if not normalized. We convert them to plain IPv4 for consistent blocking.
135
+ *
136
+ * @param ip - IP address string
137
+ * @returns Normalized IP (IPv4 if it was IPv4-mapped, otherwise unchanged)
138
+ * @internal
139
+ */
140
+ export declare function normalizeIPv4MappedIPv6(ip: string): string;
141
+ /**
142
+ * Canonical host result
143
+ */
144
+ interface CanonicalHostResult {
145
+ ok: true;
146
+ hostname: string;
147
+ isIP: boolean;
148
+ originalHostname: string;
149
+ }
150
+ interface CanonicalHostError {
151
+ ok: false;
152
+ error: string;
153
+ code: string;
154
+ }
155
+ /**
156
+ * Canonicalize a hostname with full security validation
157
+ *
158
+ * This is the single source of truth for hostname processing:
159
+ * 1. Reject IPv6 zone identifiers (SSRF bypass prevention)
160
+ * 2. Lowercase and strip trailing dot
161
+ * 3. Normalize IDNs to ASCII (punycode)
162
+ * 4. Normalize IPv4-mapped IPv6 to IPv4
163
+ *
164
+ * @param hostname - Raw hostname from URL
165
+ * @returns Canonicalized hostname or error
166
+ * @internal
167
+ */
168
+ export declare function canonicalizeHost(hostname: string): CanonicalHostResult | CanonicalHostError;
169
+ /**
170
+ * Strip hop-by-hop headers from request headers
171
+ *
172
+ * RFC 7230 Section 6.1 defines hop-by-hop headers that MUST NOT be forwarded.
173
+ * Stripping these prevents proxy confusion and request smuggling attacks.
174
+ *
175
+ * @param headers - Headers object to sanitize (mutated in place)
176
+ * @internal
177
+ */
178
+ export declare function stripHopByHopHeaders(headers: Headers): void;
179
+ /**
180
+ * Normalize hostname for comparison:
181
+ * - Lowercase
182
+ * - Strip trailing dot
183
+ * - Convert to ASCII (punycode)
184
+ * - Normalize IPv4-mapped IPv6
185
+ * @internal
186
+ */
187
+ export declare function normalizeHostname(hostname: string): string;
188
+ /**
189
+ * Extract registrable domain (eTLD+1) from hostname using proper PSL
190
+ * Uses tldts library for accurate Public Suffix List matching
191
+ *
192
+ * IMPORTANT: This function accepts a hostname (from URL.hostname), NOT a host:port string.
193
+ * IPv6 addresses are returned as-is (they don't have registrable domains).
194
+ *
195
+ * @param hostname - A hostname (e.g., "example.com", "2001:db8::1"), NOT "host:port"
196
+ * @internal
197
+ */
198
+ export declare function getRegistrableDomain(hostname: string): string;
199
+ /**
200
+ * Check if redirect target is allowed by policy
201
+ * @internal
202
+ */
203
+ export declare function isRedirectAllowed(originalUrl: URL, redirectUrl: URL, policy: RedirectPolicy, allowHosts?: string[]): boolean;
204
+ /**
205
+ * Options for creating a pinned agent
206
+ * @internal
207
+ */
208
+ interface PinnedAgentOptions {
209
+ /** TCP/TLS connect timeout in milliseconds */
210
+ connectTimeoutMs?: number;
211
+ }
212
+ /**
213
+ * Create an undici Agent with DNS pinning and optional connect timeout
214
+ * @internal
215
+ */
216
+ export declare function createPinnedAgent(pinnedIp: string, _hostname: string, options?: PinnedAgentOptions): Agent;
217
+ /**
218
+ * Options for DNS resolution
219
+ * @internal
220
+ */
221
+ interface DnsResolveOptions {
222
+ policy: SSRFPolicy;
223
+ allowMixedPublicAndPrivate?: boolean;
224
+ }
225
+ /**
226
+ * P1.3: Wrap a promise with a timeout
227
+ * Returns a discriminated union to distinguish timeout from actual result
228
+ * @internal
229
+ */
230
+ export declare function withTimeout<T>(promise: Promise<T>, timeoutMs: number, timeoutCode: string): Promise<{
231
+ ok: true;
232
+ value: T;
233
+ } | {
234
+ ok: false;
235
+ code: string;
236
+ }>;
237
+ /**
238
+ * Resolve DNS and validate ALL resolved IPs, returning only safe ones
239
+ * Implements RFC 8305-style address family ordering
240
+ *
241
+ * SECURITY NOTES:
242
+ * - Error messages are intentionally generic to avoid leaking internal IPs
243
+ * - Structured dns_answers are returned for audit trail (debug mode only reveals in events)
244
+ * - Mixed DNS (public + private) requires explicit opt-in
245
+ *
246
+ * @internal
247
+ */
248
+ export declare function resolveDnsSecure(hostname: string, policy: SSRFPolicy, resolver: DnsResolver, dnsOptions?: DnsResolveOptions): Promise<DnsResolutionResult | DnsResolutionError>;
249
+ /**
250
+ * Attempt connection with Happy Eyeballs-style fallback (RFC 8305)
251
+ * Properly cancels and cleans up the losing attempt
252
+ * @internal
253
+ */
254
+ export declare function attemptWithFallback(url: string, dnsResult: DnsResolutionResult, httpClient: HttpClient, options: SafeFetchOptions): Promise<{
255
+ response: Response;
256
+ close: () => Promise<void>;
257
+ }>;
258
+ /**
259
+ * Read response body with size limit enforcement
260
+ * @internal
261
+ */
262
+ export declare function readBodyWithLimit(response: Response, maxBytes: number): Promise<{
263
+ ok: true;
264
+ body: ArrayBuffer;
265
+ } | {
266
+ ok: false;
267
+ error: string;
268
+ code: string;
269
+ }>;
270
+ /**
271
+ * Per-request audit context for tracking request-scoped counters
272
+ *
273
+ * All counters in this context are specific to a single safeFetch invocation.
274
+ * This ensures evidence accurately reflects the state of that specific request,
275
+ * not global process state.
276
+ *
277
+ * @internal
278
+ */
279
+ export interface RequestAuditContext {
280
+ /** Number of events currently pending for this request */
281
+ pending: number;
282
+ /** Number of events dropped for this request */
283
+ dropped: number;
284
+ /** Number of hook errors for this request */
285
+ hookErrors: number;
286
+ /** Number of hook errors suppressed for this request */
287
+ hookSuppressed: number;
288
+ }
289
+ /**
290
+ * Create a new request-scoped audit context
291
+ * @internal
292
+ */
293
+ export declare function createRequestAuditContext(): RequestAuditContext;
294
+ /**
295
+ * Reset audit queue statistics (for testing)
296
+ * @internal
297
+ */
298
+ export declare function resetAuditQueueStats(): void;
299
+ /**
300
+ * Get global audit queue statistics for monitoring (process-level)
301
+ *
302
+ * NOTE: For per-request stats, use the RequestAuditContext.
303
+ * This function returns process-level totals for operational monitoring.
304
+ *
305
+ * @returns Object with global pending count
306
+ */
307
+ export declare function getAuditQueueStats(): {
308
+ pending: number;
309
+ dropped: number;
310
+ };
311
+ /**
312
+ * Safely emit an audit event via microtask for performance isolation
313
+ *
314
+ * Events are queued via queueMicrotask to prevent slow hooks from blocking
315
+ * the request path. Ordering is guaranteed within a request but may
316
+ * interleave with other async operations.
317
+ *
318
+ * P1.4: Implements bounded queue to prevent microtask blowup.
319
+ * Events are dropped (not queued) if MAX_PENDING_AUDIT_EVENTS is exceeded.
320
+ * When drops occur, a rate-limited `audit_overflow` event is emitted.
321
+ *
322
+ * @param ctx - Request-scoped audit context for tracking per-request counters
323
+ * @internal
324
+ */
325
+ export declare function emitAuditEvent(ctx: RequestAuditContext, hook: SafeFetchAuditHook | undefined, sanitizer: ((message: string) => string) | 'off' | undefined, hookName: string, event: Omit<SafeFetchEvent, 'schema_version'>): void;
326
+ /**
327
+ * Sanitize URL for logging (remove credentials)
328
+ * @internal
329
+ */
330
+ export declare function sanitizeUrl(url: string): string;
331
+ //# sourceMappingURL=impl.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"impl.d.ts","sourceRoot":"","sources":["../src/impl.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;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