@owlmeans/auth 0.1.18-rc.36 → 0.1.18-rc.37
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/README.md +2 -2
- package/agent-meta/manifest.json +2 -2
- package/agent-meta/skills/auth/SKILL.md +6 -4
- package/build/errors.d.ts +8 -0
- package/build/errors.d.ts.map +1 -1
- package/build/errors.js +8 -0
- package/build/errors.js.map +1 -1
- package/package.json +1 -1
- package/src/errors.ts +9 -1
- package/tests/errors.spec.ts +19 -0
package/README.md
CHANGED
|
@@ -14,7 +14,7 @@ shared auth protocols and organization-entity resolution (`entityKeyOf`, `requir
|
|
|
14
14
|
## Installation
|
|
15
15
|
|
|
16
16
|
```bash
|
|
17
|
-
bun add @owlmeans/auth@^0.1.18-rc.
|
|
17
|
+
bun add @owlmeans/auth@^0.1.18-rc.37
|
|
18
18
|
```
|
|
19
19
|
|
|
20
20
|
`ajv` is a **peer** dependency — install it alongside, or `verifyAuth` / `verifyAuthCredentials`
|
|
@@ -330,7 +330,7 @@ This package ships embedded agent skills under `agent-meta/`. After installing y
|
|
|
330
330
|
your project's skill store (`.agents/skills/`):
|
|
331
331
|
|
|
332
332
|
```sh
|
|
333
|
-
npx @owlmeans/agent-skills@^0.1.18-rc.
|
|
333
|
+
npx @owlmeans/agent-skills@^0.1.18-rc.45
|
|
334
334
|
```
|
|
335
335
|
|
|
336
336
|
The embedded files are version-matched to this package release. Do not edit them
|
package/agent-meta/manifest.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 2,
|
|
3
3
|
"package": "@owlmeans/auth",
|
|
4
|
-
"version": "0.1.18-rc.
|
|
5
|
-
"generatedAt": "2026-
|
|
4
|
+
"version": "0.1.18-rc.37",
|
|
5
|
+
"generatedAt": "2026-10-01T23:27:48.720Z",
|
|
6
6
|
"canonicalRepo": "https://github.com/owlmeans/common",
|
|
7
7
|
"entries": [
|
|
8
8
|
{
|
|
@@ -8,7 +8,7 @@ user-invocable: false
|
|
|
8
8
|
# @owlmeans/auth
|
|
9
9
|
|
|
10
10
|
**Layer:** Core
|
|
11
|
-
**Install:** `"@owlmeans/auth": "^0.1.18-rc.
|
|
11
|
+
**Install:** `"@owlmeans/auth": "^0.1.18-rc.37"` in `dependencies`
|
|
12
12
|
|
|
13
13
|
Types, enums, errors and schemas only — no services, no wiring. Every other auth package builds on
|
|
14
14
|
this vocabulary, so a symbol belongs here exactly when both a server and a browser need to agree on
|
|
@@ -58,7 +58,7 @@ it.
|
|
|
58
58
|
|
|
59
59
|
| Error | Raise it when |
|
|
60
60
|
|-------|---------------|
|
|
61
|
-
| `AuthUnknown` | The thing being authenticated is not known at all — an unregistered plugin type, a request whose auth state is missing |
|
|
61
|
+
| `AuthUnknown` | The thing being authenticated is not known at all — an unregistered plugin type, a method a gate refuses, a request whose auth state is missing. Declares `httpStatus = 400`: the caller's request, never a 500 |
|
|
62
62
|
| `AuthManagerError` | The auth manager itself failed |
|
|
63
63
|
| `AuthManagerUnsupported` | The manager cannot serve this request shape |
|
|
64
64
|
| `AuthenFailed` | Authentication was attempted and rejected (bad challenge, bad code, bad signature) |
|
|
@@ -142,8 +142,10 @@ export const list = handlers<Context>().request(projectProtocols.list, async (re
|
|
|
142
142
|
|
|
143
143
|
Rules of thumb:
|
|
144
144
|
|
|
145
|
-
- A gate that decides "not allowed" throws `AuthForbidden
|
|
146
|
-
on
|
|
145
|
+
- A gate that decides "not allowed" throws `AuthForbidden` (403); a handler that finds no identity
|
|
146
|
+
to act on, or a sign-in naming a method nobody serves, throws `AuthUnknown` (400); a failed
|
|
147
|
+
credential check throws `AuthenFailed`. `@owlmeans/server-api` maps the authorization family to
|
|
148
|
+
401/403 before reading a class's declared `httpStatus`, so `AuthUnknown`'s 400 never masks them.
|
|
147
149
|
- Keep ownership rules out of this package. Downstream apps compose `@owlmeans/entrypoint` gates or
|
|
148
150
|
handler-level checks around these types.
|
|
149
151
|
- WebSocket wiring uses `Auth`, `AuthToken` and `AuthenticationStage` to move a token-bearing
|
package/build/errors.d.ts
CHANGED
|
@@ -3,8 +3,16 @@ export declare class AuthError extends ResilientError {
|
|
|
3
3
|
static typeName: string;
|
|
4
4
|
constructor(message?: string);
|
|
5
5
|
}
|
|
6
|
+
/**
|
|
7
|
+
* The request names an authentication method, provider or identity this server does not know — an
|
|
8
|
+
* unregistered plugin type, a sign-in method a gate refuses, a request carrying no organization.
|
|
9
|
+
* That is the caller's request, not a crashed server, so it answers 400 (`httpStatus`, read by
|
|
10
|
+
* `@owlmeans/server-api`). It is outside the authorization family on purpose: a failed credential
|
|
11
|
+
* stays 401 (`AuthorizationError`) and a refused permission 403 (`AuthForbidden`).
|
|
12
|
+
*/
|
|
6
13
|
export declare class AuthUnknown extends AuthError {
|
|
7
14
|
static typeName: string;
|
|
15
|
+
static httpStatus: number;
|
|
8
16
|
constructor(message?: string);
|
|
9
17
|
}
|
|
10
18
|
export declare class AuthManagerError extends AuthError {
|
package/build/errors.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAA;AAEhD,qBAAa,SAAU,SAAQ,cAAc;IAC3C,OAAuB,QAAQ,EAAE,MAAM,CAAc;IAErD,YAAY,OAAO,GAAE,MAAgB,EAEpC;CACF;AAED,qBAAa,WAAY,SAAQ,SAAS;IACxC,OAAuB,QAAQ,EAAE,MAAM,CAAiC;
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAA;AAEhD,qBAAa,SAAU,SAAQ,cAAc;IAC3C,OAAuB,QAAQ,EAAE,MAAM,CAAc;IAErD,YAAY,OAAO,GAAE,MAAgB,EAEpC;CACF;AAED;;;;;;GAMG;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E9D,YAAY,OAAO,GAAE,MAAgB,EAGpC;CACF;AAED,qBAAa,aAAc,SAAQ,kBAAkB;IACnD,OAAuB,QAAQ,EAAE,MAAM,CAA4C;IAEnF,YAAY,OAAO,GAAE,MAAgB,EAGpC;CACF;AAED,qBAAa,YAAa,SAAQ,SAAS;IACzC,OAAuB,QAAQ,EAAE,MAAM,CAAiB;IAExD,YAAY,OAAO,GAAE,MAAgB,EAGpC;CACF;AAED,qBAAa,uBAAwB,SAAQ,YAAY;IACvD,OAAuB,QAAQ,EAAE,MAAM,CAAwC;IAE/E,YAAY,OAAO,GAAE,MAAgB,EAGpC;CACF"}
|
package/build/errors.js
CHANGED
|
@@ -5,8 +5,16 @@ export class AuthError extends ResilientError {
|
|
|
5
5
|
super(AuthError.typeName, `auth:${message}`);
|
|
6
6
|
}
|
|
7
7
|
}
|
|
8
|
+
/**
|
|
9
|
+
* The request names an authentication method, provider or identity this server does not know — an
|
|
10
|
+
* unregistered plugin type, a sign-in method a gate refuses, a request carrying no organization.
|
|
11
|
+
* That is the caller's request, not a crashed server, so it answers 400 (`httpStatus`, read by
|
|
12
|
+
* `@owlmeans/server-api`). It is outside the authorization family on purpose: a failed credential
|
|
13
|
+
* stays 401 (`AuthorizationError`) and a refused permission 403 (`AuthForbidden`).
|
|
14
|
+
*/
|
|
8
15
|
export class AuthUnknown extends AuthError {
|
|
9
16
|
static typeName = `${AuthError.typeName}Unknown`;
|
|
17
|
+
static httpStatus = 400;
|
|
10
18
|
constructor(message = 'error') {
|
|
11
19
|
super(`unknown:${message}`);
|
|
12
20
|
this.type = AuthUnknown.typeName;
|
package/build/errors.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAA;AAEhD,MAAM,OAAO,SAAU,SAAQ,cAAc;IACpC,MAAM,CAAU,QAAQ,GAAW,WAAW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
|
+
* The request names an authentication method, provider or identity this server does not know — an
|
|
14
|
+
* unregistered plugin type, a sign-in method a gate refuses, a request carrying no organization.
|
|
15
|
+
* That is the caller's request, not a crashed server, so it answers 400 (`httpStatus`, read by
|
|
16
|
+
* `@owlmeans/server-api`). It is outside the authorization family on purpose: a failed credential
|
|
17
|
+
* stays 401 (`AuthorizationError`) and a refused permission 403 (`AuthForbidden`).
|
|
18
|
+
*/
|
|
12
19
|
export class AuthUnknown extends AuthError {
|
|
13
20
|
public static override typeName: string = `${AuthError.typeName}Unknown`
|
|
14
|
-
|
|
21
|
+
public static httpStatus = 400
|
|
22
|
+
|
|
15
23
|
constructor(message: string = 'error') {
|
|
16
24
|
super(`unknown:${message}`)
|
|
17
25
|
this.type = AuthUnknown.typeName
|
package/tests/errors.spec.ts
CHANGED
|
@@ -5,6 +5,7 @@ import {
|
|
|
5
5
|
AuthorizationError,
|
|
6
6
|
AuthenFailed,
|
|
7
7
|
AuthenPayloadError,
|
|
8
|
+
AuthUnknown,
|
|
8
9
|
} from '@owlmeans/auth'
|
|
9
10
|
|
|
10
11
|
describe('@owlmeans/auth — error inheritance chain', () => {
|
|
@@ -49,3 +50,21 @@ describe('@owlmeans/auth — error inheritance chain', () => {
|
|
|
49
50
|
expect(thrown).toHaveLength(3)
|
|
50
51
|
})
|
|
51
52
|
})
|
|
53
|
+
|
|
54
|
+
describe('@owlmeans/auth — declared HTTP statuses', () => {
|
|
55
|
+
// An unknown method, provider or identity is the caller's request — never a crashed server (500).
|
|
56
|
+
test('AuthUnknown declares 400 and stays outside the authorization family', () => {
|
|
57
|
+
const err = new AuthUnknown('email-otp')
|
|
58
|
+
expect(AuthUnknown.httpStatus).toBe(400)
|
|
59
|
+
expect((err.constructor as { httpStatus?: unknown }).httpStatus).toBe(400)
|
|
60
|
+
expect(err).toBeInstanceOf(AuthError)
|
|
61
|
+
expect(err).not.toBeInstanceOf(AuthorizationError)
|
|
62
|
+
})
|
|
63
|
+
|
|
64
|
+
// Their 401/403 comes from the family mapping in `@owlmeans/server-api`, never from a declaration.
|
|
65
|
+
test('the authorization family declares no status of its own', () => {
|
|
66
|
+
for (const refusal of [AuthorizationError, AuthForbidden]) {
|
|
67
|
+
expect([refusal.typeName, (refusal as { httpStatus?: unknown }).httpStatus]).toEqual([refusal.typeName, undefined])
|
|
68
|
+
}
|
|
69
|
+
})
|
|
70
|
+
})
|