@arcis/node 1.0.0 → 1.2.0

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 (54) hide show
  1. package/README.md +156 -222
  2. package/dist/core/index.d.mts +4 -4
  3. package/dist/core/index.d.ts +4 -4
  4. package/dist/core/index.js +13 -2
  5. package/dist/core/index.js.map +1 -1
  6. package/dist/core/index.mjs +13 -2
  7. package/dist/core/index.mjs.map +1 -1
  8. package/dist/index-A-m-pPeW.d.mts +340 -0
  9. package/dist/index-CgK94hY_.d.mts +532 -0
  10. package/dist/index-Co5kPRZz.d.ts +340 -0
  11. package/dist/index-D_bdJcF0.d.ts +532 -0
  12. package/dist/index.d.mts +144 -108
  13. package/dist/index.d.ts +144 -108
  14. package/dist/index.js +1541 -211
  15. package/dist/index.js.map +1 -1
  16. package/dist/index.mjs +1515 -212
  17. package/dist/index.mjs.map +1 -1
  18. package/dist/logging/index.d.mts +1 -1
  19. package/dist/logging/index.d.ts +1 -1
  20. package/dist/logging/index.js +12 -1
  21. package/dist/logging/index.js.map +1 -1
  22. package/dist/logging/index.mjs +12 -1
  23. package/dist/logging/index.mjs.map +1 -1
  24. package/dist/middleware/index.d.mts +2 -2
  25. package/dist/middleware/index.d.ts +2 -2
  26. package/dist/middleware/index.js +524 -4
  27. package/dist/middleware/index.js.map +1 -1
  28. package/dist/middleware/index.mjs +517 -5
  29. package/dist/middleware/index.mjs.map +1 -1
  30. package/dist/{headers-DBQedhrb.d.mts → pii-CXcHMlnX.d.mts} +156 -2
  31. package/dist/{headers-BJq2OA0i.d.ts → pii-DhNpl7M3.d.ts} +156 -2
  32. package/dist/sanitizers/index.d.mts +2 -2
  33. package/dist/sanitizers/index.d.ts +2 -2
  34. package/dist/sanitizers/index.js +331 -3
  35. package/dist/sanitizers/index.js.map +1 -1
  36. package/dist/sanitizers/index.mjs +321 -4
  37. package/dist/sanitizers/index.mjs.map +1 -1
  38. package/dist/stores/index.d.mts +1 -1
  39. package/dist/stores/index.d.ts +1 -1
  40. package/dist/stores/index.js.map +1 -1
  41. package/dist/stores/index.mjs.map +1 -1
  42. package/dist/{types-BOdL3ZWo.d.mts → types-CsOFHoD9.d.mts} +6 -1
  43. package/dist/{types-BOdL3ZWo.d.ts → types-CsOFHoD9.d.ts} +6 -1
  44. package/dist/validation/index.d.mts +2 -2
  45. package/dist/validation/index.d.ts +2 -2
  46. package/dist/validation/index.js +504 -2
  47. package/dist/validation/index.js.map +1 -1
  48. package/dist/validation/index.mjs +498 -3
  49. package/dist/validation/index.mjs.map +1 -1
  50. package/package.json +114 -109
  51. package/dist/index-BgHPM7LC.d.ts +0 -129
  52. package/dist/index-BpT7flAQ.d.ts +0 -255
  53. package/dist/index-JaFOUKyK.d.mts +0 -255
  54. package/dist/index-nAgXexwD.d.mts +0 -129
package/package.json CHANGED
@@ -1,109 +1,114 @@
1
- {
2
- "name": "@arcis/node",
3
- "version": "1.0.0",
4
- "description": "One-line security middleware for Node.js apps.",
5
- "main": "dist/index.js",
6
- "module": "dist/index.mjs",
7
- "types": "dist/index.d.ts",
8
- "exports": {
9
- ".": {
10
- "types": "./dist/index.d.ts",
11
- "import": "./dist/index.mjs",
12
- "require": "./dist/index.js"
13
- },
14
- "./core": {
15
- "types": "./dist/core/index.d.ts",
16
- "import": "./dist/core/index.mjs",
17
- "require": "./dist/core/index.js"
18
- },
19
- "./sanitizers": {
20
- "types": "./dist/sanitizers/index.d.ts",
21
- "import": "./dist/sanitizers/index.mjs",
22
- "require": "./dist/sanitizers/index.js"
23
- },
24
- "./middleware": {
25
- "types": "./dist/middleware/index.d.ts",
26
- "import": "./dist/middleware/index.mjs",
27
- "require": "./dist/middleware/index.js"
28
- },
29
- "./validation": {
30
- "types": "./dist/validation/index.d.ts",
31
- "import": "./dist/validation/index.mjs",
32
- "require": "./dist/validation/index.js"
33
- },
34
- "./logging": {
35
- "types": "./dist/logging/index.d.ts",
36
- "import": "./dist/logging/index.mjs",
37
- "require": "./dist/logging/index.js"
38
- },
39
- "./stores": {
40
- "types": "./dist/stores/index.d.ts",
41
- "import": "./dist/stores/index.mjs",
42
- "require": "./dist/stores/index.js"
43
- }
44
- },
45
- "files": [
46
- "dist"
47
- ],
48
- "scripts": {
49
- "build": "tsup",
50
- "dev": "tsup --watch",
51
- "test": "vitest",
52
- "test:unit": "vitest run tests/index.test.ts",
53
- "test:integration": "vitest run tests/integration.test.ts",
54
- "test:conformance": "vitest run tests/conformance.test.ts",
55
- "test:coverage": "vitest --coverage",
56
- "lint": "eslint src --ext .ts",
57
- "typecheck": "tsc --noEmit",
58
- "prepublishOnly": "npm run build"
59
- },
60
- "keywords": [
61
- "security",
62
- "express",
63
- "middleware",
64
- "xss",
65
- "sql-injection",
66
- "nosql-injection",
67
- "rate-limit",
68
- "sanitize",
69
- "validation",
70
- "csrf",
71
- "helmet",
72
- "nodejs",
73
- "arcis",
74
- "ssrf",
75
- "open-redirect",
76
- "cors",
77
- "prototype-pollution",
78
- "command-injection",
79
- "path-traversal",
80
- "security-headers",
81
- "input-validation",
82
- "web-security"
83
- ],
84
- "author": "Gagan CM",
85
- "license": "MIT",
86
- "peerDependencies": {
87
- "express": ">=4.0.0"
88
- },
89
- "devDependencies": {
90
- "@types/express": "^5.0.6",
91
- "@types/node": "^25.5.0",
92
- "eslint": "^8.55.0",
93
- "express": "^5.2.1",
94
- "tsup": "^8.0.1",
95
- "typescript": "^5.3.2",
96
- "vitest": "^4.1.0"
97
- },
98
- "repository": {
99
- "type": "git",
100
- "url": "https://github.com/GagancM/arcis"
101
- },
102
- "bugs": {
103
- "url": "https://github.com/GagancM/arcis/issues"
104
- },
105
- "homepage": "https://github.com/GagancM/arcis#readme",
106
- "engines": {
107
- "node": ">=18.0.0"
108
- }
109
- }
1
+ {
2
+ "name": "@arcis/node",
3
+ "version": "1.2.0",
4
+ "description": "One-line security middleware for Node.js apps.",
5
+ "main": "dist/index.js",
6
+ "module": "dist/index.mjs",
7
+ "types": "dist/index.d.ts",
8
+ "exports": {
9
+ ".": {
10
+ "types": "./dist/index.d.ts",
11
+ "import": "./dist/index.mjs",
12
+ "require": "./dist/index.js"
13
+ },
14
+ "./core": {
15
+ "types": "./dist/core/index.d.ts",
16
+ "import": "./dist/core/index.mjs",
17
+ "require": "./dist/core/index.js"
18
+ },
19
+ "./sanitizers": {
20
+ "types": "./dist/sanitizers/index.d.ts",
21
+ "import": "./dist/sanitizers/index.mjs",
22
+ "require": "./dist/sanitizers/index.js"
23
+ },
24
+ "./middleware": {
25
+ "types": "./dist/middleware/index.d.ts",
26
+ "import": "./dist/middleware/index.mjs",
27
+ "require": "./dist/middleware/index.js"
28
+ },
29
+ "./validation": {
30
+ "types": "./dist/validation/index.d.ts",
31
+ "import": "./dist/validation/index.mjs",
32
+ "require": "./dist/validation/index.js"
33
+ },
34
+ "./logging": {
35
+ "types": "./dist/logging/index.d.ts",
36
+ "import": "./dist/logging/index.mjs",
37
+ "require": "./dist/logging/index.js"
38
+ },
39
+ "./stores": {
40
+ "types": "./dist/stores/index.d.ts",
41
+ "import": "./dist/stores/index.mjs",
42
+ "require": "./dist/stores/index.js"
43
+ },
44
+ "./utils": {
45
+ "types": "./dist/utils/index.d.ts",
46
+ "import": "./dist/utils/index.mjs",
47
+ "require": "./dist/utils/index.js"
48
+ }
49
+ },
50
+ "files": [
51
+ "dist"
52
+ ],
53
+ "scripts": {
54
+ "build": "tsup",
55
+ "dev": "tsup --watch",
56
+ "test": "vitest",
57
+ "test:unit": "vitest run tests/index.test.ts",
58
+ "test:integration": "vitest run tests/integration.test.ts",
59
+ "test:conformance": "vitest run tests/conformance.test.ts",
60
+ "test:coverage": "vitest --coverage",
61
+ "lint": "eslint src --ext .ts",
62
+ "typecheck": "tsc --noEmit",
63
+ "prepublishOnly": "npm run build"
64
+ },
65
+ "keywords": [
66
+ "security",
67
+ "express",
68
+ "middleware",
69
+ "xss",
70
+ "sql-injection",
71
+ "nosql-injection",
72
+ "rate-limit",
73
+ "sanitize",
74
+ "validation",
75
+ "csrf",
76
+ "helmet",
77
+ "nodejs",
78
+ "arcis",
79
+ "ssrf",
80
+ "open-redirect",
81
+ "cors",
82
+ "prototype-pollution",
83
+ "command-injection",
84
+ "path-traversal",
85
+ "security-headers",
86
+ "input-validation",
87
+ "web-security"
88
+ ],
89
+ "author": "Gagan CM",
90
+ "license": "MIT",
91
+ "peerDependencies": {
92
+ "express": ">=4.0.0"
93
+ },
94
+ "devDependencies": {
95
+ "@types/express": "^5.0.6",
96
+ "@types/node": "^25.5.0",
97
+ "eslint": "^8.55.0",
98
+ "express": "^5.2.1",
99
+ "tsup": "^8.0.1",
100
+ "typescript": "^5.3.2",
101
+ "vitest": "^4.1.0"
102
+ },
103
+ "repository": {
104
+ "type": "git",
105
+ "url": "https://github.com/GagancM/arcis"
106
+ },
107
+ "bugs": {
108
+ "url": "https://github.com/GagancM/arcis/issues"
109
+ },
110
+ "homepage": "https://github.com/GagancM/arcis#readme",
111
+ "engines": {
112
+ "node": ">=18.0.0"
113
+ }
114
+ }
@@ -1,129 +0,0 @@
1
- import { RequestHandler } from 'express';
2
- import { n as ValidationSchema } from './types-BOdL3ZWo.js';
3
-
4
- /**
5
- * @module @arcis/node/validation/schema
6
- * Request validation middleware
7
- */
8
-
9
- /**
10
- * Create Express middleware for request validation.
11
- * Prevents mass assignment by only allowing fields defined in the schema.
12
- *
13
- * @param schema - Validation schema defining expected fields
14
- * @param source - Request property to validate ('body', 'query', or 'params')
15
- * @returns Express middleware
16
- *
17
- * @example
18
- * app.post('/users', validate({
19
- * email: { type: 'email', required: true },
20
- * name: { type: 'string', min: 2, max: 50 },
21
- * age: { type: 'number', min: 0, max: 150 },
22
- * role: { type: 'string', enum: ['user', 'admin'] }
23
- * }), handler);
24
- *
25
- * @example
26
- * // Validate query params
27
- * app.get('/search', validate({
28
- * q: { type: 'string', required: true, min: 1 },
29
- * page: { type: 'number', min: 1 }
30
- * }, 'query'), handler);
31
- */
32
- declare function validate(schema: ValidationSchema, source?: 'body' | 'query' | 'params'): RequestHandler;
33
- /**
34
- * Alias for validate
35
- * @see validate
36
- */
37
- declare const createValidator: typeof validate;
38
-
39
- /**
40
- * @module @arcis/node/validation/file
41
- * File upload validation and filename sanitization
42
- */
43
- /** File upload validation options */
44
- interface ValidateFileOptions {
45
- /** Maximum file size in bytes. Default: 5MB */
46
- maxSize?: number;
47
- /** Allowed MIME types (e.g., ['image/jpeg', 'image/png']) */
48
- allowedTypes?: string[];
49
- /** Allowed file extensions (e.g., ['.jpg', '.png']). Includes dot. */
50
- allowedExtensions?: string[];
51
- /** Block dangerous/executable extensions. Default: true */
52
- blockExecutables?: boolean;
53
- /** Validate magic bytes match the claimed MIME type. Default: true */
54
- validateMagicBytes?: boolean;
55
- /** Block files with no extension. Default: true */
56
- blockNoExtension?: boolean;
57
- /** Block double extensions (e.g., file.php.jpg). Default: true */
58
- blockDoubleExtensions?: boolean;
59
- }
60
- /** File metadata for validation */
61
- interface FileInput {
62
- /** Original filename */
63
- filename: string;
64
- /** MIME type (as claimed by client) */
65
- mimetype: string;
66
- /** File size in bytes */
67
- size: number;
68
- /** File content buffer (for magic byte validation) */
69
- buffer?: Buffer;
70
- }
71
- /** File validation result */
72
- interface ValidateFileResult {
73
- /** Whether the file passed validation */
74
- valid: boolean;
75
- /** Validation errors (empty if valid) */
76
- errors: string[];
77
- /** Sanitized filename (safe for storage) */
78
- sanitizedFilename: string;
79
- }
80
- /**
81
- * Sanitize a filename for safe storage.
82
- *
83
- * Strips path traversal, null bytes, control characters, and special characters.
84
- * Preserves the extension and converts to a filesystem-safe name.
85
- *
86
- * @param filename - The original filename
87
- * @returns A sanitized filename safe for storage
88
- *
89
- * @example
90
- * sanitizeFilename('../../etc/passwd') // 'etc_passwd'
91
- * sanitizeFilename('file<name>.jpg') // 'filename.jpg'
92
- * sanitizeFilename('photo (1).jpg') // 'photo_1.jpg'
93
- * sanitizeFilename('.htaccess') // 'htaccess'
94
- */
95
- declare function sanitizeFilename(filename: string): string;
96
- /**
97
- * Validate a file upload for security.
98
- *
99
- * Checks file size, MIME type, extension, magic bytes, and dangerous patterns.
100
- * Returns a result with validation errors and a sanitized filename.
101
- *
102
- * @param file - File metadata and optional content
103
- * @param options - Validation options
104
- * @returns Validation result
105
- *
106
- * @example
107
- * const result = validateFile(
108
- * { filename: 'photo.jpg', mimetype: 'image/jpeg', size: 1024, buffer },
109
- * { allowedTypes: ['image/jpeg', 'image/png'], maxSize: 2 * 1024 * 1024 }
110
- * );
111
- * if (!result.valid) {
112
- * return res.status(400).json({ errors: result.errors });
113
- * }
114
- * // Use result.sanitizedFilename for storage
115
- *
116
- * @example
117
- * // Block executables only (no whitelist)
118
- * const result = validateFile(file, { blockExecutables: true });
119
- */
120
- declare function validateFile(file: FileInput, options?: ValidateFileOptions): ValidateFileResult;
121
- /**
122
- * Check if a file extension is considered dangerous/executable.
123
- *
124
- * @param filename - Filename or extension to check
125
- * @returns true if the extension is dangerous
126
- */
127
- declare function isDangerousExtension(filename: string): boolean;
128
-
129
- export { type FileInput as F, type ValidateFileOptions as V, type ValidateFileResult as a, validateFile as b, createValidator as c, isDangerousExtension as i, sanitizeFilename as s, validate as v };
@@ -1,255 +0,0 @@
1
- import { b as ArcisOptions, o as ArcisMiddlewareStack, A as ArcisFunction, e as RateLimitOptions, h as RateLimiterMiddleware, H as HeaderOptions, E as ErrorHandlerOptions } from './types-BOdL3ZWo.js';
2
- import { RequestHandler, Request, Response, NextFunction } from 'express';
3
-
4
- /**
5
- * @module @arcis/node/middleware/main
6
- * Main arcis() middleware factory
7
- */
8
-
9
- /**
10
- * Create Arcis middleware with all protections enabled.
11
- *
12
- * @param options - Configuration options
13
- * @returns Array of Express middleware
14
- *
15
- * @example
16
- * // Full protection (recommended)
17
- * app.use(arcis());
18
- *
19
- * @example
20
- * // Custom configuration
21
- * app.use(arcis({
22
- * rateLimit: { max: 50 },
23
- * headers: { frameOptions: 'SAMEORIGIN' }
24
- * }));
25
- *
26
- * @example
27
- * // Disable specific features
28
- * app.use(arcis({
29
- * rateLimit: false,
30
- * sanitize: { sql: false }
31
- * }));
32
- *
33
- * @example
34
- * // Cleanup on shutdown
35
- * const middleware = arcis();
36
- * app.use(middleware);
37
- * process.on('SIGTERM', () => middleware.close());
38
- */
39
- declare function arcis(options?: ArcisOptions): ArcisMiddlewareStack;
40
- declare const arcisWithMethods: ArcisFunction;
41
-
42
- /**
43
- * @module @arcis/node/middleware/rate-limit
44
- * Rate limiting middleware
45
- */
46
-
47
- /**
48
- * Create Express middleware for rate limiting.
49
- *
50
- * @param options - Rate limit configuration
51
- * @returns Express middleware with cleanup method
52
- *
53
- * @example
54
- * app.use(createRateLimiter({ max: 100, windowMs: 60000 }));
55
- *
56
- * @example
57
- * // Skip rate limiting for certain routes
58
- * app.use(createRateLimiter({
59
- * max: 50,
60
- * skip: (req) => req.path === '/health'
61
- * }));
62
- *
63
- * @example
64
- * // Cleanup on shutdown
65
- * const limiter = createRateLimiter();
66
- * app.use(limiter);
67
- * process.on('SIGTERM', () => limiter.close());
68
- */
69
- declare function createRateLimiter(options?: RateLimitOptions): RateLimiterMiddleware;
70
- /**
71
- * Alias for createRateLimiter
72
- * @see createRateLimiter
73
- */
74
- declare const rateLimit: typeof createRateLimiter;
75
-
76
- /**
77
- * @module @arcis/node/middleware/headers
78
- * Security headers middleware
79
- */
80
-
81
- /**
82
- * Create Express middleware for security headers.
83
- * Sets CSP, HSTS, X-Frame-Options, and other security headers.
84
- *
85
- * @param options - Header configuration
86
- * @returns Express middleware
87
- *
88
- * @example
89
- * app.use(createHeaders());
90
- *
91
- * @example
92
- * app.use(createHeaders({
93
- * frameOptions: 'SAMEORIGIN',
94
- * contentSecurityPolicy: "default-src 'self'"
95
- * }));
96
- */
97
- declare function createHeaders(options?: HeaderOptions): RequestHandler;
98
- /**
99
- * Alias for createHeaders
100
- * @see createHeaders
101
- */
102
- declare const securityHeaders: typeof createHeaders;
103
-
104
- /**
105
- * @module @arcis/node/middleware/error-handler
106
- * Production-safe error handler middleware
107
- */
108
-
109
- /**
110
- * Create Express error handler that hides sensitive details in production.
111
- *
112
- * Prevents information leakage by:
113
- * - Hiding stack traces in production
114
- * - Hiding error messages unless explicitly exposed
115
- * - Scrubbing database errors, connection strings, and internal IPs
116
- *
117
- * @param options - Error handler configuration (or boolean for isDev)
118
- * @returns Express error handling middleware
119
- *
120
- * @example
121
- * // Production mode (default) - hides error details
122
- * app.use(errorHandler());
123
- *
124
- * @example
125
- * // Development mode - shows error details and stack traces
126
- * app.use(errorHandler({ isDev: true }));
127
- *
128
- * @example
129
- * // With custom logger
130
- * app.use(errorHandler({
131
- * isDev: false,
132
- * logger: arcis.logger()
133
- * }));
134
- */
135
- declare function errorHandler(options?: ErrorHandlerOptions | boolean): (err: Error, req: Request, res: Response, next: NextFunction) => void;
136
- /**
137
- * Alias for errorHandler
138
- * @see errorHandler
139
- */
140
- declare const createErrorHandler: typeof errorHandler;
141
-
142
- /**
143
- * @module @arcis/node/middleware/cors
144
- * Safe CORS middleware with secure defaults
145
- */
146
-
147
- /** CORS configuration options */
148
- interface CorsOptions {
149
- /**
150
- * Allowed origins. Can be:
151
- * - A string: exact match (e.g., 'https://example.com')
152
- * - An array: whitelist of allowed origins
153
- * - A RegExp: pattern match (use with care)
154
- * - A function: custom validation `(origin) => boolean`
155
- * - `true`: reflect the request origin (DANGEROUS — only for dev)
156
- *
157
- * Default: none (no origin allowed). You must explicitly set this.
158
- */
159
- origin: string | string[] | RegExp | ((origin: string) => boolean) | true;
160
- /** Allowed HTTP methods. Default: ['GET', 'HEAD', 'PUT', 'PATCH', 'POST', 'DELETE'] */
161
- methods?: string[];
162
- /** Allowed headers. Default: ['Content-Type', 'Authorization'] */
163
- allowedHeaders?: string[];
164
- /** Headers exposed to the browser. Default: [] */
165
- exposedHeaders?: string[];
166
- /** Allow credentials (cookies, authorization headers). Default: false */
167
- credentials?: boolean;
168
- /** Preflight cache duration in seconds. Default: 600 (10 minutes) */
169
- maxAge?: number;
170
- /** Respond to preflight with 204 (no content). Default: true */
171
- preflightContinue?: boolean;
172
- }
173
- /**
174
- * Create safe CORS middleware.
175
- *
176
- * Unlike permissive CORS libraries, this enforces secure defaults:
177
- * - No wildcard `*` when credentials are enabled
178
- * - `null` origin is always blocked
179
- * - `Vary: Origin` is always set for proper caching
180
- * - You must explicitly configure allowed origins
181
- *
182
- * @param options - CORS configuration
183
- * @returns Express middleware
184
- *
185
- * @example
186
- * // Allow a single origin
187
- * app.use(safeCors({ origin: 'https://myapp.com' }));
188
- *
189
- * @example
190
- * // Allow multiple origins with credentials
191
- * app.use(safeCors({
192
- * origin: ['https://myapp.com', 'https://admin.myapp.com'],
193
- * credentials: true,
194
- * }));
195
- *
196
- * @example
197
- * // Development: allow all (NOT for production)
198
- * app.use(safeCors({ origin: true }));
199
- */
200
- declare function safeCors(options: CorsOptions): RequestHandler;
201
- /**
202
- * Alias for safeCors
203
- * @see safeCors
204
- */
205
- declare const createCors: typeof safeCors;
206
-
207
- /**
208
- * @module @arcis/node/middleware/cookies
209
- * Secure cookie defaults middleware
210
- */
211
-
212
- /** Cookie security configuration */
213
- interface SecureCookieOptions {
214
- /** Force HttpOnly on all cookies. Default: true */
215
- httpOnly?: boolean;
216
- /** Force Secure flag (HTTPS only). Default: true in production, false in dev */
217
- secure?: boolean;
218
- /** SameSite attribute. Default: 'Lax' */
219
- sameSite?: 'Strict' | 'Lax' | 'None' | false;
220
- /** Override Path attribute. Default: undefined (keep original) */
221
- path?: string;
222
- }
223
- /**
224
- * Enforce secure defaults on a Set-Cookie header value.
225
- */
226
- declare function enforceSecureCookie(cookieStr: string, options: Required<Omit<SecureCookieOptions, 'path'>> & {
227
- path?: string;
228
- }): string;
229
- /**
230
- * Create middleware that enforces secure cookie defaults.
231
- *
232
- * Intercepts Set-Cookie headers and adds missing security attributes:
233
- * - HttpOnly: prevents JavaScript access (XSS cookie theft)
234
- * - Secure: cookies only sent over HTTPS
235
- * - SameSite: CSRF protection
236
- *
237
- * @param options - Cookie security configuration
238
- * @returns Express middleware
239
- *
240
- * @example
241
- * // Enforce defaults on all cookies
242
- * app.use(secureCookieDefaults());
243
- *
244
- * @example
245
- * // Strict SameSite for sensitive apps
246
- * app.use(secureCookieDefaults({ sameSite: 'Strict' }));
247
- */
248
- declare function secureCookieDefaults(options?: SecureCookieOptions): RequestHandler;
249
- /**
250
- * Alias for secureCookieDefaults
251
- * @see secureCookieDefaults
252
- */
253
- declare const createSecureCookies: typeof secureCookieDefaults;
254
-
255
- export { type CorsOptions as C, type SecureCookieOptions as S, arcis as a, arcisWithMethods as b, createCors as c, createErrorHandler as d, createHeaders as e, createRateLimiter as f, createSecureCookies as g, enforceSecureCookie as h, errorHandler as i, secureCookieDefaults as j, securityHeaders as k, rateLimit as r, safeCors as s };