@robinpath/auth 0.1.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.
package/dist/auth.d.ts ADDED
@@ -0,0 +1,165 @@
1
+ import type { BuiltinHandler } from "@wiredwp/robinpath";
2
+ export declare const AuthFunctions: Record<string, BuiltinHandler>;
3
+ export declare const AuthFunctionMetadata: {
4
+ basic: {
5
+ description: string;
6
+ parameters: {
7
+ name: string;
8
+ dataType: string;
9
+ description: string;
10
+ formInputType: string;
11
+ required: boolean;
12
+ }[];
13
+ returnType: string;
14
+ returnDescription: string;
15
+ example: string;
16
+ };
17
+ parseBasic: {
18
+ description: string;
19
+ parameters: {
20
+ name: string;
21
+ dataType: string;
22
+ description: string;
23
+ formInputType: string;
24
+ required: boolean;
25
+ }[];
26
+ returnType: string;
27
+ returnDescription: string;
28
+ example: string;
29
+ };
30
+ bearer: {
31
+ description: string;
32
+ parameters: {
33
+ name: string;
34
+ dataType: string;
35
+ description: string;
36
+ formInputType: string;
37
+ required: boolean;
38
+ }[];
39
+ returnType: string;
40
+ returnDescription: string;
41
+ example: string;
42
+ };
43
+ parseBearer: {
44
+ description: string;
45
+ parameters: {
46
+ name: string;
47
+ dataType: string;
48
+ description: string;
49
+ formInputType: string;
50
+ required: boolean;
51
+ }[];
52
+ returnType: string;
53
+ returnDescription: string;
54
+ example: string;
55
+ };
56
+ apiKey: {
57
+ description: string;
58
+ parameters: {
59
+ name: string;
60
+ dataType: string;
61
+ description: string;
62
+ formInputType: string;
63
+ required: boolean;
64
+ }[];
65
+ returnType: string;
66
+ returnDescription: string;
67
+ example: string;
68
+ };
69
+ hmacSign: {
70
+ description: string;
71
+ parameters: {
72
+ name: string;
73
+ dataType: string;
74
+ description: string;
75
+ formInputType: string;
76
+ required: boolean;
77
+ }[];
78
+ returnType: string;
79
+ returnDescription: string;
80
+ example: string;
81
+ };
82
+ hmacVerify: {
83
+ description: string;
84
+ parameters: {
85
+ name: string;
86
+ dataType: string;
87
+ description: string;
88
+ formInputType: string;
89
+ required: boolean;
90
+ }[];
91
+ returnType: string;
92
+ returnDescription: string;
93
+ example: string;
94
+ };
95
+ generateApiKey: {
96
+ description: string;
97
+ parameters: {
98
+ name: string;
99
+ dataType: string;
100
+ description: string;
101
+ formInputType: string;
102
+ required: boolean;
103
+ }[];
104
+ returnType: string;
105
+ returnDescription: string;
106
+ example: string;
107
+ };
108
+ hashPassword: {
109
+ description: string;
110
+ parameters: {
111
+ name: string;
112
+ dataType: string;
113
+ description: string;
114
+ formInputType: string;
115
+ required: boolean;
116
+ }[];
117
+ returnType: string;
118
+ returnDescription: string;
119
+ example: string;
120
+ };
121
+ verifyPassword: {
122
+ description: string;
123
+ parameters: {
124
+ name: string;
125
+ dataType: string;
126
+ description: string;
127
+ formInputType: string;
128
+ required: boolean;
129
+ }[];
130
+ returnType: string;
131
+ returnDescription: string;
132
+ example: string;
133
+ };
134
+ buildAuthHeader: {
135
+ description: string;
136
+ parameters: {
137
+ name: string;
138
+ dataType: string;
139
+ description: string;
140
+ formInputType: string;
141
+ required: boolean;
142
+ }[];
143
+ returnType: string;
144
+ returnDescription: string;
145
+ example: string;
146
+ };
147
+ parseAuthHeader: {
148
+ description: string;
149
+ parameters: {
150
+ name: string;
151
+ dataType: string;
152
+ description: string;
153
+ formInputType: string;
154
+ required: boolean;
155
+ }[];
156
+ returnType: string;
157
+ returnDescription: string;
158
+ example: string;
159
+ };
160
+ };
161
+ export declare const AuthModuleMetadata: {
162
+ description: string;
163
+ methods: string[];
164
+ };
165
+ //# sourceMappingURL=auth.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../src/auth.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAA2C,MAAM,oBAAoB,CAAC;AA8KlG,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,cAAc,CAaxD,CAAC;AAEF,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyHhC,CAAC;AAEF,eAAO,MAAM,kBAAkB;;;CAG9B,CAAC"}
package/dist/auth.js ADDED
@@ -0,0 +1,298 @@
1
+ import { createHmac, timingSafeEqual, randomBytes } from "node:crypto";
2
+ // ── Function Handlers ───────────────────────────────────────────────
3
+ const basic = (args) => {
4
+ const username = String(args[0] ?? "");
5
+ const password = String(args[1] ?? "");
6
+ const encoded = Buffer.from(`${username}:${password}`).toString("base64");
7
+ return `Basic ${encoded}`;
8
+ };
9
+ const parseBasic = (args) => {
10
+ const header = String(args[0] ?? "");
11
+ const match = header.match(/^Basic\s+(.+)$/i);
12
+ if (!match)
13
+ throw new Error("Invalid Basic auth header");
14
+ const decoded = Buffer.from(match[1], "base64").toString("utf-8");
15
+ const colonIndex = decoded.indexOf(":");
16
+ if (colonIndex === -1)
17
+ throw new Error("Invalid Basic auth credentials");
18
+ return {
19
+ username: decoded.substring(0, colonIndex),
20
+ password: decoded.substring(colonIndex + 1),
21
+ };
22
+ };
23
+ const bearer = (args) => {
24
+ const token = String(args[0] ?? "");
25
+ return `Bearer ${token}`;
26
+ };
27
+ const parseBearer = (args) => {
28
+ const header = String(args[0] ?? "");
29
+ const match = header.match(/^Bearer\s+(.+)$/i);
30
+ if (!match)
31
+ throw new Error("Invalid Bearer auth header");
32
+ return match[1];
33
+ };
34
+ const apiKey = (args) => {
35
+ const key = String(args[0] ?? "");
36
+ const placement = String(args[1] ?? "header");
37
+ const name = String(args[2] ?? "X-API-Key");
38
+ if (placement === "header") {
39
+ return { type: "header", name, value: key };
40
+ }
41
+ if (placement === "query") {
42
+ return { type: "query", name, value: key };
43
+ }
44
+ throw new Error(`Invalid placement: "${placement}". Use "header" or "query".`);
45
+ };
46
+ const hmacSign = (args) => {
47
+ const payload = String(args[0] ?? "");
48
+ const secret = String(args[1] ?? "");
49
+ const algorithm = String(args[2] ?? "sha256");
50
+ const signature = createHmac(algorithm, secret).update(payload).digest("hex");
51
+ return signature;
52
+ };
53
+ const hmacVerify = (args) => {
54
+ const payload = String(args[0] ?? "");
55
+ const secret = String(args[1] ?? "");
56
+ const signature = String(args[2] ?? "");
57
+ const algorithm = String(args[3] ?? "sha256");
58
+ const expected = createHmac(algorithm, secret).update(payload).digest("hex");
59
+ // Use timing-safe comparison to prevent timing attacks
60
+ if (expected.length !== signature.length)
61
+ return false;
62
+ try {
63
+ return timingSafeEqual(Buffer.from(expected, "hex"), Buffer.from(signature, "hex"));
64
+ }
65
+ catch {
66
+ return false;
67
+ }
68
+ };
69
+ const generateApiKey = (args) => {
70
+ const length = parseInt(String(args[0] ?? "32"), 10);
71
+ const prefix = args[1] != null ? String(args[1]) : "";
72
+ const key = randomBytes(length).toString("hex");
73
+ return prefix ? `${prefix}_${key}` : key;
74
+ };
75
+ const hashPassword = async (args) => {
76
+ const password = String(args[0] ?? "");
77
+ const salt = randomBytes(16).toString("hex");
78
+ const iterations = parseInt(String(args[1] ?? "100000"), 10);
79
+ // Use PBKDF2 via crypto
80
+ const { pbkdf2 } = await import("node:crypto");
81
+ return new Promise((resolve, reject) => {
82
+ pbkdf2(password, salt, iterations, 64, "sha512", (err, derivedKey) => {
83
+ if (err)
84
+ reject(err);
85
+ else
86
+ resolve(`${salt}:${iterations}:${derivedKey.toString("hex")}`);
87
+ });
88
+ });
89
+ };
90
+ const verifyPassword = async (args) => {
91
+ const password = String(args[0] ?? "");
92
+ const hash = String(args[1] ?? "");
93
+ const parts = hash.split(":");
94
+ if (parts.length !== 3)
95
+ throw new Error("Invalid hash format. Expected salt:iterations:hash");
96
+ const [salt, iterStr, storedHash] = parts;
97
+ const iterations = parseInt(iterStr, 10);
98
+ const { pbkdf2 } = await import("node:crypto");
99
+ return new Promise((resolve, reject) => {
100
+ pbkdf2(password, salt, iterations, 64, "sha512", (err, derivedKey) => {
101
+ if (err)
102
+ reject(err);
103
+ else {
104
+ const derived = derivedKey.toString("hex");
105
+ try {
106
+ resolve(timingSafeEqual(Buffer.from(derived), Buffer.from(storedHash)));
107
+ }
108
+ catch {
109
+ resolve(false);
110
+ }
111
+ }
112
+ });
113
+ });
114
+ };
115
+ const buildAuthHeader = (args) => {
116
+ const type = String(args[0] ?? "").toLowerCase();
117
+ const value = args[1];
118
+ switch (type) {
119
+ case "basic": {
120
+ const creds = value;
121
+ if (typeof creds === "string")
122
+ return `Basic ${Buffer.from(creds).toString("base64")}`;
123
+ return `Basic ${Buffer.from(`${creds.username ?? ""}:${creds.password ?? ""}`).toString("base64")}`;
124
+ }
125
+ case "bearer":
126
+ return `Bearer ${String(value ?? "")}`;
127
+ case "apikey":
128
+ case "api-key":
129
+ return String(value ?? "");
130
+ default:
131
+ return `${type} ${String(value ?? "")}`;
132
+ }
133
+ };
134
+ const parseAuthHeader = (args) => {
135
+ const header = String(args[0] ?? "");
136
+ const spaceIndex = header.indexOf(" ");
137
+ if (spaceIndex === -1)
138
+ return { scheme: header.toLowerCase(), credentials: "" };
139
+ const scheme = header.substring(0, spaceIndex).toLowerCase();
140
+ const credentials = header.substring(spaceIndex + 1);
141
+ if (scheme === "basic") {
142
+ try {
143
+ const decoded = Buffer.from(credentials, "base64").toString("utf-8");
144
+ const colonIndex = decoded.indexOf(":");
145
+ return {
146
+ scheme,
147
+ username: colonIndex >= 0 ? decoded.substring(0, colonIndex) : decoded,
148
+ password: colonIndex >= 0 ? decoded.substring(colonIndex + 1) : "",
149
+ };
150
+ }
151
+ catch {
152
+ return { scheme, credentials };
153
+ }
154
+ }
155
+ return { scheme, token: credentials };
156
+ };
157
+ // ── Exports ─────────────────────────────────────────────────────────
158
+ export const AuthFunctions = {
159
+ basic,
160
+ parseBasic,
161
+ bearer,
162
+ parseBearer,
163
+ apiKey,
164
+ hmacSign,
165
+ hmacVerify,
166
+ generateApiKey,
167
+ hashPassword,
168
+ verifyPassword,
169
+ buildAuthHeader,
170
+ parseAuthHeader,
171
+ };
172
+ export const AuthFunctionMetadata = {
173
+ basic: {
174
+ description: "Create a Basic authentication header from username and password",
175
+ parameters: [
176
+ { name: "username", dataType: "string", description: "Username", formInputType: "text", required: true },
177
+ { name: "password", dataType: "string", description: "Password", formInputType: "text", required: true },
178
+ ],
179
+ returnType: "string",
180
+ returnDescription: "Basic auth header string (e.g. 'Basic dXNlcjpwYXNz')",
181
+ example: 'auth.basic "user" "pass"',
182
+ },
183
+ parseBasic: {
184
+ description: "Parse a Basic auth header to extract username and password",
185
+ parameters: [
186
+ { name: "header", dataType: "string", description: "The Authorization header value", formInputType: "text", required: true },
187
+ ],
188
+ returnType: "object",
189
+ returnDescription: "{username, password}",
190
+ example: 'auth.parseBasic "Basic dXNlcjpwYXNz"',
191
+ },
192
+ bearer: {
193
+ description: "Create a Bearer authentication header from a token",
194
+ parameters: [
195
+ { name: "token", dataType: "string", description: "The bearer token", formInputType: "text", required: true },
196
+ ],
197
+ returnType: "string",
198
+ returnDescription: "Bearer auth header string",
199
+ example: 'auth.bearer "eyJhbGciOi..."',
200
+ },
201
+ parseBearer: {
202
+ description: "Extract the token from a Bearer auth header",
203
+ parameters: [
204
+ { name: "header", dataType: "string", description: "The Authorization header value", formInputType: "text", required: true },
205
+ ],
206
+ returnType: "string",
207
+ returnDescription: "The extracted token string",
208
+ example: 'auth.parseBearer "Bearer eyJhbGciOi..."',
209
+ },
210
+ apiKey: {
211
+ description: "Create an API key configuration for header or query parameter placement",
212
+ parameters: [
213
+ { name: "key", dataType: "string", description: "The API key value", formInputType: "text", required: true },
214
+ { name: "placement", dataType: "string", description: "'header' or 'query' (default: header)", formInputType: "text", required: false },
215
+ { name: "name", dataType: "string", description: "Header or query param name (default: X-API-Key)", formInputType: "text", required: false },
216
+ ],
217
+ returnType: "object",
218
+ returnDescription: "{type, name, value} object for use in HTTP requests",
219
+ example: 'auth.apiKey "sk-abc123" "header" "Authorization"',
220
+ },
221
+ hmacSign: {
222
+ description: "Create an HMAC signature for a payload",
223
+ parameters: [
224
+ { name: "payload", dataType: "string", description: "The payload to sign", formInputType: "text", required: true },
225
+ { name: "secret", dataType: "string", description: "The secret key", formInputType: "text", required: true },
226
+ { name: "algorithm", dataType: "string", description: "Hash algorithm (default: sha256)", formInputType: "text", required: false },
227
+ ],
228
+ returnType: "string",
229
+ returnDescription: "Hex-encoded HMAC signature",
230
+ example: 'auth.hmacSign "payload" "secret" "sha256"',
231
+ },
232
+ hmacVerify: {
233
+ description: "Verify an HMAC signature using timing-safe comparison",
234
+ parameters: [
235
+ { name: "payload", dataType: "string", description: "The original payload", formInputType: "text", required: true },
236
+ { name: "secret", dataType: "string", description: "The secret key", formInputType: "text", required: true },
237
+ { name: "signature", dataType: "string", description: "The hex signature to verify", formInputType: "text", required: true },
238
+ { name: "algorithm", dataType: "string", description: "Hash algorithm (default: sha256)", formInputType: "text", required: false },
239
+ ],
240
+ returnType: "boolean",
241
+ returnDescription: "True if the signature is valid",
242
+ example: 'auth.hmacVerify "payload" "secret" "abc123def..."',
243
+ },
244
+ generateApiKey: {
245
+ description: "Generate a cryptographically secure random API key",
246
+ parameters: [
247
+ { name: "length", dataType: "number", description: "Key length in bytes (default 32)", formInputType: "text", required: false },
248
+ { name: "prefix", dataType: "string", description: "Optional prefix (e.g. 'sk', 'pk')", formInputType: "text", required: false },
249
+ ],
250
+ returnType: "string",
251
+ returnDescription: "Random hex API key, optionally prefixed",
252
+ example: 'auth.generateApiKey 32 "sk"',
253
+ },
254
+ hashPassword: {
255
+ description: "Hash a password using PBKDF2 with a random salt",
256
+ parameters: [
257
+ { name: "password", dataType: "string", description: "The password to hash", formInputType: "text", required: true },
258
+ { name: "iterations", dataType: "number", description: "PBKDF2 iterations (default 100000)", formInputType: "text", required: false },
259
+ ],
260
+ returnType: "string",
261
+ returnDescription: "Hash string in format salt:iterations:hash",
262
+ example: 'auth.hashPassword "my-secret-password"',
263
+ },
264
+ verifyPassword: {
265
+ description: "Verify a password against a PBKDF2 hash (timing-safe)",
266
+ parameters: [
267
+ { name: "password", dataType: "string", description: "The password to verify", formInputType: "text", required: true },
268
+ { name: "hash", dataType: "string", description: "The stored hash (salt:iterations:hash)", formInputType: "text", required: true },
269
+ ],
270
+ returnType: "boolean",
271
+ returnDescription: "True if the password matches the hash",
272
+ example: 'auth.verifyPassword "my-secret-password" $storedHash',
273
+ },
274
+ buildAuthHeader: {
275
+ description: "Build an Authorization header from a type and credentials",
276
+ parameters: [
277
+ { name: "type", dataType: "string", description: "Auth type: basic, bearer, apikey", formInputType: "text", required: true },
278
+ { name: "value", dataType: "any", description: "Token string or {username, password} for basic", formInputType: "text", required: true },
279
+ ],
280
+ returnType: "string",
281
+ returnDescription: "Complete Authorization header value",
282
+ example: 'auth.buildAuthHeader "bearer" $token',
283
+ },
284
+ parseAuthHeader: {
285
+ description: "Parse any Authorization header into its scheme and credentials",
286
+ parameters: [
287
+ { name: "header", dataType: "string", description: "The Authorization header value", formInputType: "text", required: true },
288
+ ],
289
+ returnType: "object",
290
+ returnDescription: "Object with scheme and decoded credentials",
291
+ example: 'auth.parseAuthHeader $header',
292
+ },
293
+ };
294
+ export const AuthModuleMetadata = {
295
+ description: "API authentication helpers: Basic, Bearer, API key, HMAC signing, and password hashing",
296
+ methods: ["basic", "parseBasic", "bearer", "parseBearer", "apiKey", "hmacSign", "hmacVerify", "generateApiKey", "hashPassword", "verifyPassword", "buildAuthHeader", "parseAuthHeader"],
297
+ };
298
+ //# sourceMappingURL=auth.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"auth.js","sourceRoot":"","sources":["../src/auth.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAEvE,uEAAuE;AAEvE,MAAM,KAAK,GAAmB,CAAC,IAAI,EAAE,EAAE;IACrC,MAAM,QAAQ,GAAG,MAAM,CAA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C,EAAE,aAAa,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE;SAC7H;QACD,UAAU,EAAE,QAAQ;QACpB,iBAAiB,EAAE,4CAA4C;QAC/D,OAAO,EAAE,8BAA8B;KACxC;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,WAAW,EAAE,wFAAwF;IACrG,OAAO,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,aAAa,EAAE,QAAQ,EAAE,UAAU,EAAE,YAAY,EAAE,gBAAgB,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,iBAAiB,CAAC;CACxL,CAAC"}
@@ -0,0 +1,6 @@
1
+ import type { ModuleAdapter } from "@wiredwp/robinpath";
2
+ declare const AuthModule: ModuleAdapter;
3
+ export default AuthModule;
4
+ export { AuthModule };
5
+ export { AuthFunctions, AuthFunctionMetadata, AuthModuleMetadata } from "./auth.js";
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAGxD,QAAA,MAAM,UAAU,EAAE,aAMjB,CAAC;AAEF,eAAe,UAAU,CAAC;AAC1B,OAAO,EAAE,UAAU,EAAE,CAAC;AACtB,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,12 @@
1
+ import { AuthFunctions, AuthFunctionMetadata, AuthModuleMetadata } from "./auth.js";
2
+ const AuthModule = {
3
+ name: "auth",
4
+ functions: AuthFunctions,
5
+ functionMetadata: AuthFunctionMetadata,
6
+ moduleMetadata: AuthModuleMetadata,
7
+ global: false,
8
+ }; // as ModuleAdapter
9
+ export default AuthModule;
10
+ export { AuthModule };
11
+ export { AuthFunctions, AuthFunctionMetadata, AuthModuleMetadata } from "./auth.js";
12
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAEpF,MAAM,UAAU,GAAkB;IAChC,IAAI,EAAE,MAAM;IACZ,SAAS,EAAE,aAAa;IACxB,gBAAgB,EAAE,oBAA2B;IAC7C,cAAc,EAAE,kBAAyB;IACzC,MAAM,EAAE,KAAK;CACd,CAAC,CAAC,mBAAmB;AAEtB,eAAe,UAAU,CAAC;AAC1B,OAAO,EAAE,UAAU,EAAE,CAAC;AACtB,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC"}
package/package.json ADDED
@@ -0,0 +1,14 @@
1
+ {
2
+ "name": "@robinpath/auth",
3
+ "version": "0.1.0",
4
+ "description": "API authentication helpers (Basic, Bearer, API key, HMAC) for RobinPath",
5
+ "publishConfig": { "access": "public" },
6
+ "type": "module",
7
+ "main": "dist/index.js",
8
+ "types": "dist/index.d.ts",
9
+ "exports": { ".": { "import": "./dist/index.js", "types": "./dist/index.d.ts" } },
10
+ "files": ["dist"],
11
+ "scripts": { "build": "tsc", "test": "node --import tsx --test tests/*.test.ts" },
12
+ "peerDependencies": { "@wiredwp/robinpath": ">=0.20.0" },
13
+ "devDependencies": { "@wiredwp/robinpath": "^0.30.1", "tsx": "^4.19.0", "typescript": "^5.6.0" }
14
+ }