@hasna/skills 0.9.10 → 0.9.11

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.
@@ -40,16 +40,6 @@ export declare function reconcileCodexNativeHooks(options: CodexNativeHookReconc
40
40
  before: any;
41
41
  after: any;
42
42
  }[] | undefined;
43
- version: number;
44
- kind: string;
45
- journal: string;
46
- journalIntentSha256: string;
47
- stoppedSha256: string;
48
- originalPlanDigest: any;
49
- policyBeforeSha256: string;
50
- policyCurrentSha256: string;
51
- configBeforeSha256: string;
52
- configCurrentSha256: string;
53
43
  hooksSha256: string;
54
44
  nativeConfigPath: any;
55
45
  nativeVersion: string;
@@ -68,6 +58,17 @@ export declare function reconcileCodexNativeHooks(options: CodexNativeHookReconc
68
58
  manifestSha256: string;
69
59
  };
70
60
  releaseProof: SkillsCliReleaseProof | undefined;
61
+ configDiscoveryRecovery?: import("./codex-hook-discovery-recovery.js").CodexHookDiscoveryRecovery | undefined;
62
+ version: number;
63
+ kind: string;
64
+ journal: string;
65
+ journalIntentSha256: string;
66
+ stoppedSha256: string;
67
+ originalPlanDigest: any;
68
+ policyBeforeSha256: string;
69
+ policyCurrentSha256: string;
70
+ configBeforeSha256: string;
71
+ configCurrentSha256: string;
71
72
  } | undefined;
72
73
  recoveryPlanDigest?: string | undefined;
73
74
  version: number;
@@ -80,6 +81,7 @@ export declare function reconcileCodexNativeHooks(options: CodexNativeHookReconc
80
81
  nativeVersion: string;
81
82
  nativeStateVerified: boolean;
82
83
  nativeTrustPending: boolean;
84
+ bindingRefreshRequired: boolean;
83
85
  nativeExecutionVerified: boolean;
84
86
  configSha256: string;
85
87
  hooksSha256: string;
@@ -125,6 +127,7 @@ export declare function enrollCodexNativeHooks(options?: CodexNativeHookTrustOpt
125
127
  trustStatus: any;
126
128
  }[];
127
129
  nativeEligible: boolean;
130
+ bindingRefreshRequired: boolean;
128
131
  transport: string;
129
132
  existingSessionsReloaded: boolean;
130
133
  nativeExecutionVerified: boolean;
@@ -1,6 +1,7 @@
1
1
  import type { IntegrationAgent } from "./agent-adapters.js";
2
2
  import { type DiscoveryDirectory } from "./agent-discovery-directories.js";
3
3
  import { type ManagedPluginRegistrationWitness } from "./plugin-discovery.js";
4
+ import { type CodexHookDiscoveryRecovery } from "./codex-hook-discovery-recovery.js";
4
5
  export { captureDiscoveryDirectories, type DiscoveryDirectory } from "./agent-discovery-directories.js";
5
6
  export interface DiscoverySource {
6
7
  path: string;
@@ -28,7 +29,7 @@ export interface ReviewedDiscoveryInputs {
28
29
  pluginHooks: "reviewed-no-skill-injection";
29
30
  }>;
30
31
  }
31
- export declare function verifyAgentDiscovery(binding: AgentDiscoveryBinding): void;
32
+ export declare function verifyAgentDiscovery(binding: AgentDiscoveryBinding, codexRecovery?: CodexHookDiscoveryRecovery): void;
32
33
  export declare function rebindAgentDiscovery(binding: AgentDiscoveryBinding, changes: Map<string, string>): AgentDiscoveryBinding;
33
34
  /** Capture full byte witnesses for reviewed source or executable files; never import or execute them. */
34
35
  export declare function captureDiscoveryByteSources(paths: string[]): DiscoverySource[];
@@ -1,5 +1,6 @@
1
1
  import { type AgentDiscoveryBinding, type ReviewedDiscoveryInputs } from "./agent-discovery.js";
2
2
  import { type IntegrationAgent } from "./agent-adapters.js";
3
+ import type { CodexHookDiscoveryRecovery } from "./codex-hook-discovery-recovery.js";
3
4
  export type { IntegrationAgent } from "./agent-adapters.js";
4
5
  export type ContextHookEvent = "UserPromptSubmit" | "SessionStart" | "SubagentStart";
5
6
  export interface AgentRootAlias {
@@ -120,6 +121,7 @@ export declare function assertManagedAgentBridge(agent: IntegrationAgent, option
120
121
  projectDir?: string;
121
122
  projectDirs?: string[];
122
123
  profileId?: string;
124
+ codexDiscoveryRecovery?: CodexHookDiscoveryRecovery;
123
125
  }): void;
124
126
  export declare function normalizeAgentHookPrompt(agent: IntegrationAgent, event: string, prompt: string): string;
125
127
  export declare function hookContextOutput(event: string, result: {
@@ -0,0 +1,25 @@
1
+ import type { AgentDiscoveryBinding, DiscoverySource } from "./agent-discovery.js";
2
+ import { type snapshot } from "./codex-hook-trust-files.js";
3
+ type Snapshot = ReturnType<typeof snapshot>;
4
+ /** A receipt projection, not an override supplied by a CLI caller. Only this
5
+ * module can create the in-memory proof used by discovery verification. */
6
+ export interface CodexHookDiscoveryRecovery {
7
+ readonly configPath: string;
8
+ readonly beforeSha256: string;
9
+ readonly currentSha256: string;
10
+ readonly discoverySha256: string;
11
+ readonly typedProjectionSha256: string;
12
+ }
13
+ /** Called after a complete journal/intent or the current reviewed native
14
+ * transaction and exact intended trust writes have been checked. Recheck those
15
+ * writes here so a raw hash alone can never
16
+ * grant this exception. Policy bytes and recorded sources remain unchanged. */
17
+ export declare function createCodexHookDiscoveryRecovery(binding: AgentDiscoveryBinding, before: Snapshot, current: Snapshot, hooks: Array<{
18
+ key: string;
19
+ currentHash: string;
20
+ }>): CodexHookDiscoveryRecovery | undefined;
21
+ export declare function assertCodexHookDiscoveryRecovery(binding: AgentDiscoveryBinding, witness: CodexHookDiscoveryRecovery): void;
22
+ /** Verify this one historical byte witness using the already-validated native
23
+ * transition. Every other source still uses its ordinary current-file hash. */
24
+ export declare function verifiesCodexHookDiscoverySource(binding: AgentDiscoveryBinding, source: DiscoverySource, currentDigest: string | null, witness?: CodexHookDiscoveryRecovery): boolean;
25
+ export {};