@integrity-labs/agt-cli 0.28.772 → 0.28.774
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/bin/agt.js +6 -6
- package/dist/{chunk-SBAX57SN.js → chunk-BUCKLMKD.js} +6 -71
- package/dist/chunk-BUCKLMKD.js.map +1 -0
- package/dist/{chunk-UPSDSMNC.js → chunk-PMKI7ZTP.js} +136 -1
- package/dist/chunk-PMKI7ZTP.js.map +1 -0
- package/dist/{chunk-R6XGVTQS.js → chunk-SXTHAF3R.js} +2 -2
- package/dist/{claude-pair-runtime-Z7JFVKIY.js → claude-pair-runtime-O7T3PIMT.js} +2 -2
- package/dist/lib/manager-worker.js +13 -13
- package/dist/mcp/direct-chat-channel.js +68 -0
- package/dist/mcp/index.js +213 -13
- package/dist/mcp/origami.js +68 -0
- package/dist/mcp/slack-channel.js +68 -0
- package/dist/mcp/telegram-channel.js +68 -0
- package/dist/{persistent-session-NUVUR3PB.js → persistent-session-C2Y4CSAY.js} +3 -3
- package/dist/{responsiveness-probe-J3D7MRIU.js → responsiveness-probe-7CVB5NBT.js} +3 -3
- package/dist/{session-auth-dead-GKZNZKWI.js → session-auth-dead-E3WEZYEH.js} +2 -2
- package/package.json +1 -1
- package/dist/chunk-SBAX57SN.js.map +0 -1
- package/dist/chunk-UPSDSMNC.js.map +0 -1
- /package/dist/{chunk-R6XGVTQS.js.map → chunk-SXTHAF3R.js.map} +0 -0
- /package/dist/{claude-pair-runtime-Z7JFVKIY.js.map → claude-pair-runtime-O7T3PIMT.js.map} +0 -0
- /package/dist/{persistent-session-NUVUR3PB.js.map → persistent-session-C2Y4CSAY.js.map} +0 -0
- /package/dist/{responsiveness-probe-J3D7MRIU.js.map → responsiveness-probe-7CVB5NBT.js.map} +0 -0
- /package/dist/{session-auth-dead-GKZNZKWI.js.map → session-auth-dead-E3WEZYEH.js.map} +0 -0
package/dist/bin/agt.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
import {
|
|
3
3
|
ApiError,
|
|
4
4
|
DRAIN_MANIFEST_FILENAME,
|
|
5
|
-
LITERAL_SECRET_PATTERNS,
|
|
6
5
|
PROD_AGT_HOST,
|
|
7
6
|
api,
|
|
8
7
|
buildConnectivityProbeDeps,
|
|
@@ -41,17 +40,18 @@ import {
|
|
|
41
40
|
success,
|
|
42
41
|
table,
|
|
43
42
|
warn
|
|
44
|
-
} from "../chunk-
|
|
43
|
+
} from "../chunk-BUCKLMKD.js";
|
|
45
44
|
import {
|
|
46
45
|
getProjectDir,
|
|
47
46
|
isSessionResumeDisabled,
|
|
48
47
|
readDirectChatSessionState
|
|
49
|
-
} from "../chunk-
|
|
48
|
+
} from "../chunk-SXTHAF3R.js";
|
|
50
49
|
import {
|
|
51
50
|
AnchorSessionClient,
|
|
52
51
|
CHANNEL_REGISTRY,
|
|
53
52
|
DEFAULT_FRAMEWORK,
|
|
54
53
|
DEPLOYMENT_TEMPLATES,
|
|
54
|
+
LITERAL_SECRET_PATTERNS,
|
|
55
55
|
SLACK_SCOPE_CATEGORY_LABELS,
|
|
56
56
|
SLACK_SCOPE_PRESETS,
|
|
57
57
|
SlackApiError,
|
|
@@ -79,7 +79,7 @@ import {
|
|
|
79
79
|
serializeManifestForSlackCli,
|
|
80
80
|
sessionFileExists,
|
|
81
81
|
sessionTranscriptDir
|
|
82
|
-
} from "../chunk-
|
|
82
|
+
} from "../chunk-PMKI7ZTP.js";
|
|
83
83
|
import "../chunk-XWVM4KPK.js";
|
|
84
84
|
|
|
85
85
|
// src/bin/agt.ts
|
|
@@ -5467,7 +5467,7 @@ import { execFileSync, execSync } from "child_process";
|
|
|
5467
5467
|
import { existsSync as existsSync11, realpathSync as realpathSync2 } from "fs";
|
|
5468
5468
|
import chalk18 from "chalk";
|
|
5469
5469
|
import ora16 from "ora";
|
|
5470
|
-
var cliVersion = true ? "0.28.
|
|
5470
|
+
var cliVersion = true ? "0.28.774" : "dev";
|
|
5471
5471
|
async function fetchLatestVersion() {
|
|
5472
5472
|
const host2 = getHost();
|
|
5473
5473
|
if (!host2) return null;
|
|
@@ -6658,7 +6658,7 @@ function handleError(err) {
|
|
|
6658
6658
|
}
|
|
6659
6659
|
|
|
6660
6660
|
// src/bin/agt.ts
|
|
6661
|
-
var cliVersion2 = true ? "0.28.
|
|
6661
|
+
var cliVersion2 = true ? "0.28.774" : "dev";
|
|
6662
6662
|
var program = new Command();
|
|
6663
6663
|
program.name("agt").description("Augmented CLI \u2014 agent provisioning and management").version(cliVersion2).option("--json", "Emit machine-readable JSON output (suppress spinners and colors)").option("--skip-update-check", "Skip the automatic update check on startup");
|
|
6664
6664
|
program.hook("preAction", async (thisCommand, actionCommand) => {
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
parseEnvFileEntries,
|
|
15
15
|
parseEnvIntegrations,
|
|
16
16
|
shellQuote
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-SXTHAF3R.js";
|
|
18
18
|
import {
|
|
19
19
|
BIND_FAILURE_QUARANTINE_THRESHOLD,
|
|
20
20
|
INTEGRATIONS_SECTION_END,
|
|
@@ -36,6 +36,7 @@ import {
|
|
|
36
36
|
buildForwardHeaders,
|
|
37
37
|
buildIntegrationsSection,
|
|
38
38
|
coerceEnvValue,
|
|
39
|
+
formatLiteralSecretRejection,
|
|
39
40
|
generateClaudeMd,
|
|
40
41
|
getFlagDefinition,
|
|
41
42
|
getFramework,
|
|
@@ -61,82 +62,17 @@ import {
|
|
|
61
62
|
remoteMcpServerKey,
|
|
62
63
|
resolveAvatarEnvUrl,
|
|
63
64
|
resolveConnectivityProbe,
|
|
65
|
+
scanConfigForLiteralSecrets,
|
|
64
66
|
sessionTranscriptDir,
|
|
65
67
|
worseConnectivityOutcome,
|
|
66
68
|
wrapScheduledTaskPrompt
|
|
67
|
-
} from "./chunk-
|
|
69
|
+
} from "./chunk-PMKI7ZTP.js";
|
|
68
70
|
import {
|
|
69
71
|
parsePsRows
|
|
70
72
|
} from "./chunk-XWVM4KPK.js";
|
|
71
73
|
|
|
72
74
|
// ../../packages/core/dist/provisioning/mcp-config-guards.js
|
|
73
75
|
import { chmodSync, existsSync, readFileSync, renameSync, writeFileSync, unlinkSync } from "fs";
|
|
74
|
-
|
|
75
|
-
// ../../packages/core/dist/provisioning/mcp-secret-lint.js
|
|
76
|
-
var LITERAL_SECRET_PATTERNS = [
|
|
77
|
-
// Slack bot token — `xoxb-<workspace>-<...>`
|
|
78
|
-
{ name: "slack_bot_token", re: /^xoxb-/ },
|
|
79
|
-
// Slack app-level token (Socket Mode) — `xapp-<...>`
|
|
80
|
-
{ name: "slack_app_token", re: /^xapp-/ },
|
|
81
|
-
// AGT host API key — `tlk_<...>` (see claudecode-plugin-augmented README).
|
|
82
|
-
{ name: "agt_host_api_key", re: /^tlk_/ },
|
|
83
|
-
// Composio / generic api-key prefix — `ak_<...>`
|
|
84
|
-
{ name: "composio_api_key", re: /^ak_/ },
|
|
85
|
-
// Telegram bot token — `<bot id>:AA<...>` (BotFather format). ENG-5901
|
|
86
|
-
// PR 4: the original `\d{10}:AAE` (from the issue AC) was too narrow —
|
|
87
|
-
// live tokens on agt-aws-1 carry `AA` + a varying third character
|
|
88
|
-
// (don/scout/stirling all had AA-not-E tokens the lint and migration
|
|
89
|
-
// missed). Bot ids are 8–12 digits; the token part always starts `AA`.
|
|
90
|
-
{ name: "telegram_bot_token", re: /^\d{8,12}:AA[A-Za-z0-9_-]/ },
|
|
91
|
-
// ENG-5901 extension beyond the original AC's five patterns: a literal
|
|
92
|
-
// JWT (`eyJ...`) is the shape of a leaked AGT_API_KEY, which the
|
|
93
|
-
// value-prefix patterns above would otherwise miss. Header values often
|
|
94
|
-
// carry it behind `Bearer ` (or a copy-pasted `Authorization: Bearer `),
|
|
95
|
-
// so those prefixes are optionally consumed (CodeRabbit #1731).
|
|
96
|
-
// Templates (`Bearer ${AGT_API_KEY}`) and concrete non-secret values
|
|
97
|
-
// (UUIDs, hosts) never put `eyJ` after the prefix, so this stays
|
|
98
|
-
// false-positive-safe inside .mcp.json.
|
|
99
|
-
{ name: "jwt_agt_api_key", re: /^(?:authorization:\s*)?(?:bearer\s+)?eyJ[A-Za-z0-9_-]+\./i }
|
|
100
|
-
];
|
|
101
|
-
function matchLiteralSecret(value) {
|
|
102
|
-
for (const { name, re } of LITERAL_SECRET_PATTERNS) {
|
|
103
|
-
if (re.test(value))
|
|
104
|
-
return name;
|
|
105
|
-
}
|
|
106
|
-
return null;
|
|
107
|
-
}
|
|
108
|
-
function scanRecord(server, record, location, findings) {
|
|
109
|
-
if (!record)
|
|
110
|
-
return;
|
|
111
|
-
for (const [field, value] of Object.entries(record)) {
|
|
112
|
-
if (typeof value !== "string")
|
|
113
|
-
continue;
|
|
114
|
-
const pattern = matchLiteralSecret(value);
|
|
115
|
-
if (pattern)
|
|
116
|
-
findings.push({ server, field, location, pattern });
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
function scanConfigForLiteralSecrets(config) {
|
|
120
|
-
const findings = [];
|
|
121
|
-
if (typeof config !== "object" || config === null)
|
|
122
|
-
return findings;
|
|
123
|
-
const servers = config.mcpServers;
|
|
124
|
-
if (typeof servers !== "object" || servers === null)
|
|
125
|
-
return findings;
|
|
126
|
-
for (const [server, raw] of Object.entries(servers)) {
|
|
127
|
-
if (typeof raw !== "object" || raw === null)
|
|
128
|
-
continue;
|
|
129
|
-
const entry = raw;
|
|
130
|
-
scanRecord(server, entry.env, "env", findings);
|
|
131
|
-
scanRecord(server, entry.headers, "header", findings);
|
|
132
|
-
}
|
|
133
|
-
return findings;
|
|
134
|
-
}
|
|
135
|
-
function formatLiteralSecretRejection(f) {
|
|
136
|
-
return `[mcp-write] [literal-secret-rejected] field=${f.field} server=${f.server} location=${f.location} pattern=${f.pattern}`;
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
// ../../packages/core/dist/provisioning/mcp-config-guards.js
|
|
140
76
|
var MCP_FILE_MODE = 384;
|
|
141
77
|
var lastRejectionFingerprintByPath = /* @__PURE__ */ new Map();
|
|
142
78
|
var REQUIRED_ENV_RULES_BY_SERVER = {
|
|
@@ -6452,7 +6388,7 @@ function exchangeFailureKind(err) {
|
|
|
6452
6388
|
}
|
|
6453
6389
|
|
|
6454
6390
|
// src/lib/api-client.ts
|
|
6455
|
-
var agtCliVersion = true ? "0.28.
|
|
6391
|
+
var agtCliVersion = true ? "0.28.774" : "dev";
|
|
6456
6392
|
var lastConfigHash = null;
|
|
6457
6393
|
function setConfigHash(hash) {
|
|
6458
6394
|
lastConfigHash = hash && hash.length > 0 ? hash : null;
|
|
@@ -10566,7 +10502,6 @@ function withEvidence(outcome, evidence) {
|
|
|
10566
10502
|
}
|
|
10567
10503
|
|
|
10568
10504
|
export {
|
|
10569
|
-
LITERAL_SECRET_PATTERNS,
|
|
10570
10505
|
safeWriteJsonAtomic,
|
|
10571
10506
|
extractCommandNotFound,
|
|
10572
10507
|
migrateAgentDirToIdKeyed,
|
|
@@ -10655,4 +10590,4 @@ export {
|
|
|
10655
10590
|
managerInstallSystemUnitCommand,
|
|
10656
10591
|
managerUninstallSystemUnitCommand
|
|
10657
10592
|
};
|
|
10658
|
-
//# sourceMappingURL=chunk-
|
|
10593
|
+
//# sourceMappingURL=chunk-BUCKLMKD.js.map
|