@akasecurity/ai-tc-claude-code 0.9.0 → 0.9.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/.claude-plugin/plugin.json +1 -1
- package/README.md +3 -1
- package/commands/setup.md +112 -29
- package/package.json +4 -4
- package/scripts/apply-suppressions.js +4607 -848
- package/scripts/backfill.js +2346 -639
- package/scripts/filescan.js +3554 -756
- package/scripts/firstrun.js +2132 -583
- package/scripts/intro.js +908 -168
- package/scripts/onboard.js +2140 -582
- package/scripts/post-tool-use.js +2344 -628
- package/scripts/pre-tool-use.js +2349 -633
- package/scripts/query.js +2133 -584
- package/scripts/reconcile.js +2158 -603
- package/scripts/remediate.js +2341 -640
- package/scripts/session-start.js +2216 -657
- package/scripts/start-light.js +911 -171
- package/scripts/statusline.js +2146 -587
- package/scripts/stop.js +965 -188
- package/scripts/triage-rubric.md +4 -3
- package/scripts/user-prompt-submit.js +2352 -636
package/scripts/stop.js
CHANGED
|
@@ -491,9 +491,13 @@ var require_ignore = __commonJS({
|
|
|
491
491
|
}
|
|
492
492
|
});
|
|
493
493
|
|
|
494
|
+
// ../../packages/plugin-sdk/src/config.ts
|
|
495
|
+
import { existsSync as existsSync3 } from "fs";
|
|
496
|
+
import { join as join6 } from "path";
|
|
497
|
+
|
|
494
498
|
// ../../packages/persistence/src/database.ts
|
|
495
499
|
import { randomUUID as randomUUID8 } from "crypto";
|
|
496
|
-
import { existsSync, renameSync, rmSync } from "fs";
|
|
500
|
+
import { existsSync, renameSync as renameSync2, rmSync as rmSync2 } from "fs";
|
|
497
501
|
import { join, sep } from "path";
|
|
498
502
|
import { DatabaseSync } from "node:sqlite";
|
|
499
503
|
|
|
@@ -15182,7 +15186,12 @@ var FindingFacets = external_exports.object({
|
|
|
15182
15186
|
severity: external_exports.array(FindingFacetItem),
|
|
15183
15187
|
subtype: external_exports.array(FindingFacetItem),
|
|
15184
15188
|
provider: external_exports.array(FindingFacetItem),
|
|
15185
|
-
action: external_exports.array(FindingFacetItem)
|
|
15189
|
+
action: external_exports.array(FindingFacetItem),
|
|
15190
|
+
// Counts by the group's derived status. The SQLite store derives a status
|
|
15191
|
+
// for every instance, so every group lands in a bucket; a status-less
|
|
15192
|
+
// group (possible only for callers whose rows carry no statuses) is
|
|
15193
|
+
// counted under no value.
|
|
15194
|
+
status: external_exports.array(FindingFacetItem)
|
|
15186
15195
|
}).meta({ id: "FindingFacets" });
|
|
15187
15196
|
var ListGroupedFindingsQuery = external_exports.object({
|
|
15188
15197
|
// NOTE: severity filters by Severity (critical/high/medium/low), not by
|
|
@@ -15191,6 +15200,10 @@ var ListGroupedFindingsQuery = external_exports.object({
|
|
|
15191
15200
|
subtype: external_exports.array(external_exports.string()).optional(),
|
|
15192
15201
|
provider: external_exports.array(FindingProvider).optional(),
|
|
15193
15202
|
action: external_exports.array(FindingAction).optional(),
|
|
15203
|
+
// Matches a group's DERIVED status (see FindingGroup.status), not its
|
|
15204
|
+
// individual instances' — so a filtered group's Status column always reads
|
|
15205
|
+
// one of the requested values.
|
|
15206
|
+
status: external_exports.array(FindingStatus).optional(),
|
|
15194
15207
|
q: external_exports.string().optional(),
|
|
15195
15208
|
// Scope to findings whose event carries this session id (the Activity page's
|
|
15196
15209
|
// session → findings drilldown). Findings without a session never match.
|
|
@@ -15371,6 +15384,33 @@ var ToolCallAttributes = external_exports.object({
|
|
|
15371
15384
|
parent_uuid: external_exports.string().optional(),
|
|
15372
15385
|
run_key: external_exports.string().optional()
|
|
15373
15386
|
}).catchall(external_exports.unknown());
|
|
15387
|
+
var CaptureAttributes = external_exports.object({
|
|
15388
|
+
// The harness/tool that produced the capture (`claude-code`, `cli`, …). A
|
|
15389
|
+
// column on the legacy `events` table; here it rides the bag because a
|
|
15390
|
+
// capture-typed audit row has no equivalent column of its own.
|
|
15391
|
+
source_tool: external_exports.string().optional(),
|
|
15392
|
+
file_path: external_exports.string().optional(),
|
|
15393
|
+
repo: external_exports.string().optional(),
|
|
15394
|
+
// The host tool whose input/output was scanned (e.g. 'Bash', 'WebFetch') —
|
|
15395
|
+
// gives a non-file capture a display location ("via Bash") when file_path
|
|
15396
|
+
// is absent. The tool NAME only, never its arguments/output.
|
|
15397
|
+
tool_name: external_exports.string().optional(),
|
|
15398
|
+
// Presence-only provenance flag: set when the file is excluded by the
|
|
15399
|
+
// repo's .gitignore. Omitted (not false) for tracked files.
|
|
15400
|
+
gitignored: external_exports.boolean().optional(),
|
|
15401
|
+
// Set ONLY when the capture is a COMPLETE file snapshot (a worktree scan
|
|
15402
|
+
// reading from disk), never a partial fragment (a hook-captured edit).
|
|
15403
|
+
whole_file: external_exports.boolean().optional(),
|
|
15404
|
+
// Distributed-tracing correlation: `correlation_id` ties the capture back to
|
|
15405
|
+
// the request that produced it; `trace_id` is the originating span's W3C
|
|
15406
|
+
// trace id when telemetry is enabled.
|
|
15407
|
+
correlation_id: external_exports.uuid().optional(),
|
|
15408
|
+
trace_id: external_exports.string().regex(/^[0-9a-f]{32}$/).optional(),
|
|
15409
|
+
// Ids of the detection exceptions that downgraded findings in this capture
|
|
15410
|
+
// to 'allow' — the enforcement audit trail's link back to the grant that
|
|
15411
|
+
// authorized the bypass.
|
|
15412
|
+
exception_ids: external_exports.array(external_exports.guid()).optional()
|
|
15413
|
+
}).catchall(external_exports.unknown());
|
|
15374
15414
|
var ToolCallInspection = external_exports.object({
|
|
15375
15415
|
ruleId: external_exports.string().min(1),
|
|
15376
15416
|
ruleName: external_exports.string(),
|
|
@@ -15457,7 +15497,18 @@ var InspectionFindingInput = external_exports.object({
|
|
|
15457
15497
|
span: Span,
|
|
15458
15498
|
maskedMatch: external_exports.string(),
|
|
15459
15499
|
actionTaken: ActionTaken,
|
|
15460
|
-
confidence: external_exports.number().min(0).max(1)
|
|
15500
|
+
confidence: external_exports.number().min(0).max(1),
|
|
15501
|
+
// Stable, content-addressed key correlating this finding across re-detections
|
|
15502
|
+
// — mirrors the legacy `findings.finding_key` (uq_inspection_findings_key is
|
|
15503
|
+
// its unique index). Optional: only an at-rest/re-scannable finding carries
|
|
15504
|
+
// one; an in-flight capture (prompt/response) has nothing to re-detect
|
|
15505
|
+
// against and leaves it unset, so every insert is a fresh row.
|
|
15506
|
+
findingKey: external_exports.string().optional(),
|
|
15507
|
+
// The ORIGINAL detection time, preserved across a later re-detection of the
|
|
15508
|
+
// same findingKey — mirrors the legacy `findings.first_detected_at`.
|
|
15509
|
+
// Optional: when omitted, the writer derives it from the referenced audit
|
|
15510
|
+
// event's startedAt on first insert (see SqliteInspectionFindingsRepository).
|
|
15511
|
+
firstDetectedAt: external_exports.iso.datetime().optional()
|
|
15461
15512
|
});
|
|
15462
15513
|
var InventoryContext = external_exports.object({
|
|
15463
15514
|
host: InventoryInput.optional(),
|
|
@@ -15656,6 +15707,7 @@ var ActivityOverviewResponse = external_exports.object({
|
|
|
15656
15707
|
|
|
15657
15708
|
// ../../packages/schema/src/zod/event.ts
|
|
15658
15709
|
var EventKind = external_exports.enum(["prompt", "response", "code_change", "tool_use"]).meta({ id: "EventKind" });
|
|
15710
|
+
var CAPTURE_EVENT_TYPES_SQL = EventKind.options.map((k) => `'${k}'`).join(",");
|
|
15659
15711
|
var SourceTool = external_exports.enum(["claude-code", "claude-desktop", "cursor", "chatgpt", "github-copilot", "cli", "unknown"]).meta({ id: "SourceTool" });
|
|
15660
15712
|
var EventMetadata = external_exports.object({
|
|
15661
15713
|
sessionId: external_exports.string().optional(),
|
|
@@ -15996,6 +16048,7 @@ var ExceptionBundleEntry = DetectionException.pick({
|
|
|
15996
16048
|
|
|
15997
16049
|
// ../../packages/schema/src/zod/rule.ts
|
|
15998
16050
|
var MatcherType = external_exports.enum(["keyword", "regex", "validator"]).meta({ id: "MatcherType" });
|
|
16051
|
+
var RuleProbeVerdict = external_exports.enum(["safe", "quarantined"]).meta({ id: "RuleProbeVerdict" });
|
|
15999
16052
|
var KeywordMatcher = external_exports.object({
|
|
16000
16053
|
type: external_exports.literal("keyword"),
|
|
16001
16054
|
// An empty keyword matches at every position, yielding one zero-length span
|
|
@@ -16020,9 +16073,10 @@ function matchesEmptyString(pattern, flags) {
|
|
|
16020
16073
|
return false;
|
|
16021
16074
|
}
|
|
16022
16075
|
}
|
|
16076
|
+
var MAX_PATTERN_LENGTH = 2e3;
|
|
16023
16077
|
var RegexMatcher = external_exports.object({
|
|
16024
16078
|
type: external_exports.literal("regex"),
|
|
16025
|
-
pattern: external_exports.string(),
|
|
16079
|
+
pattern: external_exports.string().min(1).max(MAX_PATTERN_LENGTH),
|
|
16026
16080
|
flags: external_exports.string().default("gi"),
|
|
16027
16081
|
captureGroup: external_exports.number().int().nonnegative().optional()
|
|
16028
16082
|
}).refine((v) => isValidRegex(v.pattern, v.flags), {
|
|
@@ -16143,6 +16197,12 @@ var PolicyBundle = external_exports.object({
|
|
|
16143
16197
|
// on-disk caches — that omit the field still parse; consumers read
|
|
16144
16198
|
// `bundle.exceptions ?? []`.
|
|
16145
16199
|
exceptions: external_exports.array(ExceptionBundleEntry).optional(),
|
|
16200
|
+
// Installed pack version, keyed by ruleId, for rules in `rules` that came
|
|
16201
|
+
// from a versioned installed pack. Optional so older backends — and older
|
|
16202
|
+
// on-disk caches — that omit the field still parse; consumers fall back to
|
|
16203
|
+
// the rule's own spec version. NOT the bundle version above — see
|
|
16204
|
+
// installedRuleset's ruleVersions for the source of truth.
|
|
16205
|
+
ruleVersions: external_exports.record(external_exports.string(), external_exports.string()).optional(),
|
|
16146
16206
|
customKeywords: external_exports.array(external_exports.string()),
|
|
16147
16207
|
fetchedAt: external_exports.iso.datetime()
|
|
16148
16208
|
}).meta({ id: "PolicyBundle" });
|
|
@@ -16504,6 +16564,212 @@ var ImportDetectionRequest = external_exports.object({
|
|
|
16504
16564
|
})
|
|
16505
16565
|
}).meta({ id: "ImportDetectionRequest" });
|
|
16506
16566
|
|
|
16567
|
+
// ../../packages/schema/src/zod/shares.ts
|
|
16568
|
+
var DestinationKind = external_exports.enum(["provider", "internal", "external", "ip"]).meta({ id: "DestinationKind" });
|
|
16569
|
+
var Transport = external_exports.enum(["https", "http", "sftp", "grpc", "smtp", "ws", "wss"]).meta({ id: "Transport" });
|
|
16570
|
+
var DataClass = external_exports.enum(["secrets", "pii", "customer", "source", "telemetry", "logs", "metrics", "none"]).meta({ id: "DataClass" });
|
|
16571
|
+
var DATA_CLASS_ORDER = DataClass.options;
|
|
16572
|
+
var ShareTrustLevel = external_exports.enum(["recognized", "internal", "unverified", "ip"]).meta({ id: "ShareTrustLevel" });
|
|
16573
|
+
var EgressDecision = external_exports.enum(["allow", "block"]).meta({ id: "EgressDecision" });
|
|
16574
|
+
var EgressStatus = external_exports.enum(["allowed", "blocked", "review"]).meta({ id: "EgressStatus" });
|
|
16575
|
+
var ReviewReason = external_exports.enum(["raw_ip", "unverified_domain", "plaintext_transport"]).meta({ id: "ReviewReason" });
|
|
16576
|
+
var HttpMethod = external_exports.enum(["GET", "POST", "PUT", "DELETE", "SDK", "REF"]).meta({ id: "HttpMethod" });
|
|
16577
|
+
var ReviewInfo = external_exports.object({
|
|
16578
|
+
needsReview: external_exports.boolean(),
|
|
16579
|
+
reasons: external_exports.array(ReviewReason)
|
|
16580
|
+
}).meta({ id: "ReviewInfo" });
|
|
16581
|
+
var DestinationNetwork = external_exports.object({
|
|
16582
|
+
port: external_exports.number().int().nullable(),
|
|
16583
|
+
geo: external_exports.string().nullable(),
|
|
16584
|
+
ptr: external_exports.string().nullable()
|
|
16585
|
+
}).meta({ id: "DestinationNetwork" });
|
|
16586
|
+
var EndpointSummary = external_exports.object({
|
|
16587
|
+
id: external_exports.string(),
|
|
16588
|
+
method: HttpMethod,
|
|
16589
|
+
transport: Transport,
|
|
16590
|
+
url: external_exports.string(),
|
|
16591
|
+
template: external_exports.boolean(),
|
|
16592
|
+
dataClass: DataClass,
|
|
16593
|
+
lastSeen: external_exports.iso.datetime(),
|
|
16594
|
+
callSiteCount: external_exports.number().int().nonnegative()
|
|
16595
|
+
}).meta({ id: "EndpointSummary" });
|
|
16596
|
+
var CallSite = external_exports.object({
|
|
16597
|
+
id: external_exports.string(),
|
|
16598
|
+
project: external_exports.string(),
|
|
16599
|
+
file: external_exports.string(),
|
|
16600
|
+
line: external_exports.number().int().nonnegative(),
|
|
16601
|
+
snippet: external_exports.string(),
|
|
16602
|
+
dynamic: external_exports.boolean(),
|
|
16603
|
+
vendored: external_exports.boolean(),
|
|
16604
|
+
/** Deep-link to the Inventory project, when the repo is governed there. */
|
|
16605
|
+
projectId: external_exports.string().nullable()
|
|
16606
|
+
}).meta({ id: "CallSite" });
|
|
16607
|
+
var EndpointWithSites = EndpointSummary.extend({
|
|
16608
|
+
sites: external_exports.array(CallSite)
|
|
16609
|
+
}).meta({ id: "EndpointWithSites" });
|
|
16610
|
+
var ShareDestinationSummary = external_exports.object({
|
|
16611
|
+
id: external_exports.string(),
|
|
16612
|
+
kind: DestinationKind,
|
|
16613
|
+
name: external_exports.string(),
|
|
16614
|
+
host: external_exports.string(),
|
|
16615
|
+
category: external_exports.string(),
|
|
16616
|
+
trust: ShareTrustLevel,
|
|
16617
|
+
/** Effective state (decision applied over the trust default). */
|
|
16618
|
+
status: EgressStatus,
|
|
16619
|
+
/** True when an egress decision override differs from the trust default. */
|
|
16620
|
+
isCustom: external_exports.boolean(),
|
|
16621
|
+
lastSeen: external_exports.iso.datetime(),
|
|
16622
|
+
endpointCount: external_exports.number().int().nonnegative(),
|
|
16623
|
+
callSiteCount: external_exports.number().int().nonnegative(),
|
|
16624
|
+
transports: external_exports.array(Transport),
|
|
16625
|
+
/** Most-sensitive first. */
|
|
16626
|
+
dataClasses: external_exports.array(DataClass),
|
|
16627
|
+
review: ReviewInfo,
|
|
16628
|
+
/** Non-provider hosts only; null for providers. */
|
|
16629
|
+
network: DestinationNetwork.nullable(),
|
|
16630
|
+
/** Embedded for inline expansion — no call sites here. */
|
|
16631
|
+
endpoints: external_exports.array(EndpointSummary)
|
|
16632
|
+
}).meta({ id: "ShareDestinationSummary" });
|
|
16633
|
+
var ShareDestinationDetail = ShareDestinationSummary.omit({
|
|
16634
|
+
endpointCount: true,
|
|
16635
|
+
callSiteCount: true,
|
|
16636
|
+
endpoints: true
|
|
16637
|
+
}).extend({
|
|
16638
|
+
/** Ownership/geo rationale; null for providers. */
|
|
16639
|
+
note: external_exports.string().nullable(),
|
|
16640
|
+
endpoints: external_exports.array(EndpointWithSites)
|
|
16641
|
+
}).meta({ id: "ShareDestinationDetail" });
|
|
16642
|
+
var ReviewDestination = external_exports.object({
|
|
16643
|
+
id: external_exports.string(),
|
|
16644
|
+
kind: DestinationKind,
|
|
16645
|
+
name: external_exports.string(),
|
|
16646
|
+
/** Registrable host — lets the strip derive the provider lettermark, as the register does. */
|
|
16647
|
+
host: external_exports.string(),
|
|
16648
|
+
trust: ShareTrustLevel,
|
|
16649
|
+
status: EgressStatus,
|
|
16650
|
+
review: ReviewInfo,
|
|
16651
|
+
topDataClass: DataClass,
|
|
16652
|
+
callSiteCount: external_exports.number().int().nonnegative(),
|
|
16653
|
+
lastSeen: external_exports.iso.datetime()
|
|
16654
|
+
}).meta({ id: "ReviewDestination" });
|
|
16655
|
+
var ShareDestinationGroup = external_exports.object({
|
|
16656
|
+
kind: DestinationKind,
|
|
16657
|
+
total: external_exports.number().int().nonnegative(),
|
|
16658
|
+
items: external_exports.array(ShareDestinationSummary)
|
|
16659
|
+
}).meta({ id: "ShareDestinationGroup" });
|
|
16660
|
+
var ListShareDestinationsResponse = external_exports.object({ groups: external_exports.array(ShareDestinationGroup) }).meta({ id: "ListShareDestinationsResponse" });
|
|
16661
|
+
var NeedsReviewResponse = external_exports.object({ items: external_exports.array(ReviewDestination) }).meta({ id: "NeedsReviewResponse" });
|
|
16662
|
+
var SharesStats = external_exports.object({
|
|
16663
|
+
destinations: external_exports.number().int().nonnegative(),
|
|
16664
|
+
endpoints: external_exports.number().int().nonnegative(),
|
|
16665
|
+
callSites: external_exports.number().int().nonnegative(),
|
|
16666
|
+
needsReview: external_exports.number().int().nonnegative(),
|
|
16667
|
+
insecure: external_exports.number().int().nonnegative(),
|
|
16668
|
+
byKind: external_exports.object({
|
|
16669
|
+
provider: external_exports.number().int().nonnegative(),
|
|
16670
|
+
internal: external_exports.number().int().nonnegative(),
|
|
16671
|
+
external: external_exports.number().int().nonnegative(),
|
|
16672
|
+
ip: external_exports.number().int().nonnegative()
|
|
16673
|
+
}),
|
|
16674
|
+
byTrust: external_exports.object({
|
|
16675
|
+
recognized: external_exports.number().int().nonnegative(),
|
|
16676
|
+
internal: external_exports.number().int().nonnegative(),
|
|
16677
|
+
unverified: external_exports.number().int().nonnegative(),
|
|
16678
|
+
ip: external_exports.number().int().nonnegative()
|
|
16679
|
+
})
|
|
16680
|
+
}).meta({ id: "SharesStats" });
|
|
16681
|
+
var SetEgressDecisionBody = external_exports.object({
|
|
16682
|
+
/** `null` clears the override — reverts to the trust default, isCustom false. */
|
|
16683
|
+
decision: EgressDecision.nullable()
|
|
16684
|
+
}).meta({ id: "SetEgressDecisionBody" });
|
|
16685
|
+
var SetEgressDecisionResponse = external_exports.object({ destination: ShareDestinationSummary }).meta({ id: "SetEgressDecisionResponse" });
|
|
16686
|
+
var ListShareDestinationsQuery = external_exports.object({
|
|
16687
|
+
/** Case-insensitive match over destination name/category, endpoint url, call-site project/file. */
|
|
16688
|
+
q: external_exports.string().optional(),
|
|
16689
|
+
/** Repeatable. Restrict to these DestinationKind values; absent means all kinds. */
|
|
16690
|
+
kind: external_exports.array(DestinationKind).optional(),
|
|
16691
|
+
/** Reserved for future grouping modes; only 'destination' is supported today. */
|
|
16692
|
+
groupBy: external_exports.enum(["destination"]).default("destination"),
|
|
16693
|
+
/**
|
|
16694
|
+
* When true, return a flat severity-ordered `items[]` instead of `groups`.
|
|
16695
|
+
* Uses `z.stringbool()` (NOT `z.coerce.boolean()` — `Boolean(str)` is true for
|
|
16696
|
+
* any non-empty string, so `?review=false`/`?review=0` would wrongly coerce
|
|
16697
|
+
* to `true`). `z.stringbool()` parses true/1/yes vs false/0/no correctly.
|
|
16698
|
+
*/
|
|
16699
|
+
review: external_exports.stringbool().default(false)
|
|
16700
|
+
});
|
|
16701
|
+
var ExportSharesQuery = external_exports.object({
|
|
16702
|
+
format: external_exports.enum(["csv", "json"]).default("csv"),
|
|
16703
|
+
q: external_exports.string().optional(),
|
|
16704
|
+
kind: external_exports.array(DestinationKind).optional()
|
|
16705
|
+
});
|
|
16706
|
+
|
|
16707
|
+
// ../../packages/schema/src/zod/egress-extraction.ts
|
|
16708
|
+
var EgressEcosystem = external_exports.enum(["npm", "pypi", "go", "maven", "rubygems", "cargo", "composer", "nuget"]).meta({ id: "EgressEcosystem" });
|
|
16709
|
+
var ProviderRegistryEntry = external_exports.object({
|
|
16710
|
+
id: external_exports.string(),
|
|
16711
|
+
name: external_exports.string(),
|
|
16712
|
+
category: external_exports.string(),
|
|
16713
|
+
/** Suffix-matched: 'stripe.com' matches api.stripe.com, never evilstripe.com. */
|
|
16714
|
+
hostSuffixes: external_exports.array(external_exports.string()).min(1),
|
|
16715
|
+
/** Canonical API base URL recorded for manifest-derived (method 'SDK') endpoints. */
|
|
16716
|
+
apiBase: external_exports.string(),
|
|
16717
|
+
/** Most-sensitive first; index 0 becomes the endpoint dataClass. */
|
|
16718
|
+
defaultDataClasses: external_exports.array(DataClass).min(1),
|
|
16719
|
+
/** SDK identifiers per ecosystem ('go' prefix-matched by path, 'maven' by group-id prefix). */
|
|
16720
|
+
sdks: external_exports.partialRecord(EgressEcosystem, external_exports.array(external_exports.string()))
|
|
16721
|
+
}).meta({ id: "ProviderRegistryEntry" });
|
|
16722
|
+
var EgressCallSiteHit = external_exports.object({
|
|
16723
|
+
file: external_exports.string(),
|
|
16724
|
+
line: external_exports.number().int().positive(),
|
|
16725
|
+
snippet: external_exports.string(),
|
|
16726
|
+
dynamic: external_exports.boolean(),
|
|
16727
|
+
vendored: external_exports.boolean()
|
|
16728
|
+
}).meta({ id: "EgressCallSiteHit" });
|
|
16729
|
+
var ResolvedEgressHit = external_exports.object({
|
|
16730
|
+
host: external_exports.string(),
|
|
16731
|
+
kind: DestinationKind,
|
|
16732
|
+
name: external_exports.string(),
|
|
16733
|
+
category: external_exports.string(),
|
|
16734
|
+
trust: ShareTrustLevel,
|
|
16735
|
+
network: DestinationNetwork.nullable(),
|
|
16736
|
+
method: HttpMethod,
|
|
16737
|
+
transport: Transport,
|
|
16738
|
+
url: external_exports.string(),
|
|
16739
|
+
template: external_exports.boolean(),
|
|
16740
|
+
dataClass: DataClass,
|
|
16741
|
+
site: EgressCallSiteHit
|
|
16742
|
+
}).meta({ id: "ResolvedEgressHit" });
|
|
16743
|
+
var EgressReconcile = external_exports.discriminatedUnion("mode", [
|
|
16744
|
+
external_exports.object({ mode: external_exports.literal("walk"), walkedPrefix: external_exports.string() }),
|
|
16745
|
+
external_exports.object({
|
|
16746
|
+
mode: external_exports.literal("ledger"),
|
|
16747
|
+
scannedFiles: external_exports.array(external_exports.string()),
|
|
16748
|
+
deletedFiles: external_exports.array(external_exports.string())
|
|
16749
|
+
})
|
|
16750
|
+
]).meta({ id: "EgressReconcile" });
|
|
16751
|
+
var RecordProjectEgressInput = external_exports.object({
|
|
16752
|
+
/** Stable reconcile key: 'git:<repo identity>' or 'path:<abs root>' (non-git). */
|
|
16753
|
+
projectKey: external_exports.string().min(1),
|
|
16754
|
+
/** Display name only — never keys reconciliation. */
|
|
16755
|
+
project: external_exports.string(),
|
|
16756
|
+
projectId: external_exports.string().nullable(),
|
|
16757
|
+
reconcile: EgressReconcile,
|
|
16758
|
+
hits: external_exports.array(ResolvedEgressHit)
|
|
16759
|
+
}).meta({ id: "RecordProjectEgressInput" });
|
|
16760
|
+
var EgressWriteSummary = external_exports.object({
|
|
16761
|
+
destinations: external_exports.number().int().nonnegative(),
|
|
16762
|
+
endpoints: external_exports.number().int().nonnegative(),
|
|
16763
|
+
callSites: external_exports.number().int().nonnegative(),
|
|
16764
|
+
truncated: external_exports.boolean(),
|
|
16765
|
+
/**
|
|
16766
|
+
* Files the cap dropped whole. Their stored rows were left untouched, so a
|
|
16767
|
+
* ledger-keeping caller must withhold their ledger entries and read them
|
|
16768
|
+
* again next scan.
|
|
16769
|
+
*/
|
|
16770
|
+
droppedFiles: external_exports.array(external_exports.string()).default([])
|
|
16771
|
+
}).meta({ id: "EgressWriteSummary" });
|
|
16772
|
+
|
|
16507
16773
|
// ../../packages/schema/src/zod/installed-pack.ts
|
|
16508
16774
|
var InstalledPack = external_exports.object({
|
|
16509
16775
|
id: external_exports.guid(),
|
|
@@ -16535,10 +16801,14 @@ var PatchInstalledPackRequest = external_exports.object({
|
|
|
16535
16801
|
}).meta({ id: "PatchInstalledPackRequest" });
|
|
16536
16802
|
|
|
16537
16803
|
// ../../packages/schema/src/zod/local.ts
|
|
16538
|
-
var WORKSPACE_SETTINGS_SPEC_VERSION =
|
|
16804
|
+
var WORKSPACE_SETTINGS_SPEC_VERSION = 4;
|
|
16539
16805
|
var RunMode = external_exports.enum(["standalone"]);
|
|
16540
16806
|
var SimpleDetectionPolicy = external_exports.enum(["redact", "warn"]);
|
|
16541
16807
|
var HistoricalAccess = external_exports.enum(["full", "session-only"]);
|
|
16808
|
+
var ModelJudgeConsent = external_exports.object({
|
|
16809
|
+
acknowledgedAt: external_exports.iso.datetime(),
|
|
16810
|
+
payloadVersion: external_exports.number().int().positive()
|
|
16811
|
+
});
|
|
16542
16812
|
var WorkspaceSettings = external_exports.object({
|
|
16543
16813
|
specVersion: external_exports.number().int().positive().default(WORKSPACE_SETTINGS_SPEC_VERSION),
|
|
16544
16814
|
// Settings files written by earlier releases may carry the retired 'attached'
|
|
@@ -16550,8 +16820,16 @@ var WorkspaceSettings = external_exports.object({
|
|
|
16550
16820
|
policy: SimpleDetectionPolicy.default("redact"),
|
|
16551
16821
|
// Consent for scanning pre-install surfaces; opt-in (see HistoricalAccess).
|
|
16552
16822
|
historicalAccess: HistoricalAccess.default("session-only"),
|
|
16823
|
+
// In-place egress extraction on the scan paths; disable to stop all Data
|
|
16824
|
+
// Shares writes.
|
|
16825
|
+
dataSharesInPlace: external_exports.boolean().default(true),
|
|
16553
16826
|
// Absent until /aka:setup completes; its presence is what "onboarded" means.
|
|
16554
|
-
onboardedAt: external_exports.iso.datetime().optional()
|
|
16827
|
+
onboardedAt: external_exports.iso.datetime().optional(),
|
|
16828
|
+
// Records that the user consented to sending findings to the model API for
|
|
16829
|
+
// the /aka:setup judge, along with the payload-shape version they agreed to.
|
|
16830
|
+
// Absent until granted; a stale payloadVersion means the consent no longer
|
|
16831
|
+
// covers the current payload and must be re-granted.
|
|
16832
|
+
modelJudgeConsent: ModelJudgeConsent.optional()
|
|
16555
16833
|
});
|
|
16556
16834
|
function defaultWorkspaceSettings() {
|
|
16557
16835
|
return WorkspaceSettings.parse({});
|
|
@@ -16929,152 +17207,33 @@ var SetupHandoffOffer = external_exports.object({
|
|
|
16929
17207
|
path: ["liveKeys"]
|
|
16930
17208
|
});
|
|
16931
17209
|
|
|
16932
|
-
// ../../packages/schema/src/zod/shares.ts
|
|
16933
|
-
var DestinationKind = external_exports.enum(["provider", "internal", "ip"]).meta({ id: "DestinationKind" });
|
|
16934
|
-
var Transport = external_exports.enum(["https", "http", "sftp", "grpc", "smtp"]).meta({ id: "Transport" });
|
|
16935
|
-
var DataClass = external_exports.enum(["secrets", "pii", "customer", "source", "telemetry", "logs", "metrics", "none"]).meta({ id: "DataClass" });
|
|
16936
|
-
var DATA_CLASS_ORDER = DataClass.options;
|
|
16937
|
-
var ShareTrustLevel = external_exports.enum(["recognized", "internal", "unverified", "ip"]).meta({ id: "ShareTrustLevel" });
|
|
16938
|
-
var EgressDecision = external_exports.enum(["allow", "block"]).meta({ id: "EgressDecision" });
|
|
16939
|
-
var EgressStatus = external_exports.enum(["allowed", "blocked", "review"]).meta({ id: "EgressStatus" });
|
|
16940
|
-
var ReviewReason = external_exports.enum(["raw_ip", "unverified_domain", "plaintext_transport"]).meta({ id: "ReviewReason" });
|
|
16941
|
-
var HttpMethod = external_exports.enum(["GET", "POST", "PUT", "DELETE"]).meta({ id: "HttpMethod" });
|
|
16942
|
-
var ReviewInfo = external_exports.object({
|
|
16943
|
-
needsReview: external_exports.boolean(),
|
|
16944
|
-
reasons: external_exports.array(ReviewReason)
|
|
16945
|
-
}).meta({ id: "ReviewInfo" });
|
|
16946
|
-
var DestinationNetwork = external_exports.object({
|
|
16947
|
-
port: external_exports.number().int().nullable(),
|
|
16948
|
-
geo: external_exports.string().nullable(),
|
|
16949
|
-
ptr: external_exports.string().nullable()
|
|
16950
|
-
}).meta({ id: "DestinationNetwork" });
|
|
16951
|
-
var EndpointSummary = external_exports.object({
|
|
16952
|
-
id: external_exports.string(),
|
|
16953
|
-
method: HttpMethod,
|
|
16954
|
-
transport: Transport,
|
|
16955
|
-
url: external_exports.string(),
|
|
16956
|
-
template: external_exports.boolean(),
|
|
16957
|
-
dataClass: DataClass,
|
|
16958
|
-
lastSeen: external_exports.iso.datetime(),
|
|
16959
|
-
callSiteCount: external_exports.number().int().nonnegative()
|
|
16960
|
-
}).meta({ id: "EndpointSummary" });
|
|
16961
|
-
var CallSite = external_exports.object({
|
|
16962
|
-
id: external_exports.string(),
|
|
16963
|
-
project: external_exports.string(),
|
|
16964
|
-
file: external_exports.string(),
|
|
16965
|
-
line: external_exports.number().int().nonnegative(),
|
|
16966
|
-
snippet: external_exports.string(),
|
|
16967
|
-
dynamic: external_exports.boolean(),
|
|
16968
|
-
vendored: external_exports.boolean(),
|
|
16969
|
-
/** Deep-link to the Inventory project, when the repo is governed there. */
|
|
16970
|
-
projectId: external_exports.string().nullable()
|
|
16971
|
-
}).meta({ id: "CallSite" });
|
|
16972
|
-
var EndpointWithSites = EndpointSummary.extend({
|
|
16973
|
-
sites: external_exports.array(CallSite)
|
|
16974
|
-
}).meta({ id: "EndpointWithSites" });
|
|
16975
|
-
var ShareDestinationSummary = external_exports.object({
|
|
16976
|
-
id: external_exports.string(),
|
|
16977
|
-
kind: DestinationKind,
|
|
16978
|
-
name: external_exports.string(),
|
|
16979
|
-
host: external_exports.string(),
|
|
16980
|
-
category: external_exports.string(),
|
|
16981
|
-
trust: ShareTrustLevel,
|
|
16982
|
-
/** Effective state (decision applied over the trust default). */
|
|
16983
|
-
status: EgressStatus,
|
|
16984
|
-
/** True when an egress decision override differs from the trust default. */
|
|
16985
|
-
isCustom: external_exports.boolean(),
|
|
16986
|
-
lastSeen: external_exports.iso.datetime(),
|
|
16987
|
-
endpointCount: external_exports.number().int().nonnegative(),
|
|
16988
|
-
callSiteCount: external_exports.number().int().nonnegative(),
|
|
16989
|
-
transports: external_exports.array(Transport),
|
|
16990
|
-
/** Most-sensitive first. */
|
|
16991
|
-
dataClasses: external_exports.array(DataClass),
|
|
16992
|
-
review: ReviewInfo,
|
|
16993
|
-
/** Non-provider hosts only; null for providers. */
|
|
16994
|
-
network: DestinationNetwork.nullable(),
|
|
16995
|
-
/** Embedded for inline expansion — no call sites here. */
|
|
16996
|
-
endpoints: external_exports.array(EndpointSummary)
|
|
16997
|
-
}).meta({ id: "ShareDestinationSummary" });
|
|
16998
|
-
var ShareDestinationDetail = ShareDestinationSummary.omit({
|
|
16999
|
-
endpointCount: true,
|
|
17000
|
-
callSiteCount: true,
|
|
17001
|
-
endpoints: true
|
|
17002
|
-
}).extend({
|
|
17003
|
-
/** Ownership/geo rationale; null for providers. */
|
|
17004
|
-
note: external_exports.string().nullable(),
|
|
17005
|
-
endpoints: external_exports.array(EndpointWithSites)
|
|
17006
|
-
}).meta({ id: "ShareDestinationDetail" });
|
|
17007
|
-
var ReviewDestination = external_exports.object({
|
|
17008
|
-
id: external_exports.string(),
|
|
17009
|
-
kind: DestinationKind,
|
|
17010
|
-
name: external_exports.string(),
|
|
17011
|
-
/** Registrable host — lets the strip derive the provider lettermark, as the register does. */
|
|
17012
|
-
host: external_exports.string(),
|
|
17013
|
-
trust: ShareTrustLevel,
|
|
17014
|
-
status: EgressStatus,
|
|
17015
|
-
review: ReviewInfo,
|
|
17016
|
-
topDataClass: DataClass,
|
|
17017
|
-
callSiteCount: external_exports.number().int().nonnegative(),
|
|
17018
|
-
lastSeen: external_exports.iso.datetime()
|
|
17019
|
-
}).meta({ id: "ReviewDestination" });
|
|
17020
|
-
var ShareDestinationGroup = external_exports.object({
|
|
17021
|
-
kind: DestinationKind,
|
|
17022
|
-
total: external_exports.number().int().nonnegative(),
|
|
17023
|
-
items: external_exports.array(ShareDestinationSummary)
|
|
17024
|
-
}).meta({ id: "ShareDestinationGroup" });
|
|
17025
|
-
var ListShareDestinationsResponse = external_exports.object({ groups: external_exports.array(ShareDestinationGroup) }).meta({ id: "ListShareDestinationsResponse" });
|
|
17026
|
-
var NeedsReviewResponse = external_exports.object({ items: external_exports.array(ReviewDestination) }).meta({ id: "NeedsReviewResponse" });
|
|
17027
|
-
var SharesStats = external_exports.object({
|
|
17028
|
-
destinations: external_exports.number().int().nonnegative(),
|
|
17029
|
-
endpoints: external_exports.number().int().nonnegative(),
|
|
17030
|
-
callSites: external_exports.number().int().nonnegative(),
|
|
17031
|
-
needsReview: external_exports.number().int().nonnegative(),
|
|
17032
|
-
insecure: external_exports.number().int().nonnegative(),
|
|
17033
|
-
byKind: external_exports.object({
|
|
17034
|
-
provider: external_exports.number().int().nonnegative(),
|
|
17035
|
-
internal: external_exports.number().int().nonnegative(),
|
|
17036
|
-
ip: external_exports.number().int().nonnegative()
|
|
17037
|
-
}),
|
|
17038
|
-
byTrust: external_exports.object({
|
|
17039
|
-
recognized: external_exports.number().int().nonnegative(),
|
|
17040
|
-
internal: external_exports.number().int().nonnegative(),
|
|
17041
|
-
unverified: external_exports.number().int().nonnegative(),
|
|
17042
|
-
ip: external_exports.number().int().nonnegative()
|
|
17043
|
-
})
|
|
17044
|
-
}).meta({ id: "SharesStats" });
|
|
17045
|
-
var SetEgressDecisionBody = external_exports.object({
|
|
17046
|
-
/** `null` clears the override — reverts to the trust default, isCustom false. */
|
|
17047
|
-
decision: EgressDecision.nullable()
|
|
17048
|
-
}).meta({ id: "SetEgressDecisionBody" });
|
|
17049
|
-
var SetEgressDecisionResponse = external_exports.object({ destination: ShareDestinationSummary }).meta({ id: "SetEgressDecisionResponse" });
|
|
17050
|
-
var ListShareDestinationsQuery = external_exports.object({
|
|
17051
|
-
/** Case-insensitive match over destination name/category, endpoint url, call-site project/file. */
|
|
17052
|
-
q: external_exports.string().optional(),
|
|
17053
|
-
/** Repeatable. Restrict to these DestinationKind values; absent means all kinds. */
|
|
17054
|
-
kind: external_exports.array(DestinationKind).optional(),
|
|
17055
|
-
/** Reserved for future grouping modes; only 'destination' is supported today. */
|
|
17056
|
-
groupBy: external_exports.enum(["destination"]).default("destination"),
|
|
17057
|
-
/**
|
|
17058
|
-
* When true, return a flat severity-ordered `items[]` instead of `groups`.
|
|
17059
|
-
* Uses `z.stringbool()` (NOT `z.coerce.boolean()` — `Boolean(str)` is true for
|
|
17060
|
-
* any non-empty string, so `?review=false`/`?review=0` would wrongly coerce
|
|
17061
|
-
* to `true`). `z.stringbool()` parses true/1/yes vs false/0/no correctly.
|
|
17062
|
-
*/
|
|
17063
|
-
review: external_exports.stringbool().default(false)
|
|
17064
|
-
});
|
|
17065
|
-
var ExportSharesQuery = external_exports.object({
|
|
17066
|
-
format: external_exports.enum(["csv", "json"]).default("csv"),
|
|
17067
|
-
q: external_exports.string().optional(),
|
|
17068
|
-
kind: external_exports.array(DestinationKind).optional()
|
|
17069
|
-
});
|
|
17070
|
-
|
|
17071
17210
|
// ../../packages/persistence/src/ids.ts
|
|
17072
17211
|
import { createHash } from "crypto";
|
|
17073
17212
|
|
|
17074
17213
|
// ../../packages/persistence/src/paths.ts
|
|
17075
|
-
import { chmodSync, mkdirSync } from "fs";
|
|
17214
|
+
import { chmodSync, lstatSync, mkdirSync, renameSync, rmSync, writeFileSync } from "fs";
|
|
17076
17215
|
var DATA_DIR_MODE = 448;
|
|
17077
17216
|
var DATA_FILE_MODE = 384;
|
|
17217
|
+
function chmodBestEffort(path, mode) {
|
|
17218
|
+
try {
|
|
17219
|
+
chmodSync(path, mode);
|
|
17220
|
+
} catch {
|
|
17221
|
+
}
|
|
17222
|
+
}
|
|
17223
|
+
function tightenDir(dir) {
|
|
17224
|
+
chmodBestEffort(dir, DATA_DIR_MODE);
|
|
17225
|
+
}
|
|
17226
|
+
function ensureDataDirSync(dir) {
|
|
17227
|
+
mkdirSync(dir, { recursive: true, mode: DATA_DIR_MODE });
|
|
17228
|
+
tightenDir(dir);
|
|
17229
|
+
}
|
|
17230
|
+
function tightenFile(file2) {
|
|
17231
|
+
try {
|
|
17232
|
+
if (lstatSync(file2).isSymbolicLink()) return;
|
|
17233
|
+
} catch {
|
|
17234
|
+
}
|
|
17235
|
+
chmodBestEffort(file2, DATA_FILE_MODE);
|
|
17236
|
+
}
|
|
17078
17237
|
|
|
17079
17238
|
// ../../packages/persistence/src/internal/json.ts
|
|
17080
17239
|
function parseJsonObject(s) {
|
|
@@ -17115,14 +17274,17 @@ import { randomUUID as randomUUID6 } from "crypto";
|
|
|
17115
17274
|
// ../../packages/persistence/src/repositories/shares.ts
|
|
17116
17275
|
import { randomUUID as randomUUID7 } from "crypto";
|
|
17117
17276
|
|
|
17277
|
+
// ../../packages/persistence/src/finding-key.ts
|
|
17278
|
+
import { createHash as createHash3 } from "crypto";
|
|
17279
|
+
|
|
17118
17280
|
// ../../packages/persistence/src/fingerprint.ts
|
|
17119
17281
|
import { createHmac, randomBytes } from "crypto";
|
|
17120
|
-
import {
|
|
17282
|
+
import { readFileSync } from "fs";
|
|
17121
17283
|
import { join as join2 } from "path";
|
|
17122
17284
|
|
|
17123
17285
|
// ../../packages/persistence/src/local-layout.ts
|
|
17124
|
-
import {
|
|
17125
|
-
import {
|
|
17286
|
+
import { renameSync as renameSync3 } from "fs";
|
|
17287
|
+
import { mkdir } from "fs/promises";
|
|
17126
17288
|
import { homedir } from "os";
|
|
17127
17289
|
import { join as join3 } from "path";
|
|
17128
17290
|
function defaultDataDir() {
|
|
@@ -17137,6 +17299,9 @@ function dataDir(base = defaultDataDir()) {
|
|
|
17137
17299
|
function dbPath(base = defaultDataDir()) {
|
|
17138
17300
|
return join3(dataDir(base), "aka.db");
|
|
17139
17301
|
}
|
|
17302
|
+
function ensureLayoutDirSync(dir = defaultDataDir()) {
|
|
17303
|
+
ensureDataDirSync(dir);
|
|
17304
|
+
}
|
|
17140
17305
|
function migrateLegacyLayout(base = defaultDataDir()) {
|
|
17141
17306
|
const moves = [
|
|
17142
17307
|
{ name: "config.json", dest: settingsDir(base) },
|
|
@@ -17144,19 +17309,17 @@ function migrateLegacyLayout(base = defaultDataDir()) {
|
|
|
17144
17309
|
];
|
|
17145
17310
|
for (const { name, dest } of moves) {
|
|
17146
17311
|
try {
|
|
17147
|
-
|
|
17148
|
-
|
|
17149
|
-
|
|
17150
|
-
|
|
17151
|
-
}
|
|
17152
|
-
renameSync3(join3(base, name), join3(dest, name));
|
|
17312
|
+
ensureDataDirSync(dest);
|
|
17313
|
+
const moved = join3(dest, name);
|
|
17314
|
+
renameSync3(join3(base, name), moved);
|
|
17315
|
+
tightenFile(moved);
|
|
17153
17316
|
} catch {
|
|
17154
17317
|
}
|
|
17155
17318
|
}
|
|
17156
17319
|
}
|
|
17157
17320
|
|
|
17158
17321
|
// ../../packages/persistence/src/settings.ts
|
|
17159
|
-
import { readFileSync as readFileSync2
|
|
17322
|
+
import { readFileSync as readFileSync2 } from "fs";
|
|
17160
17323
|
import { join as join4 } from "path";
|
|
17161
17324
|
function readWorkspaceSettings(base = defaultDataDir()) {
|
|
17162
17325
|
const record2 = readJson(join4(settingsDir(base), "settings.json"));
|
|
@@ -17178,7 +17341,7 @@ function readJson(file2) {
|
|
|
17178
17341
|
}
|
|
17179
17342
|
|
|
17180
17343
|
// ../../packages/persistence/src/warn-era-cap.ts
|
|
17181
|
-
import { existsSync as existsSync2, writeFileSync as
|
|
17344
|
+
import { existsSync as existsSync2, writeFileSync as writeFileSync2 } from "fs";
|
|
17182
17345
|
import { join as join5 } from "path";
|
|
17183
17346
|
|
|
17184
17347
|
// ../../packages/plugin-sdk/src/provider-env.ts
|
|
@@ -17231,6 +17394,12 @@ function resolveProvider() {
|
|
|
17231
17394
|
|
|
17232
17395
|
// ../../packages/plugin-sdk/src/config.ts
|
|
17233
17396
|
function loadConfig(base = defaultDataDir()) {
|
|
17397
|
+
try {
|
|
17398
|
+
ensureLayoutDirSync(base);
|
|
17399
|
+
const settingsFile = join6(settingsDir(base), "settings.json");
|
|
17400
|
+
if (existsSync3(settingsFile)) tightenFile(settingsFile);
|
|
17401
|
+
} catch {
|
|
17402
|
+
}
|
|
17234
17403
|
migrateLegacyLayout(base);
|
|
17235
17404
|
const settings = readWorkspaceSettings(base);
|
|
17236
17405
|
return {
|
|
@@ -17253,15 +17422,583 @@ function resolveProviderSafe() {
|
|
|
17253
17422
|
// ../../packages/plugin-sdk/src/config-inventory.ts
|
|
17254
17423
|
import { readdirSync, readFileSync as readFileSync4, realpathSync, statSync as statSync2 } from "fs";
|
|
17255
17424
|
import { homedir as homedir2 } from "os";
|
|
17256
|
-
import { basename as basename2, join as
|
|
17425
|
+
import { basename as basename2, join as join8 } from "path";
|
|
17426
|
+
|
|
17427
|
+
// ../../packages/detections/src/egress/registry.ts
|
|
17428
|
+
var EXTRACTOR_VERSION = "1";
|
|
17429
|
+
var PROVIDER_REGISTRY = [
|
|
17430
|
+
{
|
|
17431
|
+
id: "stripe",
|
|
17432
|
+
name: "Stripe",
|
|
17433
|
+
category: "Payments",
|
|
17434
|
+
hostSuffixes: ["stripe.com"],
|
|
17435
|
+
apiBase: "https://api.stripe.com",
|
|
17436
|
+
defaultDataClasses: ["pii", "customer"],
|
|
17437
|
+
sdks: {
|
|
17438
|
+
npm: ["stripe"],
|
|
17439
|
+
pypi: ["stripe"],
|
|
17440
|
+
go: ["github.com/stripe/stripe-go"],
|
|
17441
|
+
maven: ["com.stripe"],
|
|
17442
|
+
rubygems: ["stripe"],
|
|
17443
|
+
composer: ["stripe/stripe-php"],
|
|
17444
|
+
nuget: ["Stripe.net"]
|
|
17445
|
+
}
|
|
17446
|
+
},
|
|
17447
|
+
{
|
|
17448
|
+
id: "datadog",
|
|
17449
|
+
name: "Datadog",
|
|
17450
|
+
category: "Observability",
|
|
17451
|
+
hostSuffixes: ["datadoghq.com", "datadoghq.eu"],
|
|
17452
|
+
apiBase: "https://api.datadoghq.com",
|
|
17453
|
+
defaultDataClasses: ["telemetry", "logs", "metrics"],
|
|
17454
|
+
sdks: {
|
|
17455
|
+
npm: ["dd-trace", "@datadog/browser-logs"],
|
|
17456
|
+
pypi: ["datadog", "ddtrace"],
|
|
17457
|
+
go: ["github.com/DataDog/dd-trace-go"],
|
|
17458
|
+
maven: ["com.datadoghq"],
|
|
17459
|
+
rubygems: ["ddtrace", "dogapi"],
|
|
17460
|
+
nuget: ["Datadog.Trace"]
|
|
17461
|
+
}
|
|
17462
|
+
},
|
|
17463
|
+
{
|
|
17464
|
+
id: "newrelic",
|
|
17465
|
+
name: "New Relic",
|
|
17466
|
+
category: "Observability",
|
|
17467
|
+
hostSuffixes: ["newrelic.com", "nr-data.net"],
|
|
17468
|
+
apiBase: "https://api.newrelic.com",
|
|
17469
|
+
defaultDataClasses: ["telemetry", "logs", "metrics"],
|
|
17470
|
+
sdks: {
|
|
17471
|
+
npm: ["newrelic"],
|
|
17472
|
+
pypi: ["newrelic"],
|
|
17473
|
+
go: ["github.com/newrelic/go-agent"],
|
|
17474
|
+
maven: ["com.newrelic.agent.java"],
|
|
17475
|
+
rubygems: ["newrelic_rpm"],
|
|
17476
|
+
nuget: ["NewRelic.Agent"]
|
|
17477
|
+
}
|
|
17478
|
+
},
|
|
17479
|
+
{
|
|
17480
|
+
id: "sentry",
|
|
17481
|
+
name: "Sentry",
|
|
17482
|
+
category: "Error tracking",
|
|
17483
|
+
hostSuffixes: ["sentry.io"],
|
|
17484
|
+
apiBase: "https://sentry.io",
|
|
17485
|
+
defaultDataClasses: ["source", "telemetry"],
|
|
17486
|
+
sdks: {
|
|
17487
|
+
npm: ["@sentry/node", "@sentry/react", "@sentry/nextjs"],
|
|
17488
|
+
pypi: ["sentry-sdk"],
|
|
17489
|
+
go: ["github.com/getsentry/sentry-go"],
|
|
17490
|
+
maven: ["io.sentry"],
|
|
17491
|
+
rubygems: ["sentry-ruby"],
|
|
17492
|
+
cargo: ["sentry"],
|
|
17493
|
+
composer: ["sentry/sentry"],
|
|
17494
|
+
nuget: ["Sentry"]
|
|
17495
|
+
}
|
|
17496
|
+
},
|
|
17497
|
+
{
|
|
17498
|
+
id: "openai",
|
|
17499
|
+
name: "OpenAI",
|
|
17500
|
+
category: "LLM provider",
|
|
17501
|
+
hostSuffixes: ["openai.com"],
|
|
17502
|
+
apiBase: "https://api.openai.com",
|
|
17503
|
+
defaultDataClasses: ["pii", "source"],
|
|
17504
|
+
sdks: {
|
|
17505
|
+
npm: ["openai"],
|
|
17506
|
+
pypi: ["openai"],
|
|
17507
|
+
go: ["github.com/sashabaranov/go-openai"],
|
|
17508
|
+
maven: ["com.openai"],
|
|
17509
|
+
rubygems: ["ruby-openai"],
|
|
17510
|
+
cargo: ["async-openai"],
|
|
17511
|
+
composer: ["openai-php/client"],
|
|
17512
|
+
nuget: ["OpenAI"]
|
|
17513
|
+
}
|
|
17514
|
+
},
|
|
17515
|
+
{
|
|
17516
|
+
id: "anthropic",
|
|
17517
|
+
name: "Anthropic",
|
|
17518
|
+
category: "LLM provider",
|
|
17519
|
+
hostSuffixes: ["anthropic.com"],
|
|
17520
|
+
apiBase: "https://api.anthropic.com",
|
|
17521
|
+
defaultDataClasses: ["pii", "source"],
|
|
17522
|
+
sdks: {
|
|
17523
|
+
npm: ["@anthropic-ai/sdk"],
|
|
17524
|
+
pypi: ["anthropic"],
|
|
17525
|
+
go: ["github.com/anthropics/anthropic-sdk-go"],
|
|
17526
|
+
nuget: ["Anthropic.SDK"]
|
|
17527
|
+
}
|
|
17528
|
+
},
|
|
17529
|
+
{
|
|
17530
|
+
id: "aws",
|
|
17531
|
+
name: "Amazon Web Services",
|
|
17532
|
+
category: "Cloud platform",
|
|
17533
|
+
hostSuffixes: ["amazonaws.com"],
|
|
17534
|
+
apiBase: "https://s3.amazonaws.com",
|
|
17535
|
+
defaultDataClasses: ["secrets", "customer"],
|
|
17536
|
+
sdks: {
|
|
17537
|
+
npm: ["@aws-sdk/client-s3", "aws-sdk"],
|
|
17538
|
+
pypi: ["boto3"],
|
|
17539
|
+
go: ["github.com/aws/aws-sdk-go", "github.com/aws/aws-sdk-go-v2"],
|
|
17540
|
+
maven: ["com.amazonaws", "software.amazon.awssdk"],
|
|
17541
|
+
rubygems: ["aws-sdk-s3"],
|
|
17542
|
+
cargo: ["aws-sdk-s3"],
|
|
17543
|
+
nuget: ["AWSSDK.S3"]
|
|
17544
|
+
}
|
|
17545
|
+
},
|
|
17546
|
+
{
|
|
17547
|
+
id: "gcp",
|
|
17548
|
+
name: "Google Cloud",
|
|
17549
|
+
category: "Cloud platform",
|
|
17550
|
+
hostSuffixes: ["googleapis.com"],
|
|
17551
|
+
apiBase: "https://storage.googleapis.com",
|
|
17552
|
+
defaultDataClasses: ["customer", "logs"],
|
|
17553
|
+
sdks: {
|
|
17554
|
+
npm: ["@google-cloud/storage"],
|
|
17555
|
+
pypi: ["google-cloud-storage"],
|
|
17556
|
+
go: ["cloud.google.com/go"],
|
|
17557
|
+
maven: ["com.google.cloud"],
|
|
17558
|
+
rubygems: ["google-cloud-storage"],
|
|
17559
|
+
nuget: ["Google.Cloud.Storage.V1"]
|
|
17560
|
+
}
|
|
17561
|
+
},
|
|
17562
|
+
{
|
|
17563
|
+
id: "azure",
|
|
17564
|
+
name: "Microsoft Azure",
|
|
17565
|
+
category: "Cloud platform",
|
|
17566
|
+
hostSuffixes: ["azure.com", "windows.net"],
|
|
17567
|
+
apiBase: "https://management.azure.com",
|
|
17568
|
+
defaultDataClasses: ["customer", "logs"],
|
|
17569
|
+
sdks: {
|
|
17570
|
+
npm: ["@azure/storage-blob"],
|
|
17571
|
+
pypi: ["azure-storage-blob"],
|
|
17572
|
+
go: ["github.com/Azure/azure-sdk-for-go"],
|
|
17573
|
+
maven: ["com.azure"],
|
|
17574
|
+
rubygems: ["azure-storage-blob"],
|
|
17575
|
+
nuget: ["Azure.Storage.Blobs"]
|
|
17576
|
+
}
|
|
17577
|
+
},
|
|
17578
|
+
{
|
|
17579
|
+
id: "slack",
|
|
17580
|
+
name: "Slack",
|
|
17581
|
+
category: "Notifications",
|
|
17582
|
+
hostSuffixes: ["slack.com"],
|
|
17583
|
+
apiBase: "https://slack.com/api",
|
|
17584
|
+
defaultDataClasses: ["logs"],
|
|
17585
|
+
sdks: {
|
|
17586
|
+
npm: ["@slack/web-api"],
|
|
17587
|
+
pypi: ["slack-sdk"],
|
|
17588
|
+
go: ["github.com/slack-go/slack"],
|
|
17589
|
+
maven: ["com.slack.api"],
|
|
17590
|
+
rubygems: ["slack-ruby-client"],
|
|
17591
|
+
composer: ["slack-php/slack-api"],
|
|
17592
|
+
nuget: ["SlackNet"]
|
|
17593
|
+
}
|
|
17594
|
+
},
|
|
17595
|
+
{
|
|
17596
|
+
id: "segment",
|
|
17597
|
+
name: "Segment",
|
|
17598
|
+
category: "Analytics",
|
|
17599
|
+
hostSuffixes: ["segment.io", "segment.com"],
|
|
17600
|
+
apiBase: "https://api.segment.io",
|
|
17601
|
+
defaultDataClasses: ["customer"],
|
|
17602
|
+
sdks: {
|
|
17603
|
+
npm: ["@segment/analytics-node", "analytics-node"],
|
|
17604
|
+
pypi: ["segment-analytics-python"],
|
|
17605
|
+
go: ["github.com/segmentio/analytics-go"],
|
|
17606
|
+
maven: ["com.segment.analytics.java"],
|
|
17607
|
+
rubygems: ["analytics-ruby"],
|
|
17608
|
+
nuget: ["Analytics"]
|
|
17609
|
+
}
|
|
17610
|
+
},
|
|
17611
|
+
{
|
|
17612
|
+
id: "twilio",
|
|
17613
|
+
name: "Twilio",
|
|
17614
|
+
category: "Communications",
|
|
17615
|
+
hostSuffixes: ["twilio.com"],
|
|
17616
|
+
apiBase: "https://api.twilio.com",
|
|
17617
|
+
defaultDataClasses: ["pii", "customer"],
|
|
17618
|
+
sdks: {
|
|
17619
|
+
npm: ["twilio"],
|
|
17620
|
+
pypi: ["twilio"],
|
|
17621
|
+
go: ["github.com/twilio/twilio-go"],
|
|
17622
|
+
maven: ["com.twilio.sdk"],
|
|
17623
|
+
rubygems: ["twilio-ruby"],
|
|
17624
|
+
composer: ["twilio/sdk"],
|
|
17625
|
+
nuget: ["Twilio"]
|
|
17626
|
+
}
|
|
17627
|
+
},
|
|
17628
|
+
{
|
|
17629
|
+
id: "sendgrid",
|
|
17630
|
+
name: "SendGrid",
|
|
17631
|
+
category: "Email",
|
|
17632
|
+
hostSuffixes: ["sendgrid.com"],
|
|
17633
|
+
apiBase: "https://api.sendgrid.com",
|
|
17634
|
+
defaultDataClasses: ["pii"],
|
|
17635
|
+
sdks: {
|
|
17636
|
+
npm: ["@sendgrid/mail"],
|
|
17637
|
+
pypi: ["sendgrid"],
|
|
17638
|
+
go: ["github.com/sendgrid/sendgrid-go"],
|
|
17639
|
+
maven: ["com.sendgrid"],
|
|
17640
|
+
rubygems: ["sendgrid-ruby"],
|
|
17641
|
+
composer: ["sendgrid/sendgrid"],
|
|
17642
|
+
nuget: ["SendGrid"]
|
|
17643
|
+
}
|
|
17644
|
+
},
|
|
17645
|
+
{
|
|
17646
|
+
id: "mailgun",
|
|
17647
|
+
name: "Mailgun",
|
|
17648
|
+
category: "Email",
|
|
17649
|
+
hostSuffixes: ["mailgun.net"],
|
|
17650
|
+
apiBase: "https://api.mailgun.net",
|
|
17651
|
+
defaultDataClasses: ["pii"],
|
|
17652
|
+
sdks: {
|
|
17653
|
+
npm: ["mailgun.js"],
|
|
17654
|
+
pypi: ["mailgun"],
|
|
17655
|
+
rubygems: ["mailgun-ruby"],
|
|
17656
|
+
composer: ["mailgun/mailgun-php"],
|
|
17657
|
+
nuget: ["Mailgun"]
|
|
17658
|
+
}
|
|
17659
|
+
},
|
|
17660
|
+
{
|
|
17661
|
+
id: "mixpanel",
|
|
17662
|
+
name: "Mixpanel",
|
|
17663
|
+
category: "Analytics",
|
|
17664
|
+
hostSuffixes: ["mixpanel.com"],
|
|
17665
|
+
apiBase: "https://api.mixpanel.com",
|
|
17666
|
+
defaultDataClasses: ["customer", "telemetry"],
|
|
17667
|
+
sdks: {
|
|
17668
|
+
npm: ["mixpanel"],
|
|
17669
|
+
pypi: ["mixpanel"],
|
|
17670
|
+
rubygems: ["mixpanel-ruby"],
|
|
17671
|
+
nuget: ["Mixpanel"]
|
|
17672
|
+
}
|
|
17673
|
+
},
|
|
17674
|
+
{
|
|
17675
|
+
id: "amplitude",
|
|
17676
|
+
name: "Amplitude",
|
|
17677
|
+
category: "Analytics",
|
|
17678
|
+
hostSuffixes: ["amplitude.com"],
|
|
17679
|
+
apiBase: "https://api2.amplitude.com",
|
|
17680
|
+
defaultDataClasses: ["customer", "telemetry"],
|
|
17681
|
+
sdks: {
|
|
17682
|
+
npm: ["@amplitude/analytics-node"],
|
|
17683
|
+
pypi: ["amplitude-analytics"],
|
|
17684
|
+
nuget: ["Amplitude"]
|
|
17685
|
+
}
|
|
17686
|
+
},
|
|
17687
|
+
{
|
|
17688
|
+
id: "posthog",
|
|
17689
|
+
name: "PostHog",
|
|
17690
|
+
category: "Analytics",
|
|
17691
|
+
hostSuffixes: ["posthog.com"],
|
|
17692
|
+
apiBase: "https://us.i.posthog.com",
|
|
17693
|
+
defaultDataClasses: ["customer", "telemetry"],
|
|
17694
|
+
sdks: {
|
|
17695
|
+
npm: ["posthog-node", "posthog-js"],
|
|
17696
|
+
pypi: ["posthog"],
|
|
17697
|
+
go: ["github.com/posthog/posthog-go"],
|
|
17698
|
+
rubygems: ["posthog-ruby"],
|
|
17699
|
+
composer: ["posthog/posthog-php"],
|
|
17700
|
+
nuget: ["PostHog"]
|
|
17701
|
+
}
|
|
17702
|
+
},
|
|
17703
|
+
{
|
|
17704
|
+
id: "honeycomb",
|
|
17705
|
+
name: "Honeycomb",
|
|
17706
|
+
category: "Observability",
|
|
17707
|
+
hostSuffixes: ["honeycomb.io"],
|
|
17708
|
+
apiBase: "https://api.honeycomb.io",
|
|
17709
|
+
defaultDataClasses: ["telemetry", "metrics"],
|
|
17710
|
+
sdks: {
|
|
17711
|
+
npm: ["libhoney"],
|
|
17712
|
+
pypi: ["libhoney"],
|
|
17713
|
+
go: ["github.com/honeycombio/libhoney-go"],
|
|
17714
|
+
rubygems: ["libhoney"]
|
|
17715
|
+
}
|
|
17716
|
+
},
|
|
17717
|
+
{
|
|
17718
|
+
id: "grafana",
|
|
17719
|
+
name: "Grafana Cloud",
|
|
17720
|
+
category: "Observability",
|
|
17721
|
+
hostSuffixes: ["grafana.net"],
|
|
17722
|
+
apiBase: "https://grafana.net",
|
|
17723
|
+
defaultDataClasses: ["logs", "metrics"],
|
|
17724
|
+
sdks: {
|
|
17725
|
+
npm: ["@grafana/faro-web-sdk"]
|
|
17726
|
+
}
|
|
17727
|
+
},
|
|
17728
|
+
{
|
|
17729
|
+
id: "splunk",
|
|
17730
|
+
name: "Splunk",
|
|
17731
|
+
category: "Observability",
|
|
17732
|
+
hostSuffixes: ["splunkcloud.com", "splunk.com"],
|
|
17733
|
+
apiBase: "https://http-inputs.splunkcloud.com",
|
|
17734
|
+
defaultDataClasses: ["logs"],
|
|
17735
|
+
sdks: {
|
|
17736
|
+
npm: ["splunk-logging"],
|
|
17737
|
+
pypi: ["splunk-sdk"],
|
|
17738
|
+
maven: ["com.splunk"],
|
|
17739
|
+
nuget: ["Splunk.Logging.Common"]
|
|
17740
|
+
}
|
|
17741
|
+
},
|
|
17742
|
+
{
|
|
17743
|
+
id: "pagerduty",
|
|
17744
|
+
name: "PagerDuty",
|
|
17745
|
+
category: "Incident response",
|
|
17746
|
+
hostSuffixes: ["pagerduty.com"],
|
|
17747
|
+
apiBase: "https://api.pagerduty.com",
|
|
17748
|
+
defaultDataClasses: ["logs"],
|
|
17749
|
+
sdks: {
|
|
17750
|
+
npm: ["@pagerduty/pdjs"],
|
|
17751
|
+
pypi: ["pdpyras"],
|
|
17752
|
+
go: ["github.com/PagerDuty/go-pagerduty"],
|
|
17753
|
+
rubygems: ["pagerduty"]
|
|
17754
|
+
}
|
|
17755
|
+
},
|
|
17756
|
+
{
|
|
17757
|
+
id: "github",
|
|
17758
|
+
name: "GitHub",
|
|
17759
|
+
category: "Developer platform",
|
|
17760
|
+
hostSuffixes: ["github.com", "githubusercontent.com"],
|
|
17761
|
+
apiBase: "https://api.github.com",
|
|
17762
|
+
defaultDataClasses: ["source"],
|
|
17763
|
+
sdks: {
|
|
17764
|
+
npm: ["@octokit/rest", "octokit"],
|
|
17765
|
+
pypi: ["pygithub"],
|
|
17766
|
+
go: ["github.com/google/go-github"],
|
|
17767
|
+
maven: ["org.kohsuke.github-api"],
|
|
17768
|
+
rubygems: ["octokit"],
|
|
17769
|
+
cargo: ["octocrab"],
|
|
17770
|
+
composer: ["knplabs/github-api"],
|
|
17771
|
+
nuget: ["Octokit"]
|
|
17772
|
+
}
|
|
17773
|
+
},
|
|
17774
|
+
{
|
|
17775
|
+
id: "gitlab",
|
|
17776
|
+
name: "GitLab",
|
|
17777
|
+
category: "Developer platform",
|
|
17778
|
+
hostSuffixes: ["gitlab.com"],
|
|
17779
|
+
apiBase: "https://gitlab.com/api",
|
|
17780
|
+
defaultDataClasses: ["source"],
|
|
17781
|
+
sdks: {
|
|
17782
|
+
npm: ["@gitbeaker/rest"],
|
|
17783
|
+
pypi: ["python-gitlab"],
|
|
17784
|
+
go: ["gitlab.com/gitlab-org/api/client-go"],
|
|
17785
|
+
rubygems: ["gitlab"],
|
|
17786
|
+
nuget: ["GitLabApiClient"]
|
|
17787
|
+
}
|
|
17788
|
+
},
|
|
17789
|
+
{
|
|
17790
|
+
id: "auth0",
|
|
17791
|
+
name: "Auth0",
|
|
17792
|
+
category: "Identity",
|
|
17793
|
+
hostSuffixes: ["auth0.com"],
|
|
17794
|
+
apiBase: "https://login.auth0.com",
|
|
17795
|
+
defaultDataClasses: ["pii"],
|
|
17796
|
+
sdks: {
|
|
17797
|
+
npm: ["auth0"],
|
|
17798
|
+
pypi: ["auth0-python"],
|
|
17799
|
+
go: ["github.com/auth0/go-auth0"],
|
|
17800
|
+
maven: ["com.auth0"],
|
|
17801
|
+
rubygems: ["auth0"],
|
|
17802
|
+
composer: ["auth0/auth0-php"],
|
|
17803
|
+
nuget: ["Auth0.ManagementApi"]
|
|
17804
|
+
}
|
|
17805
|
+
},
|
|
17806
|
+
{
|
|
17807
|
+
id: "okta",
|
|
17808
|
+
name: "Okta",
|
|
17809
|
+
category: "Identity",
|
|
17810
|
+
hostSuffixes: ["okta.com", "oktapreview.com"],
|
|
17811
|
+
apiBase: "https://login.okta.com",
|
|
17812
|
+
defaultDataClasses: ["pii"],
|
|
17813
|
+
sdks: {
|
|
17814
|
+
npm: ["@okta/okta-sdk-nodejs"],
|
|
17815
|
+
pypi: ["okta"],
|
|
17816
|
+
go: ["github.com/okta/okta-sdk-golang"],
|
|
17817
|
+
maven: ["com.okta.sdk"],
|
|
17818
|
+
nuget: ["Okta.Sdk"]
|
|
17819
|
+
}
|
|
17820
|
+
},
|
|
17821
|
+
{
|
|
17822
|
+
id: "clerk",
|
|
17823
|
+
name: "Clerk",
|
|
17824
|
+
category: "Identity",
|
|
17825
|
+
hostSuffixes: ["clerk.com", "clerk.dev"],
|
|
17826
|
+
apiBase: "https://api.clerk.com",
|
|
17827
|
+
defaultDataClasses: ["pii"],
|
|
17828
|
+
sdks: {
|
|
17829
|
+
npm: ["@clerk/backend", "@clerk/nextjs"],
|
|
17830
|
+
pypi: ["clerk-backend-api"],
|
|
17831
|
+
go: ["github.com/clerk/clerk-sdk-go"]
|
|
17832
|
+
}
|
|
17833
|
+
},
|
|
17834
|
+
{
|
|
17835
|
+
id: "supabase",
|
|
17836
|
+
name: "Supabase",
|
|
17837
|
+
category: "Backend platform",
|
|
17838
|
+
hostSuffixes: ["supabase.co", "supabase.com"],
|
|
17839
|
+
apiBase: "https://api.supabase.com",
|
|
17840
|
+
defaultDataClasses: ["pii", "customer"],
|
|
17841
|
+
sdks: {
|
|
17842
|
+
npm: ["@supabase/supabase-js"],
|
|
17843
|
+
pypi: ["supabase"],
|
|
17844
|
+
cargo: ["postgrest"]
|
|
17845
|
+
}
|
|
17846
|
+
},
|
|
17847
|
+
{
|
|
17848
|
+
id: "firebase",
|
|
17849
|
+
name: "Firebase",
|
|
17850
|
+
category: "Backend platform",
|
|
17851
|
+
hostSuffixes: ["firebaseio.com", "firebase.google.com"],
|
|
17852
|
+
apiBase: "https://firebaseio.com",
|
|
17853
|
+
defaultDataClasses: ["customer"],
|
|
17854
|
+
sdks: {
|
|
17855
|
+
npm: ["firebase", "firebase-admin"],
|
|
17856
|
+
pypi: ["firebase-admin"],
|
|
17857
|
+
go: ["firebase.google.com/go"],
|
|
17858
|
+
maven: ["com.google.firebase"]
|
|
17859
|
+
}
|
|
17860
|
+
},
|
|
17861
|
+
{
|
|
17862
|
+
id: "mongodb-atlas",
|
|
17863
|
+
name: "MongoDB Atlas",
|
|
17864
|
+
category: "Database SaaS",
|
|
17865
|
+
hostSuffixes: ["mongodb.net", "mongodb.com"],
|
|
17866
|
+
apiBase: "https://cloud.mongodb.com",
|
|
17867
|
+
defaultDataClasses: ["customer"],
|
|
17868
|
+
sdks: {
|
|
17869
|
+
npm: ["mongodb"],
|
|
17870
|
+
pypi: ["pymongo"],
|
|
17871
|
+
go: ["go.mongodb.org/mongo-driver"],
|
|
17872
|
+
maven: ["org.mongodb"],
|
|
17873
|
+
rubygems: ["mongo"],
|
|
17874
|
+
cargo: ["mongodb"],
|
|
17875
|
+
nuget: ["MongoDB.Driver"]
|
|
17876
|
+
}
|
|
17877
|
+
},
|
|
17878
|
+
{
|
|
17879
|
+
id: "planetscale",
|
|
17880
|
+
name: "PlanetScale",
|
|
17881
|
+
category: "Database SaaS",
|
|
17882
|
+
hostSuffixes: ["psdb.cloud", "planetscale.com"],
|
|
17883
|
+
apiBase: "https://api.planetscale.com",
|
|
17884
|
+
defaultDataClasses: ["customer"],
|
|
17885
|
+
sdks: {
|
|
17886
|
+
npm: ["@planetscale/database"],
|
|
17887
|
+
go: ["github.com/planetscale/planetscale-go"]
|
|
17888
|
+
}
|
|
17889
|
+
},
|
|
17890
|
+
{
|
|
17891
|
+
id: "algolia",
|
|
17892
|
+
name: "Algolia",
|
|
17893
|
+
category: "Search SaaS",
|
|
17894
|
+
hostSuffixes: ["algolia.net", "algolianet.com"],
|
|
17895
|
+
apiBase: "https://algolia.net",
|
|
17896
|
+
defaultDataClasses: ["customer"],
|
|
17897
|
+
sdks: {
|
|
17898
|
+
npm: ["algoliasearch"],
|
|
17899
|
+
pypi: ["algoliasearch"],
|
|
17900
|
+
go: ["github.com/algolia/algoliasearch-client-go"],
|
|
17901
|
+
maven: ["com.algolia"],
|
|
17902
|
+
rubygems: ["algolia"],
|
|
17903
|
+
composer: ["algolia/algoliasearch-client-php"],
|
|
17904
|
+
nuget: ["Algolia.Search"]
|
|
17905
|
+
}
|
|
17906
|
+
},
|
|
17907
|
+
{
|
|
17908
|
+
id: "cloudflare",
|
|
17909
|
+
name: "Cloudflare",
|
|
17910
|
+
category: "CDN / edge",
|
|
17911
|
+
hostSuffixes: ["cloudflare.com", "workers.dev"],
|
|
17912
|
+
apiBase: "https://api.cloudflare.com",
|
|
17913
|
+
defaultDataClasses: ["logs"],
|
|
17914
|
+
sdks: {
|
|
17915
|
+
npm: ["cloudflare"],
|
|
17916
|
+
pypi: ["cloudflare"],
|
|
17917
|
+
go: ["github.com/cloudflare/cloudflare-go"],
|
|
17918
|
+
nuget: ["CloudFlare.Client"]
|
|
17919
|
+
}
|
|
17920
|
+
},
|
|
17921
|
+
{
|
|
17922
|
+
id: "huggingface",
|
|
17923
|
+
name: "Hugging Face",
|
|
17924
|
+
category: "LLM provider",
|
|
17925
|
+
hostSuffixes: ["huggingface.co"],
|
|
17926
|
+
apiBase: "https://api-inference.huggingface.co",
|
|
17927
|
+
defaultDataClasses: ["source"],
|
|
17928
|
+
sdks: {
|
|
17929
|
+
npm: ["@huggingface/inference"],
|
|
17930
|
+
pypi: ["huggingface-hub", "transformers"],
|
|
17931
|
+
rubygems: ["hugging-face"]
|
|
17932
|
+
}
|
|
17933
|
+
},
|
|
17934
|
+
{
|
|
17935
|
+
id: "cohere",
|
|
17936
|
+
name: "Cohere",
|
|
17937
|
+
category: "LLM provider",
|
|
17938
|
+
hostSuffixes: ["cohere.com", "cohere.ai"],
|
|
17939
|
+
apiBase: "https://api.cohere.com",
|
|
17940
|
+
defaultDataClasses: ["pii", "source"],
|
|
17941
|
+
sdks: {
|
|
17942
|
+
npm: ["cohere-ai"],
|
|
17943
|
+
pypi: ["cohere"],
|
|
17944
|
+
go: ["github.com/cohere-ai/cohere-go"]
|
|
17945
|
+
}
|
|
17946
|
+
},
|
|
17947
|
+
{
|
|
17948
|
+
id: "mistral",
|
|
17949
|
+
name: "Mistral AI",
|
|
17950
|
+
category: "LLM provider",
|
|
17951
|
+
hostSuffixes: ["mistral.ai"],
|
|
17952
|
+
apiBase: "https://api.mistral.ai",
|
|
17953
|
+
defaultDataClasses: ["pii", "source"],
|
|
17954
|
+
sdks: {
|
|
17955
|
+
npm: ["@mistralai/mistralai"],
|
|
17956
|
+
pypi: ["mistralai"],
|
|
17957
|
+
go: ["github.com/gage-technologies/mistral-go"]
|
|
17958
|
+
}
|
|
17959
|
+
}
|
|
17960
|
+
];
|
|
17961
|
+
var EGRESS_VERSION_MATERIAL = `${EXTRACTOR_VERSION}
|
|
17962
|
+
${JSON.stringify(PROVIDER_REGISTRY)}`;
|
|
17963
|
+
|
|
17964
|
+
// ../../packages/detections/src/egress/extract.ts
|
|
17965
|
+
var SECRET_KEY_NAMES = "api[_-]?key|apikey|private[_-]?key|access[_-]?key|access[_-]?token|token|secret|credentials?|password|passwd|pwd|authorization|sig|signature|sas|assertion";
|
|
17966
|
+
var AUTH_SCHEMES = "Bearer|Basic|Token|Digest|ApiKey|SSWS|AWS4-HMAC-SHA256";
|
|
17967
|
+
var SECRET_VALUE = new RegExp(
|
|
17968
|
+
`((?:${SECRET_KEY_NAMES})['"\`]?\\s*[:=]\\s*['"\`]?)(?!(?:${AUTH_SCHEMES})[\\s'"\`])[^\\s'"\`&]+`,
|
|
17969
|
+
"gi"
|
|
17970
|
+
);
|
|
17971
|
+
var AUTH_SCHEME_VALUE = new RegExp(
|
|
17972
|
+
`((?:${SECRET_KEY_NAMES})['"\`]?\\s*[:=]\\s*['"\`]?)(${AUTH_SCHEMES})\\s+[^\\s'"\`]+`,
|
|
17973
|
+
"gi"
|
|
17974
|
+
);
|
|
17975
|
+
var WEBHOOK_SECRET_PATHS = [
|
|
17976
|
+
{ hosts: ["hooks.slack.com"], prefix: "/services/" },
|
|
17977
|
+
{
|
|
17978
|
+
hosts: ["discord.com", "discordapp.com", "ptb.discord.com", "canary.discord.com"],
|
|
17979
|
+
prefix: "/api/webhooks/"
|
|
17980
|
+
},
|
|
17981
|
+
{ hosts: ["hooks.zapier.com"], prefix: "/hooks/" },
|
|
17982
|
+
{ hosts: ["outlook.office.com", "outlook.office365.com"], prefix: "/webhook/" }
|
|
17983
|
+
];
|
|
17984
|
+
function escapeRegExp(literal2) {
|
|
17985
|
+
return literal2.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
17986
|
+
}
|
|
17987
|
+
var WEBHOOK_URL = new RegExp(
|
|
17988
|
+
`(https?://(?:${WEBHOOK_SECRET_PATHS.flatMap(
|
|
17989
|
+
(entry) => entry.hosts.map((host) => `${escapeRegExp(host)}${escapeRegExp(entry.prefix)}`)
|
|
17990
|
+
).join("|")}))[^\\s'"\`<>()[\\]{},;]+`,
|
|
17991
|
+
"gi"
|
|
17992
|
+
);
|
|
17257
17993
|
|
|
17258
17994
|
// ../../packages/detections/src/escape-regexp.ts
|
|
17259
|
-
function
|
|
17995
|
+
function escapeRegExp2(value) {
|
|
17260
17996
|
return value.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
17261
17997
|
}
|
|
17262
17998
|
|
|
17263
17999
|
// ../../packages/detections/src/matchers/limits.ts
|
|
17264
18000
|
var MAX_MATCHES_PER_RULE = 1e4;
|
|
18001
|
+
var MAX_REGEX_INPUT_LENGTH = 2e5;
|
|
17265
18002
|
|
|
17266
18003
|
// ../../packages/detections/src/matchers/keyword.ts
|
|
17267
18004
|
var KeywordMatcher2 = class {
|
|
@@ -17272,7 +18009,7 @@ var KeywordMatcher2 = class {
|
|
|
17272
18009
|
for (const kw of keywords) {
|
|
17273
18010
|
if (kw.length === 0) continue;
|
|
17274
18011
|
if (spans.length >= MAX_MATCHES_PER_RULE) break;
|
|
17275
|
-
const re = new RegExp(
|
|
18012
|
+
const re = new RegExp(escapeRegExp2(kw), caseSensitive ? "gu" : "giu");
|
|
17276
18013
|
let m;
|
|
17277
18014
|
while ((m = re.exec(text)) !== null) {
|
|
17278
18015
|
spans.push({ start: m.index, end: m.index + m[0].length });
|
|
@@ -17289,9 +18026,13 @@ var RegexMatcher2 = class {
|
|
|
17289
18026
|
if (rule.matcher.type !== "regex") return [];
|
|
17290
18027
|
const { pattern, flags, captureGroup } = rule.matcher;
|
|
17291
18028
|
const re = new RegExp(pattern, flags.includes("d") ? flags : `${flags}d`);
|
|
18029
|
+
const scanText2 = text.length > MAX_REGEX_INPUT_LENGTH ? text.slice(0, MAX_REGEX_INPUT_LENGTH) : text;
|
|
17292
18030
|
const spans = [];
|
|
17293
18031
|
let m;
|
|
17294
|
-
|
|
18032
|
+
const maxIterations = scanText2.length + 1;
|
|
18033
|
+
let iterations = 0;
|
|
18034
|
+
while ((m = re.exec(scanText2)) !== null) {
|
|
18035
|
+
if (++iterations > maxIterations) break;
|
|
17295
18036
|
const group = captureGroup != null ? m[captureGroup] : m[0];
|
|
17296
18037
|
if (m[0].length === 0) re.lastIndex++;
|
|
17297
18038
|
if (group && spans.length < MAX_MATCHES_PER_RULE) {
|
|
@@ -17366,27 +18107,53 @@ var CONFIG_POSTURE_RULES = [
|
|
|
17366
18107
|
}
|
|
17367
18108
|
];
|
|
17368
18109
|
|
|
18110
|
+
// ../../packages/detections/src/security/redos-probe.ts
|
|
18111
|
+
var EXPONENTIAL_UNITS = [
|
|
18112
|
+
"a",
|
|
18113
|
+
"0",
|
|
18114
|
+
" ",
|
|
18115
|
+
"x",
|
|
18116
|
+
"ab",
|
|
18117
|
+
"a.",
|
|
18118
|
+
"a-",
|
|
18119
|
+
"a_",
|
|
18120
|
+
"a@",
|
|
18121
|
+
"a/",
|
|
18122
|
+
"a:",
|
|
18123
|
+
"a=",
|
|
18124
|
+
"a;",
|
|
18125
|
+
"aA0",
|
|
18126
|
+
" "
|
|
18127
|
+
];
|
|
18128
|
+
var EXPONENTIAL_PROBES = EXPONENTIAL_UNITS.flatMap(
|
|
18129
|
+
(unit) => [23, 25].map((len) => unit.repeat(Math.ceil(len / unit.length)).slice(0, len) + "!")
|
|
18130
|
+
);
|
|
18131
|
+
var POLYNOMIAL_PROBES = ["abc-", "a.", "a ", "a=", "x", "0", "a@", "a/", "ab"].map(
|
|
18132
|
+
(unit) => unit.repeat(1e4).slice(0, 4e4) + "!"
|
|
18133
|
+
);
|
|
18134
|
+
|
|
17369
18135
|
// ../../packages/plugin-sdk/src/repo.ts
|
|
17370
|
-
import { existsSync as
|
|
17371
|
-
import { basename, dirname, isAbsolute, join as
|
|
18136
|
+
import { existsSync as existsSync4, readFileSync as readFileSync3, statSync } from "fs";
|
|
18137
|
+
import { basename, dirname, isAbsolute, join as join7, sep as sep2 } from "path";
|
|
17372
18138
|
|
|
17373
18139
|
// ../../packages/plugin-sdk/src/events.ts
|
|
17374
|
-
import { createHash as
|
|
17375
|
-
|
|
17376
|
-
// ../../packages/plugin-sdk/src/finding-key.ts
|
|
17377
|
-
import { createHash as createHash4 } from "crypto";
|
|
18140
|
+
import { createHash as createHash4, randomUUID as randomUUID9 } from "crypto";
|
|
17378
18141
|
|
|
17379
18142
|
// ../../packages/plugin-sdk/src/inventory-resolver.ts
|
|
17380
18143
|
import { arch, hostname as hostname3, platform, release } from "os";
|
|
17381
18144
|
|
|
17382
18145
|
// ../../packages/plugin-sdk/src/nudge.ts
|
|
17383
|
-
import { mkdirSync as
|
|
17384
|
-
import { join as
|
|
18146
|
+
import { mkdirSync as mkdirSync2, readFileSync as readFileSync5, writeFileSync as writeFileSync3 } from "fs";
|
|
18147
|
+
import { join as join9 } from "path";
|
|
18148
|
+
|
|
18149
|
+
// ../../packages/plugin-sdk/src/paths.ts
|
|
18150
|
+
import { readdirSync as readdirSync2, realpathSync as realpathSync2 } from "fs";
|
|
18151
|
+
import { basename as basename3, dirname as dirname2, sep as sep3 } from "path";
|
|
17385
18152
|
|
|
17386
18153
|
// ../../packages/plugin-sdk/src/project-files.ts
|
|
17387
18154
|
var import_ignore = __toESM(require_ignore(), 1);
|
|
17388
|
-
import { existsSync as
|
|
17389
|
-
import { basename as
|
|
18155
|
+
import { existsSync as existsSync5, readdirSync as readdirSync3, readFileSync as readFileSync6 } from "fs";
|
|
18156
|
+
import { basename as basename4, join as join10, relative, sep as sep4 } from "path";
|
|
17390
18157
|
|
|
17391
18158
|
// ../../packages/plugin-sdk/src/runtime.ts
|
|
17392
18159
|
import { randomUUID as randomUUID10 } from "crypto";
|
|
@@ -17395,17 +18162,17 @@ import { randomUUID as randomUUID10 } from "crypto";
|
|
|
17395
18162
|
var THIRTY_DAYS_MS = 30 * 24 * 60 * 60 * 1e3;
|
|
17396
18163
|
|
|
17397
18164
|
// ../../packages/plugin-sdk/src/throttle.ts
|
|
17398
|
-
import { mkdirSync as
|
|
17399
|
-
import { join as
|
|
18165
|
+
import { mkdirSync as mkdirSync3, statSync as statSync3, writeFileSync as writeFileSync4 } from "fs";
|
|
18166
|
+
import { join as join11 } from "path";
|
|
17400
18167
|
function throttled(dataDir2, markerName, windowMs) {
|
|
17401
|
-
const marker =
|
|
18168
|
+
const marker = join11(dataDir2, markerName);
|
|
17402
18169
|
try {
|
|
17403
18170
|
if (Date.now() - statSync3(marker).mtimeMs < windowMs) return true;
|
|
17404
18171
|
} catch {
|
|
17405
18172
|
}
|
|
17406
18173
|
try {
|
|
17407
|
-
|
|
17408
|
-
|
|
18174
|
+
mkdirSync3(dataDir2, { recursive: true, mode: DATA_DIR_MODE });
|
|
18175
|
+
writeFileSync4(marker, String(Date.now()), { mode: DATA_FILE_MODE });
|
|
17409
18176
|
} catch {
|
|
17410
18177
|
}
|
|
17411
18178
|
return false;
|
|
@@ -17413,7 +18180,7 @@ function throttled(dataDir2, markerName, windowMs) {
|
|
|
17413
18180
|
|
|
17414
18181
|
// src/history/reconcile-trigger.ts
|
|
17415
18182
|
import { spawn } from "child_process";
|
|
17416
|
-
import { dirname as
|
|
18183
|
+
import { dirname as dirname3, join as join13 } from "path";
|
|
17417
18184
|
import { fileURLToPath } from "url";
|
|
17418
18185
|
|
|
17419
18186
|
// src/history/tail.ts
|
|
@@ -17421,13 +18188,13 @@ import { createHash as createHash5 } from "crypto";
|
|
|
17421
18188
|
import {
|
|
17422
18189
|
closeSync,
|
|
17423
18190
|
fstatSync,
|
|
17424
|
-
mkdirSync as
|
|
18191
|
+
mkdirSync as mkdirSync4,
|
|
17425
18192
|
openSync,
|
|
17426
18193
|
readFileSync as readFileSync7,
|
|
17427
18194
|
readSync,
|
|
17428
|
-
writeFileSync as
|
|
18195
|
+
writeFileSync as writeFileSync5
|
|
17429
18196
|
} from "fs";
|
|
17430
|
-
import { join as
|
|
18197
|
+
import { join as join12 } from "path";
|
|
17431
18198
|
var SAFE_SESSION_ID = /^[A-Za-z0-9._-]+$/;
|
|
17432
18199
|
function safeSessionId(sessionId) {
|
|
17433
18200
|
if (SAFE_SESSION_ID.test(sessionId) && sessionId !== "." && sessionId !== "..") {
|
|
@@ -17443,8 +18210,8 @@ function triggerReconcile(dataDir2, sessionId, transcriptPath) {
|
|
|
17443
18210
|
try {
|
|
17444
18211
|
const marker = `${RECONCILE_MARKER_PREFIX}-${safeSessionId(sessionId)}`;
|
|
17445
18212
|
if (throttled(dataDir2, marker, RECONCILE_THROTTLE_MS)) return;
|
|
17446
|
-
const here =
|
|
17447
|
-
const child = spawn(process.execPath, [
|
|
18213
|
+
const here = dirname3(fileURLToPath(import.meta.url));
|
|
18214
|
+
const child = spawn(process.execPath, [join13(here, "reconcile.js"), sessionId, transcriptPath], {
|
|
17448
18215
|
detached: true,
|
|
17449
18216
|
stdio: "ignore"
|
|
17450
18217
|
});
|
|
@@ -17457,13 +18224,23 @@ function triggerReconcile(dataDir2, sessionId, transcriptPath) {
|
|
|
17457
18224
|
async function readStdin() {
|
|
17458
18225
|
return new Promise((resolve) => {
|
|
17459
18226
|
let data = "";
|
|
17460
|
-
|
|
17461
|
-
|
|
17462
|
-
|
|
17463
|
-
|
|
17464
|
-
|
|
18227
|
+
let settled = false;
|
|
18228
|
+
const finish = () => {
|
|
18229
|
+
if (settled) return;
|
|
18230
|
+
settled = true;
|
|
18231
|
+
clearTimeout(timer);
|
|
18232
|
+
process.stdin.removeListener("data", onData);
|
|
18233
|
+
process.stdin.removeListener("end", finish);
|
|
17465
18234
|
resolve(data);
|
|
17466
|
-
}
|
|
18235
|
+
};
|
|
18236
|
+
const onData = (chunk) => {
|
|
18237
|
+
data += chunk;
|
|
18238
|
+
};
|
|
18239
|
+
const timer = setTimeout(finish, 5e3);
|
|
18240
|
+
process.stdin.setEncoding("utf8");
|
|
18241
|
+
process.stdin.on("data", onData);
|
|
18242
|
+
process.stdin.on("end", finish);
|
|
18243
|
+
process.stdin.on("error", finish);
|
|
17467
18244
|
});
|
|
17468
18245
|
}
|
|
17469
18246
|
function parseJson(raw) {
|