@integrity-labs/agt-cli 0.27.142 → 0.27.144
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 +4 -4
- package/dist/{chunk-IDDSO7Q5.js → chunk-7GKJZBTB.js} +2 -2
- package/dist/{chunk-OI33LV54.js → chunk-HPUIWWKD.js} +11 -5
- package/dist/chunk-HPUIWWKD.js.map +1 -0
- package/dist/{chunk-WCXA7EEP.js → chunk-WOOYOAPG.js} +27 -1
- package/dist/chunk-WOOYOAPG.js.map +1 -0
- package/dist/{claude-pair-runtime-ZLYTTNUY.js → claude-pair-runtime-GIUCD7IG.js} +2 -2
- package/dist/lib/manager-worker.js +22 -10
- package/dist/lib/manager-worker.js.map +1 -1
- package/dist/mcp/slack-channel.js +40 -6
- package/dist/{persistent-session-SOCMTNFC.js → persistent-session-35PWSTLO.js} +3 -3
- package/dist/{responsiveness-probe-USWGCI4C.js → responsiveness-probe-MA4M2QM4.js} +3 -3
- package/package.json +1 -1
- package/dist/chunk-OI33LV54.js.map +0 -1
- package/dist/chunk-WCXA7EEP.js.map +0 -1
- /package/dist/{chunk-IDDSO7Q5.js.map → chunk-7GKJZBTB.js.map} +0 -0
- /package/dist/{claude-pair-runtime-ZLYTTNUY.js.map → claude-pair-runtime-GIUCD7IG.js.map} +0 -0
- /package/dist/{persistent-session-SOCMTNFC.js.map → persistent-session-35PWSTLO.js.map} +0 -0
- /package/dist/{responsiveness-probe-USWGCI4C.js.map → responsiveness-probe-MA4M2QM4.js.map} +0 -0
|
@@ -15568,6 +15568,19 @@ function mergeInboundText(text, blocks) {
|
|
|
15568
15568
|
return { content, recoveredTable: rendered.length > 0 && content !== text };
|
|
15569
15569
|
}
|
|
15570
15570
|
|
|
15571
|
+
// src/slack-allowlist-source.ts
|
|
15572
|
+
function parseAllowedUsersCsv(raw) {
|
|
15573
|
+
return new Set(
|
|
15574
|
+
(raw ?? "").split(",").map((s) => s.trim()).filter((s) => s.length > 0)
|
|
15575
|
+
);
|
|
15576
|
+
}
|
|
15577
|
+
function extractAllowedUsersFromMcpJson(jsonText) {
|
|
15578
|
+
const parsed = JSON.parse(jsonText);
|
|
15579
|
+
const slackServer = parsed.mcpServers?.["slack"];
|
|
15580
|
+
if (!slackServer) return null;
|
|
15581
|
+
return parseAllowedUsersCsv(slackServer.env?.["SLACK_ALLOWED_USERS"]);
|
|
15582
|
+
}
|
|
15583
|
+
|
|
15571
15584
|
// src/slack-response-mode.ts
|
|
15572
15585
|
var MODES = [
|
|
15573
15586
|
"mention_only",
|
|
@@ -16306,9 +16319,7 @@ async function maybeSendSenderPolicyDecline(args) {
|
|
|
16306
16319
|
var BLOCK_KIT_ENABLED = process.env.SLACK_BLOCK_KIT_ENABLED === "true";
|
|
16307
16320
|
var BLOCK_KIT_ASK_USER_ENABLED = process.env.SLACK_BLOCK_KIT_ASK_USER_ENABLED === "true";
|
|
16308
16321
|
var BLOCK_KIT_DISABLED = process.env.SLACK_BLOCK_KIT_DISABLED === "true";
|
|
16309
|
-
var ALLOWED_USERS =
|
|
16310
|
-
(process.env.SLACK_ALLOWED_USERS ?? "").split(",").map((s) => s.trim()).filter(Boolean)
|
|
16311
|
-
);
|
|
16322
|
+
var ALLOWED_USERS = parseAllowedUsersCsv(process.env.SLACK_ALLOWED_USERS);
|
|
16312
16323
|
var THREAD_AUTO_FOLLOW = process.env.SLACK_THREAD_AUTO_FOLLOW ?? "off";
|
|
16313
16324
|
var CHANNEL_RESPONSE_MODE = parseResponseMode(process.env.SLACK_CHANNEL_RESPONSE_MODE);
|
|
16314
16325
|
var SLACK_PEER_DISABLED_MODE = (() => {
|
|
@@ -16355,6 +16366,28 @@ var SLACK_PEER_CLASSIFIER_CONFIG = {
|
|
|
16355
16366
|
peer_disabled_mode: SLACK_PEER_DISABLED_MODE
|
|
16356
16367
|
};
|
|
16357
16368
|
var SLACK_AGENT_DIR = AGENT_CODE_NAME ? join6(homedir2(), ".augmented", AGENT_CODE_NAME) : null;
|
|
16369
|
+
var SLACK_MCP_CONFIG_PATH = SLACK_AGENT_DIR ? join6(SLACK_AGENT_DIR, "project", ".mcp.json") : null;
|
|
16370
|
+
var liveAllowedUsersCache = null;
|
|
16371
|
+
function readLiveAllowedUsers() {
|
|
16372
|
+
if (!SLACK_MCP_CONFIG_PATH) return null;
|
|
16373
|
+
try {
|
|
16374
|
+
const mtimeMs = statSync2(SLACK_MCP_CONFIG_PATH).mtimeMs;
|
|
16375
|
+
if (liveAllowedUsersCache && liveAllowedUsersCache.mtimeMs === mtimeMs) {
|
|
16376
|
+
return liveAllowedUsersCache.value;
|
|
16377
|
+
}
|
|
16378
|
+
const value = extractAllowedUsersFromMcpJson(
|
|
16379
|
+
readFileSync7(SLACK_MCP_CONFIG_PATH, "utf-8")
|
|
16380
|
+
);
|
|
16381
|
+
if (value === null) return null;
|
|
16382
|
+
liveAllowedUsersCache = { mtimeMs, value };
|
|
16383
|
+
return value;
|
|
16384
|
+
} catch {
|
|
16385
|
+
return null;
|
|
16386
|
+
}
|
|
16387
|
+
}
|
|
16388
|
+
function getEffectiveAllowedUsers() {
|
|
16389
|
+
return readLiveAllowedUsers() ?? ALLOWED_USERS;
|
|
16390
|
+
}
|
|
16358
16391
|
var SLACK_PENDING_INBOUND_DIR = SLACK_AGENT_DIR ? join6(SLACK_AGENT_DIR, "slack-pending-inbound") : null;
|
|
16359
16392
|
var SLACK_RECOVERY_OUTBOX_DIR = SLACK_AGENT_DIR ? join6(SLACK_AGENT_DIR, "slack-recovery-outbox") : null;
|
|
16360
16393
|
var SLACK_RESTART_CONFIRM_FILE = SLACK_AGENT_DIR ? join6(SLACK_AGENT_DIR, "slack-restart-confirm.json") : null;
|
|
@@ -17298,7 +17331,7 @@ async function handleDebugSlashCommand(payload, responseUrl) {
|
|
|
17298
17331
|
const verdict = evaluateDebugGate({
|
|
17299
17332
|
channelId: payload.channel_id,
|
|
17300
17333
|
userId: payload.user_id,
|
|
17301
|
-
allowedUsers:
|
|
17334
|
+
allowedUsers: getEffectiveAllowedUsers()
|
|
17302
17335
|
});
|
|
17303
17336
|
const investigateCmd = agentSlashCommand("/investigate");
|
|
17304
17337
|
if (!verdict.ok) {
|
|
@@ -17400,7 +17433,8 @@ async function handleSlashCommandEnvelope(payload) {
|
|
|
17400
17433
|
return;
|
|
17401
17434
|
}
|
|
17402
17435
|
if (matchesAgentCommand(command, "/restart")) {
|
|
17403
|
-
|
|
17436
|
+
const restartAllowedUsers = getEffectiveAllowedUsers();
|
|
17437
|
+
if (restartAllowedUsers.size > 0 && (!payload.user_id || !restartAllowedUsers.has(payload.user_id))) {
|
|
17404
17438
|
process.stderr.write(
|
|
17405
17439
|
`slack-channel(${codeName}): /restart slash-command denied \u2014 user not in SLACK_ALLOWED_USERS
|
|
17406
17440
|
`
|
|
@@ -19085,7 +19119,7 @@ async function connectSocketMode() {
|
|
|
19085
19119
|
return;
|
|
19086
19120
|
}
|
|
19087
19121
|
if (isRestartCommand) {
|
|
19088
|
-
const senderAllowed = isRestartSenderAllowed(
|
|
19122
|
+
const senderAllowed = isRestartSenderAllowed(getEffectiveAllowedUsers(), evt.user);
|
|
19089
19123
|
if (!senderAllowed) {
|
|
19090
19124
|
await denyUnauthorizedRestart({
|
|
19091
19125
|
channel: evt.channel ?? "",
|
|
@@ -25,8 +25,8 @@ import {
|
|
|
25
25
|
takeAcpxExecFailureCount,
|
|
26
26
|
takeZombieDetection,
|
|
27
27
|
writePersistentClaudeWrapper
|
|
28
|
-
} from "./chunk-
|
|
29
|
-
import "./chunk-
|
|
28
|
+
} from "./chunk-7GKJZBTB.js";
|
|
29
|
+
import "./chunk-WOOYOAPG.js";
|
|
30
30
|
import "./chunk-354FAVQR.js";
|
|
31
31
|
import "./chunk-XWVM4KPK.js";
|
|
32
32
|
export {
|
|
@@ -57,4 +57,4 @@ export {
|
|
|
57
57
|
takeZombieDetection,
|
|
58
58
|
writePersistentClaudeWrapper
|
|
59
59
|
};
|
|
60
|
-
//# sourceMappingURL=persistent-session-
|
|
60
|
+
//# sourceMappingURL=persistent-session-35PWSTLO.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
paneLogPath
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-7GKJZBTB.js";
|
|
4
|
+
import "./chunk-WOOYOAPG.js";
|
|
5
5
|
import "./chunk-354FAVQR.js";
|
|
6
6
|
import "./chunk-XWVM4KPK.js";
|
|
7
7
|
|
|
@@ -155,4 +155,4 @@ export {
|
|
|
155
155
|
livePendingInboundOldestAgeSeconds,
|
|
156
156
|
oldestLivePendingInboundMtimeMs
|
|
157
157
|
};
|
|
158
|
-
//# sourceMappingURL=responsiveness-probe-
|
|
158
|
+
//# sourceMappingURL=responsiveness-probe-MA4M2QM4.js.map
|