@happyvertical/smrt-users 0.56.1 → 0.56.2
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 +21 -0
- package/dist/chunks/{TerminalAuthService-qeDjch8C.js → TerminalAuthService-bCA7skXS.js} +72 -5
- package/dist/chunks/TerminalAuthService-bCA7skXS.js.map +1 -0
- package/dist/collections/TenantCollection.d.ts +34 -0
- package/dist/collections/TenantCollection.d.ts.map +1 -1
- package/dist/index.js +4 -4
- package/dist/manifest.json +399 -13
- package/dist/services/PermissionCatalogService.d.ts.map +1 -1
- package/dist/smrt-knowledge.json +641 -4393
- package/dist/sveltekit.js +1 -1
- package/package.json +9 -9
- package/dist/chunks/TerminalAuthService-qeDjch8C.js.map +0 -1
|
@@ -20,6 +20,21 @@ export interface CreateChildTenantOptions {
|
|
|
20
20
|
/** Whether this child cascades permissions to its children. Default: true */
|
|
21
21
|
cascadePermissions?: boolean;
|
|
22
22
|
}
|
|
23
|
+
/** The verified actor supplied to a hierarchy read-scope authorizer. */
|
|
24
|
+
export interface TenantReadScopeAuthorizationContext {
|
|
25
|
+
actorTenantId: string;
|
|
26
|
+
actorUserId: string;
|
|
27
|
+
rootTenantId: string;
|
|
28
|
+
mode: 'catalog' | 'subtree';
|
|
29
|
+
}
|
|
30
|
+
/** Authorization must return exactly `true`; every other result fails closed. */
|
|
31
|
+
export type TenantReadScopeAuthorizer = (context: TenantReadScopeAuthorizationContext) => boolean | Promise<boolean>;
|
|
32
|
+
export interface TenantReadScopeOptions {
|
|
33
|
+
/** Qualified tenant-scoped model identities whose list reads may widen. */
|
|
34
|
+
collections: readonly string[];
|
|
35
|
+
/** Owning service's affirmative permission decision for this scope. */
|
|
36
|
+
authorize: TenantReadScopeAuthorizer;
|
|
37
|
+
}
|
|
23
38
|
/**
|
|
24
39
|
* Collection for managing Tenant objects with hierarchical support.
|
|
25
40
|
*
|
|
@@ -65,6 +80,8 @@ export declare class TenantCollection extends SmrtCollection<Tenant> {
|
|
|
65
80
|
* Uses the hierarchyPath for efficient lookup.
|
|
66
81
|
*/
|
|
67
82
|
getAncestors(tenantId: string): Promise<Tenant[]>;
|
|
83
|
+
/** Return ancestor IDs in the model's canonical root-to-parent order. */
|
|
84
|
+
getAncestorIds(tenantId: string): Promise<string[]>;
|
|
68
85
|
/**
|
|
69
86
|
* Get all ancestors in order from root to immediate parent.
|
|
70
87
|
* Reverse of getAncestors.
|
|
@@ -75,6 +92,8 @@ export declare class TenantCollection extends SmrtCollection<Tenant> {
|
|
|
75
92
|
* Uses hierarchyPath prefix matching for efficient lookup.
|
|
76
93
|
*/
|
|
77
94
|
getDescendants(tenantId: string): Promise<Tenant[]>;
|
|
95
|
+
/** Return descendant IDs without reimplementing materialized-path traversal. */
|
|
96
|
+
getDescendantIds(tenantId: string): Promise<string[]>;
|
|
78
97
|
/**
|
|
79
98
|
* Get siblings of a tenant (other tenants with the same parent)
|
|
80
99
|
*/
|
|
@@ -87,6 +106,21 @@ export declare class TenantCollection extends SmrtCollection<Tenant> {
|
|
|
87
106
|
* Check if a tenant is a descendant of another tenant
|
|
88
107
|
*/
|
|
89
108
|
isDescendantOf(potentialDescendantId: string, tenantId: string): Promise<boolean>;
|
|
109
|
+
/** Require `childId` to sit below `parentId`, failing closed otherwise. */
|
|
110
|
+
requireChildOf(parentId: string, childId: string): Promise<void>;
|
|
111
|
+
/**
|
|
112
|
+
* Allow list reads for the active family's catalog rows, its ancestors, and
|
|
113
|
+
* global rows. This never includes descendants or siblings.
|
|
114
|
+
*/
|
|
115
|
+
withTenantCatalogReadScope<T>(options: TenantReadScopeOptions, callback: () => Promise<T>): Promise<T>;
|
|
116
|
+
/**
|
|
117
|
+
* Allow list reads for one authorized root and its descendants. Global and
|
|
118
|
+
* ancestor rows remain unavailable so aggregate views cannot become catalog
|
|
119
|
+
* lookups by accident.
|
|
120
|
+
*/
|
|
121
|
+
withTenantHierarchyContext<T>(rootTenantId: string, options: TenantReadScopeOptions, callback: () => Promise<T>): Promise<T>;
|
|
122
|
+
private requireReadScopeActor;
|
|
123
|
+
private runAuthorizedReadScope;
|
|
90
124
|
/**
|
|
91
125
|
* Create a child tenant under a parent.
|
|
92
126
|
* `hierarchyLevel` and `hierarchyPath` are derived by {@link Tenant.save}.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TenantCollection.d.ts","sourceRoot":"","sources":["../../src/collections/TenantCollection.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"TenantCollection.d.ts","sourceRoot":"","sources":["../../src/collections/TenantCollection.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAK1D,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD,OAAO,EAAE,oBAAoB,EAAE,CAAC;AAEhC;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,YAAY,CAAC;IACtB,sEAAsE;IACtE,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,6EAA6E;IAC7E,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B;AAED,wEAAwE;AACxE,MAAM,WAAW,mCAAmC;IAClD,aAAa,EAAE,MAAM,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;IACrB,IAAI,EAAE,SAAS,GAAG,SAAS,CAAC;CAC7B;AAED,iFAAiF;AACjF,MAAM,MAAM,yBAAyB,GAAG,CACtC,OAAO,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Y,CAAC,EAAE,MAAM,GACpB,OAAO,CAAC,KAAK,CAAC,MAAM,GAAG;QAAE,QAAQ,EAAE,MAAM,EAAE,CAAA;KAAE,CAAC,CAAC;CAyBnD"}
|
package/dist/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { $ as PermissionResolver, $t as GroupCollection, A as withSessionPermissionContext, At as recordTenantHierarchyChanges, B as resolveOidcProviderConfig, Bt as RoleCollection, C as OperationPermissionError, Ct as TenantCollection, D as getCurrentSessionPermissionContext, Dt as applyTenantHierarchyUpdates, E as hasOperationPermission, Et as TenantHierarchyError, F as OidcLoginError, Ft as deriveOperationPermissionSlug, G as DeviceCredentialForbiddenError, Gt as UsersPasswordCredential, H as DEFAULT_DEVICE_PERSON_IDLE_SECONDS, Ht as UsersPinCredential, I as OidcLoginService, It as normalizeOperationPermissionAction, J as PIN_LOGIN_KIND, Jt as MembershipCollection, K as DeviceCredentialPolicyError, Kt as MembershipOverrideCollection, L as decodeOidcTransaction, Lt as registerPermissionDefinitions, M as MobileAuthService, Mt as RolePermissionCollection, N as readMobileBearerToken, Nt as PermissionCatalogService, O as getRequestScopedDatabase, Ot as assertTenantTableName, P as validateMobileRedirectUri, Pt as deriveOperationPermissionCollectionName, Q as SessionService, Qt as GroupMember, R as encodeOidcTransaction, Rt as syncPermissionCatalog, S as outOfBandProofSessionData, St as TenantPermissionOverride, T as checkOperationPermission, Tt as MAX_TENANT_HIERARCHY_DEPTH, U as DEFAULT_PIN_MANAGE_PERMISSION, Ut as PermissionCollection, Vt as UsersPinCredentialCollection, W as DeviceCredentialError, Wt as UsersPasswordCredentialCollection, X as PinVerifier, Xt as GroupRole, Y as PIN_PERMISSION_DEFINITIONS, Yt as GroupRoleCollection, Z as ensurePinPermissionsRegistered, Zt as GroupMemberCollection, _ as PasswordCredentialError, _n as Membership, _t as UserCollection, a as TerminalAuthError, an as UsersCliAuthRequestCollection, at as DEFAULT_SOURCE_LOCKOUT_AUDIT_SECONDS, b as PasswordPolicyError, bt as backfillUserEmailKeys, c as DEFAULT_PASSWORD_DENYLIST, cn as User, ct as LoginAttemptLimiter, d as DEFAULT_PASSWORD_MIN_LENGTH, dn as DEFAULT_SESSION_TTL, dt as ANCESTOR_READ_ACTION, en as Group, et as DEFAULT_LOGIN_ATTEMPT_WINDOW_SECONDS, f as DEFAULT_PASSWORD_RECOVERY_MAX_AGE_SECONDS, fn as SESSION_DATA_KEYS, ft as DEFAULT_ANCESTOR_READ_MAX_DEPTH, g as PASSWORD_RECOVERY_MAX_AGE_CEILING_SECONDS, gn as Permission, gt as OidcProvisioningError, h as PASSWORD_PERMISSION_DEFINITIONS, hn as Role, ht as normalizeAncestorReadPolicy, i as TERMINAL_APPROVE_LOGIN_KIND, in as UsersLoginAttempt, it as DEFAULT_LOGIN_MAX_ATTEMPTS, j as MobileAuthError, jt as DEFAULT_ROLE_PERMISSION_PATTERNS, k as withPrincipalPermissionContext, kt as planTenantHierarchy, l as DEFAULT_PASSWORD_MANAGE_PERMISSION, ln as isValidEmail, lt as LoginRateLimitError, m as PASSWORD_MAX_LENGTH_CEILING, mn as generateSessionId, mt as isAncestorReadableSlug, n as DEFAULT_CLI_AUTH_REQUEST_TTL_SECONDS, nn as UsersLoginAuditEvent, nt as DEFAULT_LOGIN_LOCKOUT_FACTOR, o as TerminalAuthRateLimitError, on as SessionCollection, ot as DurableLoginAuditSink, p as PASSWORD_LOGIN_KIND, pn as Session, pt as getConfiguredAncestorReadPolicy, q as DeviceCredentialService, qt as MembershipOverride, r as DEFAULT_CLI_SESSION_TTL_SECONDS, rn as UsersLoginAttemptCollection, rt as DEFAULT_LOGIN_LOCKOUT_MAX_SECONDS, s as TerminalAuthService, sn as UsersCliAuthRequest, st as InvalidCredentialsError, t as DEFAULT_CLI_AUTH_POLL_INTERVAL_SECONDS, tn as UsersLoginAuditEventCollection, tt as DEFAULT_LOGIN_LOCKOUT_BASE_SECONDS, u as DEFAULT_PASSWORD_MAX_LENGTH, un as normalizeEmail, ut as withoutListBounds, v as PasswordCredentialForbiddenError, w as assertOperationPermission, wt as Tenant, x as ensurePasswordPermissionsRegistered, xt as TenantPermissionOverrideCollection, y as PasswordCredentialService, yt as UserEmailKeyBackfillError, z as getUsersOidcConfig, zt as RolePermission } from "./chunks/TerminalAuthService-
|
|
1
|
+
import { $ as PermissionResolver, $t as GroupCollection, A as withSessionPermissionContext, At as recordTenantHierarchyChanges, B as resolveOidcProviderConfig, Bt as RoleCollection, C as OperationPermissionError, Ct as TenantCollection, D as getCurrentSessionPermissionContext, Dt as applyTenantHierarchyUpdates, E as hasOperationPermission, Et as TenantHierarchyError, F as OidcLoginError, Ft as deriveOperationPermissionSlug, G as DeviceCredentialForbiddenError, Gt as UsersPasswordCredential, H as DEFAULT_DEVICE_PERSON_IDLE_SECONDS, Ht as UsersPinCredential, I as OidcLoginService, It as normalizeOperationPermissionAction, J as PIN_LOGIN_KIND, Jt as MembershipCollection, K as DeviceCredentialPolicyError, Kt as MembershipOverrideCollection, L as decodeOidcTransaction, Lt as registerPermissionDefinitions, M as MobileAuthService, Mt as RolePermissionCollection, N as readMobileBearerToken, Nt as PermissionCatalogService, O as getRequestScopedDatabase, Ot as assertTenantTableName, P as validateMobileRedirectUri, Pt as deriveOperationPermissionCollectionName, Q as SessionService, Qt as GroupMember, R as encodeOidcTransaction, Rt as syncPermissionCatalog, S as outOfBandProofSessionData, St as TenantPermissionOverride, T as checkOperationPermission, Tt as MAX_TENANT_HIERARCHY_DEPTH, U as DEFAULT_PIN_MANAGE_PERMISSION, Ut as PermissionCollection, Vt as UsersPinCredentialCollection, W as DeviceCredentialError, Wt as UsersPasswordCredentialCollection, X as PinVerifier, Xt as GroupRole, Y as PIN_PERMISSION_DEFINITIONS, Yt as GroupRoleCollection, Z as ensurePinPermissionsRegistered, Zt as GroupMemberCollection, _ as PasswordCredentialError, _n as Membership, _t as UserCollection, a as TerminalAuthError, an as UsersCliAuthRequestCollection, at as DEFAULT_SOURCE_LOCKOUT_AUDIT_SECONDS, b as PasswordPolicyError, bt as backfillUserEmailKeys, c as DEFAULT_PASSWORD_DENYLIST, cn as User, ct as LoginAttemptLimiter, d as DEFAULT_PASSWORD_MIN_LENGTH, dn as DEFAULT_SESSION_TTL, dt as ANCESTOR_READ_ACTION, en as Group, et as DEFAULT_LOGIN_ATTEMPT_WINDOW_SECONDS, f as DEFAULT_PASSWORD_RECOVERY_MAX_AGE_SECONDS, fn as SESSION_DATA_KEYS, ft as DEFAULT_ANCESTOR_READ_MAX_DEPTH, g as PASSWORD_RECOVERY_MAX_AGE_CEILING_SECONDS, gn as Permission, gt as OidcProvisioningError, h as PASSWORD_PERMISSION_DEFINITIONS, hn as Role, ht as normalizeAncestorReadPolicy, i as TERMINAL_APPROVE_LOGIN_KIND, in as UsersLoginAttempt, it as DEFAULT_LOGIN_MAX_ATTEMPTS, j as MobileAuthError, jt as DEFAULT_ROLE_PERMISSION_PATTERNS, k as withPrincipalPermissionContext, kt as planTenantHierarchy, l as DEFAULT_PASSWORD_MANAGE_PERMISSION, ln as isValidEmail, lt as LoginRateLimitError, m as PASSWORD_MAX_LENGTH_CEILING, mn as generateSessionId, mt as isAncestorReadableSlug, n as DEFAULT_CLI_AUTH_REQUEST_TTL_SECONDS, nn as UsersLoginAuditEvent, nt as DEFAULT_LOGIN_LOCKOUT_FACTOR, o as TerminalAuthRateLimitError, on as SessionCollection, ot as DurableLoginAuditSink, p as PASSWORD_LOGIN_KIND, pn as Session, pt as getConfiguredAncestorReadPolicy, q as DeviceCredentialService, qt as MembershipOverride, r as DEFAULT_CLI_SESSION_TTL_SECONDS, rn as UsersLoginAttemptCollection, rt as DEFAULT_LOGIN_LOCKOUT_MAX_SECONDS, s as TerminalAuthService, sn as UsersCliAuthRequest, st as InvalidCredentialsError, t as DEFAULT_CLI_AUTH_POLL_INTERVAL_SECONDS, tn as UsersLoginAuditEventCollection, tt as DEFAULT_LOGIN_LOCKOUT_BASE_SECONDS, u as DEFAULT_PASSWORD_MAX_LENGTH, un as normalizeEmail, ut as withoutListBounds, v as PasswordCredentialForbiddenError, w as assertOperationPermission, wt as Tenant, x as ensurePasswordPermissionsRegistered, xt as TenantPermissionOverrideCollection, y as PasswordCredentialService, yt as UserEmailKeyBackfillError, z as getUsersOidcConfig, zt as RolePermission } from "./chunks/TerminalAuthService-bCA7skXS.js";
|
|
2
2
|
import { a as MembershipStatus, c as TenantPermissionEffect, i as DEFAULT_TENANT_POLICY, l as TenantStatus, n as DEFAULT_ROLES, o as OverrideEffect, r as DEFAULT_ROLE_SLUGS, s as SessionStatus, t as AccessRequestStatus, u as UserStatus } from "./chunks/types-DFqeph0R.js";
|
|
3
3
|
import { ObjectRegistry, SmrtCollection, SmrtObject, SmrtRecipe, bumpChangeFeed, ensureChangeFeedTable, field, findManifestEntryByQualifiedName, foreignKey, isEmbeddedDatabase, isUniqueViolationError, registerRetentionTask, smrt, unregisterRetentionTask, withEmbeddedWriteTransaction } from "@happyvertical/smrt-core";
|
|
4
4
|
import { PROFILE_EMAIL_KEY_BACKFILL_NAME, Person, ProfileCollection, ProfileTypeCollection, normalizeIdentityEmail } from "@happyvertical/smrt-profiles";
|
|
5
5
|
import { createHash, randomUUID } from "node:crypto";
|
|
6
6
|
import { setTimeout } from "node:timers/promises";
|
|
7
|
-
import { createLogger } from "@happyvertical/logger";
|
|
8
7
|
import { TenantScoped, tenantId, withSystemContext } from "@happyvertical/smrt-tenancy";
|
|
8
|
+
import { createLogger } from "@happyvertical/logger";
|
|
9
9
|
import { BackfillTracker } from "@happyvertical/smrt-core/migrations";
|
|
10
10
|
import { OAuthServerError } from "@happyvertical/auth/server";
|
|
11
11
|
//#region src/models/ResourceGrant.ts
|
|
@@ -1948,7 +1948,7 @@ var MagicLinkService = class MagicLinkService {
|
|
|
1948
1948
|
* The caller is responsible for emailing the token to the user.
|
|
1949
1949
|
*/
|
|
1950
1950
|
async generate(email) {
|
|
1951
|
-
const { SignJWT } = await import("./chunks/TerminalAuthService-
|
|
1951
|
+
const { SignJWT } = await import("./chunks/TerminalAuthService-bCA7skXS.js").then((n) => n.V);
|
|
1952
1952
|
const key = await this.getSigningKey();
|
|
1953
1953
|
const nonce = crypto.randomUUID();
|
|
1954
1954
|
const normalizedEmail = normalizeEmail(email);
|
|
@@ -1977,7 +1977,7 @@ var MagicLinkService = class MagicLinkService {
|
|
|
1977
1977
|
* @throws {MagicLinkError} If the token is invalid, expired, or already used
|
|
1978
1978
|
*/
|
|
1979
1979
|
async verify(token) {
|
|
1980
|
-
const { jwtVerify, errors } = await import("./chunks/TerminalAuthService-
|
|
1980
|
+
const { jwtVerify, errors } = await import("./chunks/TerminalAuthService-bCA7skXS.js").then((n) => n.V);
|
|
1981
1981
|
const key = await this.getSigningKey();
|
|
1982
1982
|
let payload;
|
|
1983
1983
|
try {
|