@ory/argus 1.1.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.
- package/dist/auth.d.ts +4 -0
- package/dist/auth.js +4 -0
- package/dist/build-info.json +4 -4
- package/dist/opl.js +2 -1
- package/package.json +1 -1
package/dist/auth.d.ts
CHANGED
|
@@ -52,6 +52,8 @@ export interface PkceLoginOptions {
|
|
|
52
52
|
isHeadless?: () => boolean;
|
|
53
53
|
/** Optional AbortSignal to cancel the login (e.g. on shutdown). */
|
|
54
54
|
signal?: AbortSignal;
|
|
55
|
+
/** @internal Injectable seam for testing default-fetch TLS setup. */
|
|
56
|
+
configureSystemCaTrust?: () => void;
|
|
55
57
|
}
|
|
56
58
|
export type PkceLoginOutcome = {
|
|
57
59
|
kind: "ok";
|
|
@@ -119,6 +121,8 @@ export declare function refreshAccessToken(args: {
|
|
|
119
121
|
projectUrl: string;
|
|
120
122
|
clientId: string;
|
|
121
123
|
refreshToken: string;
|
|
124
|
+
/** @internal Injectable seam for testing default-fetch TLS setup. */
|
|
125
|
+
configureSystemCaTrust?: () => void;
|
|
122
126
|
}): Promise<OryOAuth2Tokens>;
|
|
123
127
|
/**
|
|
124
128
|
* Best-effort human-readable name for the signed-in user, pulled from the
|
package/dist/auth.js
CHANGED
|
@@ -60,6 +60,7 @@ const node_url_1 = require("node:url");
|
|
|
60
60
|
const fs = __importStar(require("node:fs"));
|
|
61
61
|
const path = __importStar(require("node:path"));
|
|
62
62
|
const branding_js_1 = require("./branding.js");
|
|
63
|
+
const runtime_credential_js_1 = require("./runtime-credential.js");
|
|
63
64
|
/** Loopback ports tried in order. All must be registered as redirect URIs on the Ory OAuth2 client. */
|
|
64
65
|
exports.LOOPBACK_PORTS = [47823, 47824, 47825, 47826];
|
|
65
66
|
/**
|
|
@@ -202,6 +203,7 @@ async function runPkceAttempt(options, scope, scopeFallbackPending) {
|
|
|
202
203
|
redirectUri,
|
|
203
204
|
code: result.code,
|
|
204
205
|
codeVerifier,
|
|
206
|
+
configureSystemCaTrust: options.configureSystemCaTrust,
|
|
205
207
|
});
|
|
206
208
|
return { kind: "ok", tokens };
|
|
207
209
|
}
|
|
@@ -516,6 +518,7 @@ async function exchangeCodeForTokens(args) {
|
|
|
516
518
|
code_verifier: args.codeVerifier,
|
|
517
519
|
});
|
|
518
520
|
const tokenUrl = new node_url_1.URL("/oauth2/token", args.projectUrl).toString();
|
|
521
|
+
(args.configureSystemCaTrust ?? runtime_credential_js_1.configureSystemCaTrustForDefaultFetch)();
|
|
519
522
|
const res = await fetch(tokenUrl, {
|
|
520
523
|
method: "POST",
|
|
521
524
|
headers: { "content-type": "application/x-www-form-urlencoded" },
|
|
@@ -558,6 +561,7 @@ async function refreshAccessToken(args) {
|
|
|
558
561
|
refresh_token: args.refreshToken,
|
|
559
562
|
});
|
|
560
563
|
const tokenUrl = new node_url_1.URL("/oauth2/token", args.projectUrl).toString();
|
|
564
|
+
(args.configureSystemCaTrust ?? runtime_credential_js_1.configureSystemCaTrustForDefaultFetch)();
|
|
561
565
|
const res = await fetch(tokenUrl, {
|
|
562
566
|
method: "POST",
|
|
563
567
|
headers: { "content-type": "application/x-www-form-urlencoded" },
|
package/dist/build-info.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"repo": "ory-agent-plugins",
|
|
3
|
-
"commit": "
|
|
4
|
-
"commitShort": "
|
|
3
|
+
"commit": "f046260973bf9257c98d5a06e1d6e945f3c291e5",
|
|
4
|
+
"commitShort": "f046260",
|
|
5
5
|
"branch": "main",
|
|
6
|
-
"commitDate": "2026-
|
|
6
|
+
"commitDate": "2026-09-01T17:01:44-07:00",
|
|
7
7
|
"dirty": false,
|
|
8
|
-
"builtAt": "2026-
|
|
8
|
+
"builtAt": "2026-09-02T00:05:01.245Z"
|
|
9
9
|
}
|
package/dist/opl.js
CHANGED
|
@@ -415,7 +415,8 @@ function buildAgentSecurityOpl(namespace = exports.DEFAULT_NAMESPACE, shellNames
|
|
|
415
415
|
renderDelegationNamespaceClass(),
|
|
416
416
|
"",
|
|
417
417
|
"// Registered credential groups used to apply posture by harness or sub-agent type.",
|
|
418
|
-
|
|
418
|
+
"// Delegated Sub-Agents also belong to their parent harness group.",
|
|
419
|
+
renderAgentTypeNamespaceClass(exports.AGENT_TYPE_NAMESPACE, `${subject_js_1.AGENT_NAMESPACE} | ${subject_js_1.SUBAGENT_NAMESPACE}`),
|
|
419
420
|
"",
|
|
420
421
|
renderAgentTypeNamespaceClass(exports.SUBAGENT_TYPE_NAMESPACE, subject_js_1.SUBAGENT_NAMESPACE),
|
|
421
422
|
"",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ory/argus",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"description": "Ory Argus: the core API for building authentication, authorization, and audit into AI agent harness plugins, extensions, and custom integrations",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://ory.com",
|