@r_masseater/fu4 0.2.0 → 0.3.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.
@@ -0,0 +1,662 @@
1
+ import { _ as YamlNode, h as SyntaxNode, l as Project, m as Source, n as Fu4Config, p as ScriptLanguage } from "./index-DFaQsB5x.mjs";
2
+ import { Effect, Option, Result, Schema } from "effect";
3
+ interface Origin {
4
+ readonly start: number;
5
+ readonly end: number;
6
+ readonly raw: string;
7
+ }
8
+ type Literal = {
9
+ readonly kind: "number";
10
+ readonly value: number;
11
+ } | {
12
+ readonly kind: "string";
13
+ readonly value: string;
14
+ } | {
15
+ readonly kind: "boolean";
16
+ readonly value: boolean;
17
+ } | {
18
+ readonly kind: "null";
19
+ };
20
+ type BinaryOp = "and" | "or" | "eq" | "neq" | "gt" | "ge" | "lt" | "le";
21
+ type FunctionName = "contains" | "startswith" | "endswith" | "format" | "join" | "tojson" | "fromjson" | "hashfiles" | "case" | "success" | "always" | "cancelled" | "failure";
22
+ type Expr = {
23
+ readonly type: "literal";
24
+ readonly literal: Literal;
25
+ } | {
26
+ readonly type: "star";
27
+ } | {
28
+ readonly type: "call";
29
+ readonly func: FunctionName;
30
+ readonly args: readonly Spanned[];
31
+ } | {
32
+ readonly type: "identifier";
33
+ readonly name: string;
34
+ } | {
35
+ readonly type: "index";
36
+ readonly inner: Spanned;
37
+ } | {
38
+ readonly type: "context";
39
+ readonly parts: readonly Spanned[];
40
+ } | {
41
+ readonly type: "binary";
42
+ readonly lhs: Spanned;
43
+ readonly op: BinaryOp;
44
+ readonly rhs: Spanned;
45
+ } | {
46
+ readonly type: "not";
47
+ readonly inner: Spanned;
48
+ };
49
+ interface Spanned {
50
+ readonly origin: Origin;
51
+ readonly expr: Expr;
52
+ }
53
+ type ContextExpr = Extract<Expr, {
54
+ readonly type: "context";
55
+ }>;
56
+ interface Anchor {
57
+ readonly name: string;
58
+ readonly start: number;
59
+ readonly target: SyntaxNode;
60
+ }
61
+ interface Point {
62
+ readonly row: number;
63
+ readonly column: number;
64
+ }
65
+ interface Document {
66
+ readonly text: string;
67
+ readonly root: SyntaxNode;
68
+ readonly top: SyntaxNode;
69
+ readonly anchors: readonly Anchor[];
70
+ readonly lineStarts: readonly number[];
71
+ }
72
+ type Component = number | string;
73
+ type Route = readonly Component[];
74
+ type LoE<Value> = {
75
+ readonly type: "expr";
76
+ readonly raw: string;
77
+ } | {
78
+ readonly type: "literal";
79
+ readonly value: Value;
80
+ };
81
+ type EnvValue = {
82
+ readonly type: "string";
83
+ readonly value: string;
84
+ } | {
85
+ readonly type: "number";
86
+ readonly value: number;
87
+ } | {
88
+ readonly type: "boolean";
89
+ readonly value: boolean;
90
+ };
91
+ type If = {
92
+ readonly type: "bool";
93
+ readonly value: boolean;
94
+ } | {
95
+ readonly type: "expr";
96
+ readonly raw: string;
97
+ };
98
+ type BasePermission = "default" | "read-all" | "write-all";
99
+ type Permission = Exclude<CacheMode, "write-only">;
100
+ type Permissions = {
101
+ readonly type: "base";
102
+ readonly base: BasePermission;
103
+ } | {
104
+ readonly type: "explicit";
105
+ readonly permissions: ReadonlyMap<string, Permission>;
106
+ };
107
+ declare const CACHE_MODES: readonly ["read", "write", "write-only", "none"];
108
+ type CacheMode = (typeof CACHE_MODES)[number];
109
+ interface RepositoryUses {
110
+ readonly type: "repository";
111
+ readonly raw: string;
112
+ readonly owner: string;
113
+ readonly repo: string;
114
+ readonly slug: string;
115
+ readonly subpath: Option.Option<string>;
116
+ readonly gitRef: string;
117
+ }
118
+ interface DockerUses {
119
+ readonly type: "docker";
120
+ readonly raw: string;
121
+ readonly registry: Option.Option<string>;
122
+ readonly image: string;
123
+ readonly tag: Option.Option<string>;
124
+ readonly hash: Option.Option<string>;
125
+ }
126
+ interface LocalUses {
127
+ readonly type: "local";
128
+ readonly raw: string;
129
+ }
130
+ type Uses = RepositoryUses | DockerUses | LocalUses;
131
+ type Fragment = {
132
+ readonly type: "raw";
133
+ readonly text: string;
134
+ } | {
135
+ readonly type: "pattern";
136
+ readonly pattern: RegExp;
137
+ };
138
+ interface Subfeature {
139
+ readonly after: number;
140
+ readonly fragment: Fragment;
141
+ }
142
+ type Persona = "auditor" | "pedantic" | "regular";
143
+ declare const SEVERITIES: readonly ["informational", "low", "medium", "high"];
144
+ type Severity = (typeof SEVERITIES)[number];
145
+ type Confidence = Exclude<Severity, "informational">;
146
+ type FeatureKind = {
147
+ readonly type: "normal";
148
+ } | {
149
+ readonly type: "subfeature";
150
+ readonly subfeature: Subfeature;
151
+ } | {
152
+ readonly type: "key-only";
153
+ };
154
+ type LocationKind = "primary" | "related" | "hidden";
155
+ interface SymbolicLocation {
156
+ readonly annotation: string;
157
+ readonly link: Option.Option<string>;
158
+ readonly route: Route;
159
+ readonly feature: FeatureKind;
160
+ readonly kind: LocationKind;
161
+ }
162
+ interface Comment {
163
+ readonly raw: string;
164
+ readonly start: Point;
165
+ readonly offset: number;
166
+ }
167
+ interface ConcreteFeature {
168
+ readonly start: Point;
169
+ readonly end: Point;
170
+ readonly startOffset: number;
171
+ readonly endOffset: number;
172
+ readonly text: string;
173
+ readonly comments: readonly Comment[];
174
+ }
175
+ interface Location {
176
+ readonly symbolic: SymbolicLocation;
177
+ readonly concrete: ConcreteFeature;
178
+ }
179
+ interface FindingDraft {
180
+ readonly ident: string;
181
+ readonly desc: string;
182
+ readonly url: string;
183
+ readonly severity: Severity;
184
+ readonly confidence: Confidence;
185
+ readonly persona: Persona;
186
+ readonly locations: readonly SymbolicLocation[];
187
+ readonly rawLocations: readonly Location[];
188
+ readonly tip: Option.Option<string>;
189
+ }
190
+ type ActionStepBody = {
191
+ readonly type: "uses";
192
+ readonly uses: Uses;
193
+ readonly with: LoE<ReadonlyMap<string, EnvValue>>;
194
+ } | {
195
+ readonly type: "run";
196
+ readonly run: string;
197
+ readonly shell: LoE<string>;
198
+ readonly workingDirectory: Option.Option<string>;
199
+ };
200
+ interface ActionStepModel {
201
+ readonly id: Option.Option<string>;
202
+ readonly if: Option.Option<If>;
203
+ readonly name: Option.Option<string>;
204
+ readonly env: LoE<ReadonlyMap<string, EnvValue>>;
205
+ readonly body: ActionStepBody;
206
+ }
207
+ type DockerImage = {
208
+ readonly type: "dockerfile";
209
+ } | {
210
+ readonly type: "image";
211
+ readonly image: LoE<DockerUses>;
212
+ };
213
+ type Runs = {
214
+ readonly type: "javascript";
215
+ readonly using: string;
216
+ } | {
217
+ readonly type: "composite";
218
+ readonly using: string;
219
+ readonly steps: readonly ActionStepModel[];
220
+ } | {
221
+ readonly type: "docker";
222
+ readonly using: string;
223
+ readonly image: DockerImage;
224
+ readonly env: ReadonlyMap<string, EnvValue>;
225
+ };
226
+ interface ActionModel {
227
+ readonly name: Option.Option<string>;
228
+ readonly inputs: readonly string[];
229
+ readonly runs: Runs;
230
+ }
231
+ interface RemoteUrl {
232
+ readonly href: string;
233
+ readonly protocol: string;
234
+ readonly hostname: string;
235
+ readonly pathname: string;
236
+ }
237
+ type RepoModel = {
238
+ readonly type: "remote";
239
+ readonly repo: string;
240
+ readonly url: RemoteUrl;
241
+ readonly rev: string;
242
+ } | {
243
+ readonly type: "special";
244
+ readonly repo: string;
245
+ };
246
+ interface PreCommitConfigModel {
247
+ readonly repos: readonly RepoModel[];
248
+ }
249
+ interface PreCommitHooksModel {
250
+ readonly hooks: readonly string[];
251
+ }
252
+ type UsesPattern = {
253
+ readonly type: "exact-with-ref";
254
+ readonly owner: string;
255
+ readonly repo: string;
256
+ readonly subpath: Option.Option<string>;
257
+ readonly gitRef: string;
258
+ } | {
259
+ readonly type: "exact-path";
260
+ readonly owner: string;
261
+ readonly repo: string;
262
+ readonly subpath: string;
263
+ } | {
264
+ readonly type: "exact-repo";
265
+ readonly owner: string;
266
+ readonly repo: string;
267
+ } | {
268
+ readonly type: "in-repo";
269
+ readonly owner: string;
270
+ readonly repo: string;
271
+ } | {
272
+ readonly type: "in-owner";
273
+ readonly owner: string;
274
+ } | {
275
+ readonly type: "any";
276
+ };
277
+ declare const USES_POLICIES: readonly ["any", "ref-pin", "hash-pin"];
278
+ type UsesPolicy = (typeof USES_POLICIES)[number];
279
+ declare const ALLOW_DENY: readonly ["allow", "deny"];
280
+ type AllowDeny = (typeof ALLOW_DENY)[number];
281
+ interface IgnoreRule {
282
+ readonly filename: string;
283
+ readonly line: Option.Option<number>;
284
+ readonly column: Option.Option<number>;
285
+ }
286
+ interface RuleConfig {
287
+ readonly disable: boolean;
288
+ readonly ignore: readonly IgnoreRule[];
289
+ readonly config: Option.Option<Readonly<Record<string, unknown>>>;
290
+ readonly remap: Option.Option<Severity>;
291
+ }
292
+ type PolicyEntry = readonly [UsesPattern, UsesPolicy];
293
+ interface UnpinnedUsesPolicies {
294
+ readonly tree: ReadonlyMap<string, readonly PolicyEntry[]>;
295
+ readonly fallback: UsesPolicy;
296
+ }
297
+ interface Config$1 {
298
+ readonly rules: ReadonlyMap<string, RuleConfig>;
299
+ readonly cooldownDays: number;
300
+ readonly forbiddenUses: Option.Option<{
301
+ readonly type: AllowDeny;
302
+ readonly patterns: readonly UsesPattern[];
303
+ }>;
304
+ readonly secretsAllow: ReadonlySet<string>;
305
+ readonly unpinnedUses: UnpinnedUsesPolicies;
306
+ readonly knownVulnerableAllow: ReadonlySet<string>;
307
+ readonly denyRunners: ReadonlySet<string>;
308
+ readonly allowGroups: ReadonlySet<string>;
309
+ }
310
+ interface Cooldown {
311
+ readonly defaultDays: Option.Option<number>;
312
+ }
313
+ interface UpdateModel {
314
+ readonly packageEcosystem: string;
315
+ readonly insecureExternalCodeExecution: AllowDeny;
316
+ readonly cooldown: Option.Option<Cooldown>;
317
+ readonly multiEcosystemGroup: Option.Option<string>;
318
+ }
319
+ interface DependabotModel {
320
+ readonly updates: readonly UpdateModel[];
321
+ }
322
+ type DispatchInputType = "boolean" | "choice" | "environment" | "number" | "string";
323
+ type CallInputType = Exclude<DispatchInputType, "choice" | "environment">;
324
+ interface WorkflowCallEvent {
325
+ readonly inputs: ReadonlyMap<string, CallInputType>;
326
+ readonly outputs: ReadonlyMap<string, string>;
327
+ readonly secrets: readonly string[];
328
+ }
329
+ interface WorkflowDispatchEvent {
330
+ readonly inputs: ReadonlyMap<string, DispatchInputType>;
331
+ }
332
+ type EventBody = {
333
+ readonly type: "default";
334
+ } | {
335
+ readonly type: "body";
336
+ readonly node: YamlNode;
337
+ readonly types: readonly string[];
338
+ };
339
+ type TriggerSyntax = {
340
+ readonly type: "scalar";
341
+ } | {
342
+ readonly type: "sequence";
343
+ readonly events: readonly string[];
344
+ } | {
345
+ readonly type: "mapping";
346
+ };
347
+ interface Trigger {
348
+ readonly events: ReadonlyMap<string, EventBody>;
349
+ readonly syntax: TriggerSyntax;
350
+ readonly workflowCall: Option.Option<WorkflowCallEvent>;
351
+ readonly workflowDispatch: Option.Option<WorkflowDispatchEvent>;
352
+ }
353
+ interface RunDefaults {
354
+ readonly shell: Option.Option<LoE<string>>;
355
+ readonly workingDirectory: Option.Option<string>;
356
+ }
357
+ interface Defaults {
358
+ readonly run: Option.Option<RunDefaults>;
359
+ }
360
+ type Concurrency = {
361
+ readonly type: "bare";
362
+ readonly group: string;
363
+ } | {
364
+ readonly type: "rich";
365
+ readonly group: string;
366
+ readonly cancelInProgress: LoE<boolean>;
367
+ };
368
+ type RunsOn = {
369
+ readonly type: "target";
370
+ readonly labels: readonly string[];
371
+ } | {
372
+ readonly type: "group";
373
+ readonly group: Option.Option<string>;
374
+ readonly labels: readonly string[];
375
+ };
376
+ type DeploymentEnvironment = {
377
+ readonly type: "name";
378
+ readonly name: string;
379
+ } | {
380
+ readonly type: "name-url";
381
+ readonly name: string;
382
+ readonly url: Option.Option<string>;
383
+ };
384
+ interface SharedStepFields {
385
+ readonly id: Option.Option<string>;
386
+ readonly if: Option.Option<If>;
387
+ readonly name: Option.Option<string>;
388
+ readonly env: LoE<ReadonlyMap<string, EnvValue>>;
389
+ }
390
+ type StepBody = {
391
+ readonly type: "uses";
392
+ readonly uses: Uses;
393
+ readonly with: LoE<ReadonlyMap<string, EnvValue>>;
394
+ } | {
395
+ readonly type: "run";
396
+ readonly run: string;
397
+ readonly workingDirectory: Option.Option<string>;
398
+ readonly shell: Option.Option<LoE<string>>;
399
+ };
400
+ interface StepModel extends SharedStepFields {
401
+ readonly body: StepBody;
402
+ }
403
+ type RawStep = {
404
+ readonly type: "step";
405
+ readonly step: StepModel;
406
+ } | {
407
+ readonly type: "parallel";
408
+ readonly steps: readonly StepModel[];
409
+ } | {
410
+ readonly type: "control";
411
+ };
412
+ type MatrixValue = {
413
+ readonly kind: "null";
414
+ } | {
415
+ readonly kind: "scalar";
416
+ readonly text: string;
417
+ } | {
418
+ readonly kind: "array";
419
+ readonly items: readonly MatrixValue[];
420
+ } | {
421
+ readonly kind: "object";
422
+ readonly entries: readonly (readonly [string, MatrixValue])[];
423
+ };
424
+ type MatrixRow = readonly (readonly [string, MatrixValue])[];
425
+ interface Matrix {
426
+ readonly include: LoE<readonly MatrixRow[]>;
427
+ readonly exclude: LoE<readonly MatrixRow[]>;
428
+ readonly dimensions: LoE<readonly (readonly [string, LoE<readonly MatrixValue[]>])[]>;
429
+ }
430
+ interface Strategy {
431
+ readonly matrix: Option.Option<LoE<Matrix>>;
432
+ }
433
+ interface DockerCredentials {
434
+ readonly username: Option.Option<string>;
435
+ readonly password: Option.Option<string>;
436
+ }
437
+ type Container = {
438
+ readonly type: "name";
439
+ readonly image: LoE<DockerUses>;
440
+ } | {
441
+ readonly type: "container";
442
+ readonly image: LoE<DockerUses>;
443
+ readonly credentials: Option.Option<DockerCredentials>;
444
+ readonly env: LoE<ReadonlyMap<string, EnvValue>>;
445
+ };
446
+ interface NormalJobModel {
447
+ readonly type: "normal";
448
+ readonly name: Option.Option<string>;
449
+ readonly cacheMode: Option.Option<CacheMode>;
450
+ readonly permissions: Permissions;
451
+ readonly needs: readonly string[];
452
+ readonly if: Option.Option<If>;
453
+ readonly runsOn: LoE<RunsOn>;
454
+ readonly environment: Option.Option<DeploymentEnvironment>;
455
+ readonly concurrency: Option.Option<Concurrency>;
456
+ readonly env: LoE<ReadonlyMap<string, EnvValue>>;
457
+ readonly defaults: Option.Option<Defaults>;
458
+ readonly steps: readonly RawStep[];
459
+ readonly strategy: Option.Option<Strategy>;
460
+ readonly container: Option.Option<Container>;
461
+ readonly services: readonly (readonly [string, Container])[];
462
+ }
463
+ type Secrets = {
464
+ readonly type: "inherit";
465
+ } | {
466
+ readonly type: "env";
467
+ readonly env: ReadonlyMap<string, EnvValue>;
468
+ };
469
+ interface ReusableJobModel {
470
+ readonly type: "reusable";
471
+ readonly name: Option.Option<string>;
472
+ readonly cacheMode: Option.Option<CacheMode>;
473
+ readonly permissions: Permissions;
474
+ readonly needs: readonly string[];
475
+ readonly if: Option.Option<If>;
476
+ readonly uses: Uses;
477
+ readonly with: LoE<ReadonlyMap<string, EnvValue>>;
478
+ readonly secrets: Option.Option<Secrets>;
479
+ }
480
+ type JobModel = NormalJobModel | ReusableJobModel;
481
+ interface WorkflowModel {
482
+ readonly name: Option.Option<string>;
483
+ readonly runName: Option.Option<string>;
484
+ readonly on: Trigger;
485
+ readonly cacheMode: Option.Option<CacheMode>;
486
+ readonly permissions: Permissions;
487
+ readonly env: LoE<ReadonlyMap<string, EnvValue>>;
488
+ readonly defaults: Option.Option<Defaults>;
489
+ readonly concurrency: Option.Option<Concurrency>;
490
+ readonly jobs: readonly (readonly [string, JobModel])[];
491
+ }
492
+ interface InputBase {
493
+ readonly filename: string;
494
+ readonly path: string;
495
+ readonly source: Source;
496
+ readonly document: Document;
497
+ }
498
+ interface WorkflowInput extends InputBase {
499
+ readonly kind: "workflow";
500
+ readonly model: WorkflowModel;
501
+ }
502
+ interface ActionInput extends InputBase {
503
+ readonly kind: "action";
504
+ readonly model: ActionModel;
505
+ }
506
+ interface DependabotInput extends InputBase {
507
+ readonly kind: "dependabot";
508
+ readonly model: DependabotModel;
509
+ }
510
+ interface PreCommitConfigInput extends InputBase {
511
+ readonly kind: "pre-commit-config";
512
+ readonly model: PreCommitConfigModel;
513
+ }
514
+ interface PreCommitHooksInput extends InputBase {
515
+ readonly kind: "pre-commit-hooks";
516
+ readonly model: PreCommitHooksModel;
517
+ }
518
+ type AuditInput = WorkflowInput | ActionInput | DependabotInput | PreCommitConfigInput | PreCommitHooksInput;
519
+ interface NormalJob {
520
+ readonly id: string;
521
+ readonly model: NormalJobModel;
522
+ readonly workflow: WorkflowInput;
523
+ }
524
+ interface ReusableJob {
525
+ readonly id: string;
526
+ readonly model: ReusableJobModel;
527
+ readonly workflow: WorkflowInput;
528
+ }
529
+ type Capability = "arbitrary" | "structured" | "fixed";
530
+ type StepBodyCommon = {
531
+ readonly type: "uses";
532
+ readonly uses: Uses;
533
+ readonly with: LoE<ReadonlyMap<string, EnvValue>>;
534
+ } | {
535
+ readonly type: "run";
536
+ readonly run: string;
537
+ };
538
+ interface Expansion {
539
+ readonly path: string;
540
+ readonly value: string;
541
+ readonly location: SymbolicLocation;
542
+ }
543
+ interface MatrixView {
544
+ readonly location: SymbolicLocation;
545
+ readonly expansions: readonly Expansion[];
546
+ readonly indirectlyExpanded: Option.Option<SymbolicLocation>;
547
+ readonly indirectInclusions: Option.Option<SymbolicLocation>;
548
+ readonly indirectExclusions: Option.Option<SymbolicLocation>;
549
+ }
550
+ interface StepView {
551
+ readonly kind: "workflow" | "composite";
552
+ readonly input: AuditInput;
553
+ readonly document: Document;
554
+ readonly order: readonly number[];
555
+ readonly name: Option.Option<string>;
556
+ readonly id: Option.Option<string>;
557
+ readonly if: Option.Option<If>;
558
+ readonly env: LoE<ReadonlyMap<string, EnvValue>>;
559
+ readonly body: StepBodyCommon;
560
+ readonly location: SymbolicLocation;
561
+ readonly locationWithGrip: SymbolicLocation;
562
+ readonly matrix: Option.Option<MatrixView>;
563
+ readonly envIsStatic: (context: ContextExpr) => boolean;
564
+ readonly shell: () => Option.Option<readonly [string, SymbolicLocation]>;
565
+ readonly getInput: (name: string) => Option.Option<Capability>;
566
+ readonly job: Option.Option<NormalJob>;
567
+ readonly action: Option.Option<ActionInput>;
568
+ readonly index: number;
569
+ }
570
+ type ScriptParser = (language: ScriptLanguage, text: string) => Source;
571
+ declare const GitHubError_base: Schema.Class<GitHubError, Schema.TaggedStruct<"GitHubError", {
572
+ readonly message: Schema.String;
573
+ }>, import("effect/Cause").YieldableError & {
574
+ readonly brand: unique symbol;
575
+ }>;
576
+ declare class GitHubError extends GitHubError_base {}
577
+ interface NamedRef {
578
+ readonly name: string;
579
+ readonly commit: string;
580
+ }
581
+ interface RepoRefs {
582
+ readonly branches: readonly NamedRef[];
583
+ readonly tags: readonly NamedRef[];
584
+ }
585
+ interface Advisory {
586
+ readonly id: string;
587
+ readonly severity: string;
588
+ }
589
+ type GitHubEffect<Value> = Effect.Effect<Value, GitHubError>;
590
+ type FastPath = "contained" | "absent" | "unknown";
591
+ interface Reachability {
592
+ readonly known: (slug: string) => (commit: string) => Effect.Effect<boolean>;
593
+ readonly remember: (slug: string) => (commit: string) => Effect.Effect<void>;
594
+ }
595
+ interface GitHubClient {
596
+ readonly refs: (slug: string) => GitHubEffect<RepoRefs>;
597
+ readonly exists: (slug: string) => GitHubEffect<boolean>;
598
+ readonly defaultBranch: (slug: string) => GitHubEffect<string>;
599
+ readonly peeled: (slug: string) => (sha: string) => GitHubEffect<string>;
600
+ readonly branchCommits: (slug: string) => (sha: string) => Effect.Effect<FastPath>;
601
+ readonly contains: (slug: string) => (base: string, head: string) => GitHubEffect<boolean>;
602
+ readonly advisories: (slug: string) => (version: string) => GitHubEffect<readonly Advisory[]>;
603
+ readonly reachability: Reachability;
604
+ }
605
+ interface AuditContext {
606
+ readonly config: Config$1;
607
+ readonly project: Project;
608
+ readonly parseScript: ScriptParser;
609
+ readonly github: Option.Option<GitHubClient>;
610
+ }
611
+ type Drafts = readonly FindingDraft[];
612
+ type Produced = Drafts | Effect.Effect<Drafts>;
613
+ interface RepoView {
614
+ readonly index: number;
615
+ readonly model: RepoModel;
616
+ readonly input: PreCommitConfigInput;
617
+ }
618
+ interface Audit {
619
+ readonly ident: string;
620
+ readonly desc: string;
621
+ readonly workflow?: (workflow: WorkflowInput, context: AuditContext) => Produced;
622
+ readonly normalJob?: (job: NormalJob, context: AuditContext) => Produced;
623
+ readonly reusableJob?: (job: ReusableJob, context: AuditContext) => Produced;
624
+ readonly step?: (step: StepView, context: AuditContext) => Produced;
625
+ readonly action?: (action: ActionInput, context: AuditContext) => Produced;
626
+ readonly dockerAction?: (action: ActionInput, context: AuditContext) => Produced;
627
+ readonly compositeStep?: (step: StepView, context: AuditContext) => Produced;
628
+ readonly dependabot?: (dependabot: DependabotInput, context: AuditContext) => Produced;
629
+ readonly preCommitConfig?: (config: PreCommitConfigInput, context: AuditContext) => Produced;
630
+ readonly preCommitRepo?: (repo: RepoView, context: AuditContext) => Produced;
631
+ readonly preCommitHooks?: (hooks: PreCommitHooksInput, context: AuditContext) => Produced;
632
+ readonly raw?: (input: AuditInput, context: AuditContext) => Produced;
633
+ }
634
+ declare const CONCERNS: {
635
+ readonly injection: readonly Audit[];
636
+ readonly "supply-chain": readonly Audit[];
637
+ readonly references: readonly Audit[];
638
+ readonly credentials: readonly Audit[];
639
+ readonly workflow: readonly Audit[];
640
+ readonly config: readonly Audit[];
641
+ };
642
+ type Concern = keyof typeof CONCERNS;
643
+ interface ActionlintOptions {
644
+ readonly "self-hosted-runner"?: {
645
+ readonly labels?: readonly string[];
646
+ };
647
+ readonly "config-variables"?: readonly string[] | null;
648
+ }
649
+ interface ZizmorOptions {
650
+ readonly concerns?: readonly Concern[];
651
+ readonly persona?: Persona;
652
+ readonly minSeverity?: Severity;
653
+ readonly minConfidence?: Confidence;
654
+ readonly online?: boolean;
655
+ readonly githubHost?: string;
656
+ readonly rules?: Readonly<Record<string, unknown>>;
657
+ }
658
+ export declare const actionlint: (settings?: ActionlintOptions) => Fu4Config;
659
+ export declare const zizmor: ({ concerns, ...settings }?: ZizmorOptions) => Fu4Config;
660
+ export declare const recommended: () => Fu4Config;
661
+ export type { ActionlintOptions, Concern as ZizmorConcern, Confidence as ZizmorConfidence, ZizmorOptions, Persona as ZizmorPersona, Severity as ZizmorSeverity };
662
+ //# sourceMappingURL=presets.d.mts.map