@vess-id/ai-identity 0.14.0-alpha.0 → 0.14.0-alpha.1
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/index.d.mts +23 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +40 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +38 -0
- package/dist/index.mjs.map +1 -1
- package/dist/types/permission-vc.d.ts +9 -0
- package/dist/types/permission-vc.d.ts.map +1 -1
- package/dist/utils/freemail-domains.d.ts +13 -0
- package/dist/utils/freemail-domains.d.ts.map +1 -0
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -966,6 +966,15 @@ interface PermissionRule {
|
|
|
966
966
|
* 2+ will bump the schema to v3.1 and make it required.
|
|
967
967
|
*/
|
|
968
968
|
policy_ref?: PolicyRef;
|
|
969
|
+
/**
|
|
970
|
+
* Cedar policy bindings (複数) — 1 つの委任スコープに複数の policy が AND/OR
|
|
971
|
+
* で適用されるケース (例: calendarDomain 宛先制約 + timeWindow forbid)。
|
|
972
|
+
* 後方互換のため単数 `policy_ref` は維持し、発行時は `policy_refs[0]` を
|
|
973
|
+
* ミラーする。読み手は policy_refs を優先し、無ければ policy_ref を単要素配列に
|
|
974
|
+
* 正規化する。Cedar 評価では全 ref を 1 つの PolicySet に集約 (permit=OR,
|
|
975
|
+
* forbid=override で AND)。
|
|
976
|
+
*/
|
|
977
|
+
policy_refs?: PolicyRef[];
|
|
969
978
|
}
|
|
970
979
|
/**
|
|
971
980
|
* Permission VC Claims v2 — the pre-Cedar canonical credential claims format.
|
|
@@ -9419,6 +9428,19 @@ declare function resolveUserTier(tier: string | undefined | null): UserTier;
|
|
|
9419
9428
|
*/
|
|
9420
9429
|
declare function getTierLimits(tier: string | undefined | null): TierLimits;
|
|
9421
9430
|
|
|
9431
|
+
/**
|
|
9432
|
+
* フリーメール / コンシューマ向けメールドメインのリスト。
|
|
9433
|
+
* grant の internalDomains で「ドメイン全体ワイルドカード (*@<freemail>)」を
|
|
9434
|
+
* 許可することを禁止するために使う (個別アドレス x@gmail.com は許可)。
|
|
9435
|
+
* 理由: *@gmail.com を「社内ドメイン」として自動許可すると、全 Gmail ユーザー
|
|
9436
|
+
* 宛が無条件許可になり危険。
|
|
9437
|
+
*
|
|
9438
|
+
* 網羅性は完璧でなくてよい (主要なもの)。後から追加可能な Set 構造。
|
|
9439
|
+
*/
|
|
9440
|
+
declare const FREEMAIL_DOMAINS: ReadonlySet<string>;
|
|
9441
|
+
/** ドメインがフリーメールか判定 (小文字化して比較)。 */
|
|
9442
|
+
declare function isFreemailDomain(domain: string): boolean;
|
|
9443
|
+
|
|
9422
9444
|
/**
|
|
9423
9445
|
* P1-A14a-1 / Threat Model S4 — canonical-string + signature-header
|
|
9424
9446
|
* helpers for HMAC body signing of internal HTTP requests.
|
|
@@ -9985,4 +10007,4 @@ declare function resolveActionRisk(action: string | undefined | null): ActionRis
|
|
|
9985
10007
|
|
|
9986
10008
|
declare const version = "0.0.1";
|
|
9987
10009
|
|
|
9988
|
-
export { type ABACPolicyEngine, ACTION_PARAMS_MAX_SIZE, ACTION_PREFIXES, ACTION_REGISTRY, AIdentityClient, type AIdentityConfig, AIdentityError, type APIAgent, type APICredential, APIVCManager, type AbacDecision, type AbacInput, type AcceptInvitationRequest, type AckEventResponse, type ActionInputSchema, type ActionMapping, type ActionMeta, type ActionParamDisplay, type ActionRegistry, type ActionRisk, type ActionRiskLevel, type Agent, type AgentCreateOptions, type AgentDIDConfig, AgentDIDManager, AgentManager, AgentStatus, AgentType, type AgentWithId, AllowAllAbac, type AnyProvider, type ApiKeyValidationResult, type ApprovalContext, type AuditEvent, type AuditQuery, AuthProvider, type AuthState, AuthenticationError, type AutoApproveConfig, type BindingSource, type BuildKbJwtPayloadArgs, type BuildKbJwtPayloadDeps, CANONICAL_PROVIDERS, type CanonicalProvider, type CapabilityMeta, type CedarDecision, type CedarDecisionDiagnostic, type CedarDecisionValue, type CedarEngine, CedarEngineUnavailableError, type CedarEntitiesInput, type CedarEntity, type CedarEntityDescriptor, type CedarError, type CedarEvaluateRequest, CedarParseError, type CedarPolicySetHandle, type CedarSchema, type CedarSchemaHandle, type CheckGrantPermissionRequest, type CheckGrantPermissionResult, type CheckPermissionInput, type CheckPermissionResult, type CollectContextRequest, type ConfirmGrantSuggestionRequest, type ConnectorAction, type ConnectorConfig, type ConnectorExecutionContext, type ConnectorResponse, type ConnectorResponseMetadata, type ConnectorTokenConfig, type ConstraintEvaluationResult, ConstraintEvaluator, type ConstraintEvaluatorOptions, type ConstraintViolation, type ConstraintWarning, type ContextBindingSource, type ContextProvider, type CreateGrantRequest, type CreateInvitationRequest, type CreateReceiptRequest, type CredentialRef, CredentialStatus, type CredentialStore, CredentialType, DECISION_VALUES, DEFAULT_CONSTRAINTS_BY_RISK, type DIDDocument, type DataAccessVC, type Decision, type DecisionTrace, type DelegationVC, DeviceEnrollManager, type DeviceEnrollPollResult, type DeviceEnrollServerSideParams, type DeviceEnrollStartParams, type DeviceEnrollStartResult, type DisclosureFields, DummyCreds, DummyVpVerifier, type EmployeeVPRequest, type EvaluateInput, type EvaluateResult, type EvaluationContext, type ExternalActionRequest, FilesystemKeyStorage, GATEWAY_ERROR_CODE, GatewayClient, GatewayError, type GatewayErrorCode, type GatewayEvent, type GetEventsOptions, type GetEventsResponse, type GitHubConfig, type GoogleConfig, type Grant, type GrantConstraints, type GrantResource, GrantResourceType, GrantScope, GrantStatus, type GrantUsage, type IConnectorService, type IStateStore, type Intent, type IntentEvaluationResult, type IntentObligation, type IntentResource, type InternalHmacSignerKey, InvalidVPError, type Invitation, type InvitationRole, InvitationStatus, type IssueSDJWTVCRequest, type IssueSDJWTVCResult, type JiraBoard, type JiraConfig, type JiraIssue, type JiraIssueLink, type JiraIssueLinkType, type JiraIssueType, type JiraProject, type JiraSprint, type JiraStatus, type JiraUser, type JiraWorklog, type JsonSchema, JsonStateStore, KB_JWT_DEFAULT_LIFETIME_SECONDS, type KbJwtPayload, KeyManager, type KeyPairGenerationResult, type KeyStorageConfig, type KeyStorageProvider, LEGACY_RESOURCE_TYPE_MAP, MIN_SIGNER_KEY_BYTES, MemoryKeyStorage, NetworkError, type NormalizeIntentRequest, type NormalizedIntent, type OAuthAuthorizeRequest, type OAuthCallbackParams, type OAuthConnection, OAuthProvider, type OAuthToken, type OrganizationConfig, type OrganizationPermission, type OrganizationPolicy, type OrganizationVC, PHASE_1_VC_LAYER, PROVIDER_ALIASES, type ParamBindingSource, type ParsedResourceType, type ParsedSignature, type PermissionConstraints, type PermissionMode, type PermissionResource, type PermissionRule, type PermissionTimeConstraint, type PermissionVcClaims, type PermissionVcClaims_V2, type PermissionVcClaims_V3, type Phase1VcLayer, type PlanDelegationInput, type PlanDelegationResult, type PolicyCondition, type PolicyEvaluationResult, type PolicyInput, type PolicyRef, type PolicyRefInline, type PolicyRefReference, type PolicyRule, type PolicySetHandle, type PolicyTarget, type PolicyValidationError, type Provider, REAUTH_REQUIRED_ACTION, RESOURCE_TYPES, type ReBACChecker, type Receipt, type ReceiptListResult, type ReceiptOutcome, type ReceiptSearchQuery, ReceiptStatus, type Relation, type ResolvedTargets, type ResourceIdBinding, type ResourceRef, type ResourceScope, type ResourceType, type RiskAssessmentResult, type RiskFactor, type RiskLevel, SDJwtClient, SIGNATURE_HEADER, SIGNATURE_VERSION_PREFIX, type SchemaHandle, ScopeUnmatchedError, type SecondaryBinding, type SignRequestArgs, SimpleRebac, type SlackConfig, StandardActionCategory, type SuggestGrantRequest, type SuggestedAction, type SuggestedConstraints, type SuggestedGrant, type SuggestedResource, type SuggestionRiskLevel, TIER_LIMITS, type TargetBindings, type TargetConstraint, TargetResolver, type TierLimits, type TimeWindowCheckResult, type TimeWindowConstraint, type ToolDefinition, type ToolInvocation, ToolManager, type ToolPermissionRequest, type ToolPermissionVC, type UnifiedResourceType, type UpdateGrantRequest, type UserIdentity, type UserIdentityConfig, type UserIdentityCreateOptions, UserIdentityManager, UserKeyPairManager, type UserTier, VALID_MCP_ACTIONS, VALID_MCP_TOOLS, VCExpiredError, VCManager, VCRevokedError, VCStatus, type VCTemplate, VCType, VPManager, type VPRequest, type VcApprovalClaim, type VerifiablePresentation, type VerificationMethod, type VerifiedVcClaims, type VerifyInvitationResponse, type VerifyReceiptRequest, type VerifyReceiptResult, type VerifySDJWTVCResult, type VpVerifier, WRITE_ACTION_NAMES, type WeeklyReportData, type WeeklyReportSummary, buildCanonicalString, buildCedarEntities, buildGrantIdFields, buildKbJwtPayload, buildPhase1VcClaims, buildValidationErrors, canonicalizeAction, checkPermissionWithVP, classifyCedarErrorMessage, configure, createAjv, createCedarEngine, createDidJwk, credentialStatusToVCStatus, defaultConstraintEvaluator, evaluateConstraints, extractProjectKey, extractPublicKey, extractPublicKeyFromDid, formatSignatureHeader, generateActionParamsDisplay, generateActionSummary, generateKeyPair, generateNonce, getActionAliases, getAllActionForms, getAllValidMcpActionNames, getClient, getDefaultDisclosureFields, getKeyIdFromDid, getRequiredRelations, getRequiredScopes, getTierLimits, getValidMcpActionNames, grantConstraintsToPermissionConstraints, grantToPermissionRules, indexActions, indexCapabilities, isActionEquivalent, isCanonicalProvider, isDecision, isPolicyRefInline, isPolicyRefReference, isUnlimited, isValidDidJwk, isValidProvider, isWriteAction, loadActionRegistryFromFile, loadActionRegistryFromObject, normalizeDomain, normalizeMcpActionName, parseGrantAction, parseGrantResourceType, parseSignatureHeader, planDelegationForVC, publicKeysMatch, readVcExpSeconds, resolveActionRisk, resolveActionsFromSelection, resolveProvider, resolveResourceType, resolveUserTier, sha256Hex, signJWT, signRequest, validateRegistryObject, vcStatusToCredentialStatus, verifyJWT, version };
|
|
10010
|
+
export { type ABACPolicyEngine, ACTION_PARAMS_MAX_SIZE, ACTION_PREFIXES, ACTION_REGISTRY, AIdentityClient, type AIdentityConfig, AIdentityError, type APIAgent, type APICredential, APIVCManager, type AbacDecision, type AbacInput, type AcceptInvitationRequest, type AckEventResponse, type ActionInputSchema, type ActionMapping, type ActionMeta, type ActionParamDisplay, type ActionRegistry, type ActionRisk, type ActionRiskLevel, type Agent, type AgentCreateOptions, type AgentDIDConfig, AgentDIDManager, AgentManager, AgentStatus, AgentType, type AgentWithId, AllowAllAbac, type AnyProvider, type ApiKeyValidationResult, type ApprovalContext, type AuditEvent, type AuditQuery, AuthProvider, type AuthState, AuthenticationError, type AutoApproveConfig, type BindingSource, type BuildKbJwtPayloadArgs, type BuildKbJwtPayloadDeps, CANONICAL_PROVIDERS, type CanonicalProvider, type CapabilityMeta, type CedarDecision, type CedarDecisionDiagnostic, type CedarDecisionValue, type CedarEngine, CedarEngineUnavailableError, type CedarEntitiesInput, type CedarEntity, type CedarEntityDescriptor, type CedarError, type CedarEvaluateRequest, CedarParseError, type CedarPolicySetHandle, type CedarSchema, type CedarSchemaHandle, type CheckGrantPermissionRequest, type CheckGrantPermissionResult, type CheckPermissionInput, type CheckPermissionResult, type CollectContextRequest, type ConfirmGrantSuggestionRequest, type ConnectorAction, type ConnectorConfig, type ConnectorExecutionContext, type ConnectorResponse, type ConnectorResponseMetadata, type ConnectorTokenConfig, type ConstraintEvaluationResult, ConstraintEvaluator, type ConstraintEvaluatorOptions, type ConstraintViolation, type ConstraintWarning, type ContextBindingSource, type ContextProvider, type CreateGrantRequest, type CreateInvitationRequest, type CreateReceiptRequest, type CredentialRef, CredentialStatus, type CredentialStore, CredentialType, DECISION_VALUES, DEFAULT_CONSTRAINTS_BY_RISK, type DIDDocument, type DataAccessVC, type Decision, type DecisionTrace, type DelegationVC, DeviceEnrollManager, type DeviceEnrollPollResult, type DeviceEnrollServerSideParams, type DeviceEnrollStartParams, type DeviceEnrollStartResult, type DisclosureFields, DummyCreds, DummyVpVerifier, type EmployeeVPRequest, type EvaluateInput, type EvaluateResult, type EvaluationContext, type ExternalActionRequest, FREEMAIL_DOMAINS, FilesystemKeyStorage, GATEWAY_ERROR_CODE, GatewayClient, GatewayError, type GatewayErrorCode, type GatewayEvent, type GetEventsOptions, type GetEventsResponse, type GitHubConfig, type GoogleConfig, type Grant, type GrantConstraints, type GrantResource, GrantResourceType, GrantScope, GrantStatus, type GrantUsage, type IConnectorService, type IStateStore, type Intent, type IntentEvaluationResult, type IntentObligation, type IntentResource, type InternalHmacSignerKey, InvalidVPError, type Invitation, type InvitationRole, InvitationStatus, type IssueSDJWTVCRequest, type IssueSDJWTVCResult, type JiraBoard, type JiraConfig, type JiraIssue, type JiraIssueLink, type JiraIssueLinkType, type JiraIssueType, type JiraProject, type JiraSprint, type JiraStatus, type JiraUser, type JiraWorklog, type JsonSchema, JsonStateStore, KB_JWT_DEFAULT_LIFETIME_SECONDS, type KbJwtPayload, KeyManager, type KeyPairGenerationResult, type KeyStorageConfig, type KeyStorageProvider, LEGACY_RESOURCE_TYPE_MAP, MIN_SIGNER_KEY_BYTES, MemoryKeyStorage, NetworkError, type NormalizeIntentRequest, type NormalizedIntent, type OAuthAuthorizeRequest, type OAuthCallbackParams, type OAuthConnection, OAuthProvider, type OAuthToken, type OrganizationConfig, type OrganizationPermission, type OrganizationPolicy, type OrganizationVC, PHASE_1_VC_LAYER, PROVIDER_ALIASES, type ParamBindingSource, type ParsedResourceType, type ParsedSignature, type PermissionConstraints, type PermissionMode, type PermissionResource, type PermissionRule, type PermissionTimeConstraint, type PermissionVcClaims, type PermissionVcClaims_V2, type PermissionVcClaims_V3, type Phase1VcLayer, type PlanDelegationInput, type PlanDelegationResult, type PolicyCondition, type PolicyEvaluationResult, type PolicyInput, type PolicyRef, type PolicyRefInline, type PolicyRefReference, type PolicyRule, type PolicySetHandle, type PolicyTarget, type PolicyValidationError, type Provider, REAUTH_REQUIRED_ACTION, RESOURCE_TYPES, type ReBACChecker, type Receipt, type ReceiptListResult, type ReceiptOutcome, type ReceiptSearchQuery, ReceiptStatus, type Relation, type ResolvedTargets, type ResourceIdBinding, type ResourceRef, type ResourceScope, type ResourceType, type RiskAssessmentResult, type RiskFactor, type RiskLevel, SDJwtClient, SIGNATURE_HEADER, SIGNATURE_VERSION_PREFIX, type SchemaHandle, ScopeUnmatchedError, type SecondaryBinding, type SignRequestArgs, SimpleRebac, type SlackConfig, StandardActionCategory, type SuggestGrantRequest, type SuggestedAction, type SuggestedConstraints, type SuggestedGrant, type SuggestedResource, type SuggestionRiskLevel, TIER_LIMITS, type TargetBindings, type TargetConstraint, TargetResolver, type TierLimits, type TimeWindowCheckResult, type TimeWindowConstraint, type ToolDefinition, type ToolInvocation, ToolManager, type ToolPermissionRequest, type ToolPermissionVC, type UnifiedResourceType, type UpdateGrantRequest, type UserIdentity, type UserIdentityConfig, type UserIdentityCreateOptions, UserIdentityManager, UserKeyPairManager, type UserTier, VALID_MCP_ACTIONS, VALID_MCP_TOOLS, VCExpiredError, VCManager, VCRevokedError, VCStatus, type VCTemplate, VCType, VPManager, type VPRequest, type VcApprovalClaim, type VerifiablePresentation, type VerificationMethod, type VerifiedVcClaims, type VerifyInvitationResponse, type VerifyReceiptRequest, type VerifyReceiptResult, type VerifySDJWTVCResult, type VpVerifier, WRITE_ACTION_NAMES, type WeeklyReportData, type WeeklyReportSummary, buildCanonicalString, buildCedarEntities, buildGrantIdFields, buildKbJwtPayload, buildPhase1VcClaims, buildValidationErrors, canonicalizeAction, checkPermissionWithVP, classifyCedarErrorMessage, configure, createAjv, createCedarEngine, createDidJwk, credentialStatusToVCStatus, defaultConstraintEvaluator, evaluateConstraints, extractProjectKey, extractPublicKey, extractPublicKeyFromDid, formatSignatureHeader, generateActionParamsDisplay, generateActionSummary, generateKeyPair, generateNonce, getActionAliases, getAllActionForms, getAllValidMcpActionNames, getClient, getDefaultDisclosureFields, getKeyIdFromDid, getRequiredRelations, getRequiredScopes, getTierLimits, getValidMcpActionNames, grantConstraintsToPermissionConstraints, grantToPermissionRules, indexActions, indexCapabilities, isActionEquivalent, isCanonicalProvider, isDecision, isFreemailDomain, isPolicyRefInline, isPolicyRefReference, isUnlimited, isValidDidJwk, isValidProvider, isWriteAction, loadActionRegistryFromFile, loadActionRegistryFromObject, normalizeDomain, normalizeMcpActionName, parseGrantAction, parseGrantResourceType, parseSignatureHeader, planDelegationForVC, publicKeysMatch, readVcExpSeconds, resolveActionRisk, resolveActionsFromSelection, resolveProvider, resolveResourceType, resolveUserTier, sha256Hex, signJWT, signRequest, validateRegistryObject, vcStatusToCredentialStatus, verifyJWT, version };
|
package/dist/index.d.ts
CHANGED
|
@@ -34,6 +34,7 @@ export { isPolicyRefInline, isPolicyRefReference, PHASE_1_VC_LAYER, buildPhase1V
|
|
|
34
34
|
export type { CedarSchema, CedarPolicySetHandle, CedarSchemaHandle, CedarDecisionValue, CedarDecisionDiagnostic, } from './types/cedar-policy';
|
|
35
35
|
export { isWriteAction, WRITE_ACTION_NAMES } from './utils/action-classifier';
|
|
36
36
|
export { resolveUserTier, getTierLimits, isUnlimited } from './utils/tier-utils';
|
|
37
|
+
export { FREEMAIL_DOMAINS, isFreemailDomain } from './utils/freemail-domains';
|
|
37
38
|
export * from './internal-signature';
|
|
38
39
|
export { createCedarEngine, CedarEngineUnavailableError, CedarParseError, } from './policy';
|
|
39
40
|
export type { CedarEngine, CedarDecision, CedarEntity, CedarEvaluateRequest, EvaluateInput, EvaluateResult, CedarError, SchemaHandle, PolicySetHandle, } from './policy';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,MAAM,UAAU,CAAA;AAGrD,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAGrD,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAC9C,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAA;AAC3D,OAAO,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAA;AACtE,OAAO,EAAE,kB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,EACL,qBAAqB,EACrB,yBAAyB,GAC1B,MAAM,UAAU,CAAA;AACjB,YAAY,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAA;AAGrD,OAAO,EAAE,kBAAkB,EAAE,eAAe,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAC1E,YAAY,EACV,kBAAkB,EAClB,qBAAqB,EACrB,QAAQ,GACT,MAAM,UAAU,CAAA;AACjB,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAA;AAC1D,YAAY,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAA;AAGxD,eAAO,MAAM,OAAO,UAAU,CAAA"}
|
package/dist/index.js
CHANGED
|
@@ -54,6 +54,7 @@ __export(index_exports, {
|
|
|
54
54
|
DeviceEnrollManager: () => DeviceEnrollManager,
|
|
55
55
|
DummyCreds: () => DummyCreds,
|
|
56
56
|
DummyVpVerifier: () => DummyVpVerifier,
|
|
57
|
+
FREEMAIL_DOMAINS: () => FREEMAIL_DOMAINS,
|
|
57
58
|
FilesystemKeyStorage: () => FilesystemKeyStorage,
|
|
58
59
|
GATEWAY_ERROR_CODE: () => GATEWAY_ERROR_CODE,
|
|
59
60
|
GatewayClient: () => GatewayClient,
|
|
@@ -137,6 +138,7 @@ __export(index_exports, {
|
|
|
137
138
|
isActionEquivalent: () => isActionEquivalent,
|
|
138
139
|
isCanonicalProvider: () => isCanonicalProvider,
|
|
139
140
|
isDecision: () => isDecision,
|
|
141
|
+
isFreemailDomain: () => isFreemailDomain,
|
|
140
142
|
isPolicyRefInline: () => isPolicyRefInline,
|
|
141
143
|
isPolicyRefReference: () => isPolicyRefReference,
|
|
142
144
|
isUnlimited: () => isUnlimited,
|
|
@@ -6300,6 +6302,42 @@ function getTierLimits(tier) {
|
|
|
6300
6302
|
return TIER_LIMITS[resolveUserTier(tier)];
|
|
6301
6303
|
}
|
|
6302
6304
|
|
|
6305
|
+
// src/utils/freemail-domains.ts
|
|
6306
|
+
var FREEMAIL_DOMAINS = /* @__PURE__ */ new Set([
|
|
6307
|
+
"gmail.com",
|
|
6308
|
+
"googlemail.com",
|
|
6309
|
+
"outlook.com",
|
|
6310
|
+
"hotmail.com",
|
|
6311
|
+
"live.com",
|
|
6312
|
+
"yahoo.com",
|
|
6313
|
+
"yahoo.co.jp",
|
|
6314
|
+
"ymail.com",
|
|
6315
|
+
"icloud.com",
|
|
6316
|
+
"me.com",
|
|
6317
|
+
"mac.com",
|
|
6318
|
+
"aol.com",
|
|
6319
|
+
"protonmail.com",
|
|
6320
|
+
"proton.me",
|
|
6321
|
+
"pm.me",
|
|
6322
|
+
"gmx.com",
|
|
6323
|
+
"gmx.net",
|
|
6324
|
+
"mail.com",
|
|
6325
|
+
"zoho.com",
|
|
6326
|
+
"yandex.com",
|
|
6327
|
+
// 日本の主要キャリア/フリーメール
|
|
6328
|
+
"docomo.ne.jp",
|
|
6329
|
+
"ezweb.ne.jp",
|
|
6330
|
+
"au.com",
|
|
6331
|
+
"softbank.ne.jp",
|
|
6332
|
+
"i.softbank.jp",
|
|
6333
|
+
"nifty.com",
|
|
6334
|
+
"so-net.ne.jp",
|
|
6335
|
+
"biglobe.ne.jp"
|
|
6336
|
+
]);
|
|
6337
|
+
function isFreemailDomain(domain) {
|
|
6338
|
+
return FREEMAIL_DOMAINS.has(domain.trim().toLowerCase());
|
|
6339
|
+
}
|
|
6340
|
+
|
|
6303
6341
|
// src/internal-signature/canonical.ts
|
|
6304
6342
|
var import_crypto3 = require("crypto");
|
|
6305
6343
|
var SIGNATURE_HEADER = "x-internal-signature";
|
|
@@ -6671,6 +6709,7 @@ var version = "0.0.1";
|
|
|
6671
6709
|
DeviceEnrollManager,
|
|
6672
6710
|
DummyCreds,
|
|
6673
6711
|
DummyVpVerifier,
|
|
6712
|
+
FREEMAIL_DOMAINS,
|
|
6674
6713
|
FilesystemKeyStorage,
|
|
6675
6714
|
GATEWAY_ERROR_CODE,
|
|
6676
6715
|
GatewayClient,
|
|
@@ -6754,6 +6793,7 @@ var version = "0.0.1";
|
|
|
6754
6793
|
isActionEquivalent,
|
|
6755
6794
|
isCanonicalProvider,
|
|
6756
6795
|
isDecision,
|
|
6796
|
+
isFreemailDomain,
|
|
6757
6797
|
isPolicyRefInline,
|
|
6758
6798
|
isPolicyRefReference,
|
|
6759
6799
|
isUnlimited,
|