@le-space/shared-types 0.9.9 → 0.11.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.
Files changed (2) hide show
  1. package/index.d.ts +47 -3
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -86,6 +86,23 @@ interface CrnRecord {
86
86
  resolved_ip?: string | null;
87
87
  geo_source?: string | null;
88
88
  system_usage?: CrnSystemUsage | null;
89
+ /** Registered owner of the node (corechannel aggregate). */
90
+ owner?: string | null;
91
+ /** Where the node's rewards go (crns.json); names the operator when owner is absent. */
92
+ payment_receiver_address?: string | null;
93
+ /** aleph-vm version, from crns.json or the node's /status/config. */
94
+ version?: string | null;
95
+ /** crns.json's flag; does not say whether SEV-SNP or only SEV / SEV-ES. */
96
+ confidential_support?: boolean;
97
+ /** CPU features from /about/usage/system, e.g. ["sev", "sev_es", "sev_snp"]. */
98
+ cpu_features?: string[] | null;
99
+ /** TEE properties from /about/usage/system; present for SEV-SNP nodes. */
100
+ tee?: CrnTeeProperties | null;
101
+ }
102
+ interface CrnTeeProperties {
103
+ sev_snp?: {
104
+ supported_vcpu_types?: string[];
105
+ };
89
106
  }
90
107
  type ReferenceStatus = 'processed' | 'pending' | 'rejected' | 'removing' | 'removed' | 'unknown' | 'missing';
91
108
  interface RuntimeMetadata {
@@ -184,7 +201,7 @@ interface DeploymentResult {
184
201
  response?: AlephBroadcastResponse;
185
202
  rejectionReason?: string | null;
186
203
  }
187
- type DeploymentProgressStage = "idle" | "validating" | "loading-manifest" | "verifying-rootfs" | "loading-pricing" | "loading-balance" | "selecting-crn" | "building-message" | "signing-message" | "broadcasting" | "notifying-crn" | "waiting-for-aleph" | "deployment-confirmed" | "deployment-rejected" | "publishing-bootstrap" | "building-delete-message" | "signing-delete-message" | "broadcasting-delete" | "delete-completed" | "refreshing-instances" | "completed" | "error";
204
+ type DeploymentProgressStage = "idle" | "validating" | "loading-manifest" | "verifying-rootfs" | "loading-pricing" | "loading-balance" | "selecting-crn" | "building-message" | "signing-message" | "broadcasting" | "notifying-crn" | "preparing-confidential" | "attesting-guest" | "unlocking-guest" | "waiting-for-aleph" | "deployment-confirmed" | "deployment-rejected" | "publishing-bootstrap" | "building-delete-message" | "signing-delete-message" | "broadcasting-delete" | "delete-completed" | "refreshing-instances" | "completed" | "error";
188
205
  interface DeploymentProgressEvent {
189
206
  stage: DeploymentProgressStage;
190
207
  label: string;
@@ -224,6 +241,33 @@ interface AlephAggregateContent<T = Record<string, unknown>> {
224
241
  content: T;
225
242
  time: number;
226
243
  }
244
+ /** TEE mode on the wire; absent or "sev" is the legacy SEV / SEV-ES flow. */
245
+ type TeeMode = "sev" | "sev_snp" | "tdx";
246
+ /** Expected launch registers of a measured mode (sev_snp declares `launch`). */
247
+ interface LaunchMeasurement {
248
+ platform: "sev_snp" | "tdx";
249
+ registers: Record<string, string>;
250
+ /** QEMU CPU model the registers were computed for, e.g. "EPYC-v4". */
251
+ vcpu_type?: string;
252
+ }
253
+ /**
254
+ * `environment.trusted_execution` of a confidential instance, as aleph-rs
255
+ * (`aleph-types`, TrustedExecutionEnvironment) serialises it. Legacy SEV uses
256
+ * `firmware` and `policy`; the measured modes (sev_snp, tdx) need `runtime`
257
+ * and `measurements` instead.
258
+ */
259
+ interface TrustedExecution {
260
+ /** OVMF firmware item hash (legacy SEV only). */
261
+ firmware?: string;
262
+ /** AMD SEV policy bits (legacy) or the SEV-SNP 64-bit guest policy. */
263
+ policy?: number;
264
+ mode?: TeeMode;
265
+ /** STORE item hash of the measured runtime bundle (measured modes only). */
266
+ runtime?: string;
267
+ measurements?: LaunchMeasurement[];
268
+ /** In-guest attestation port; the runtime bundle's default (8443) if absent. */
269
+ attestation_port?: number;
270
+ }
227
271
  interface AlephInstanceContent {
228
272
  address: string;
229
273
  time: number;
@@ -239,7 +283,7 @@ interface AlephInstanceContent {
239
283
  reproducible?: boolean;
240
284
  shared_cache?: boolean;
241
285
  hypervisor: "qemu";
242
- trusted_execution?: Record<string, unknown>;
286
+ trusted_execution?: TrustedExecution;
243
287
  };
244
288
  resources: {
245
289
  vcpus: number;
@@ -354,4 +398,4 @@ interface UcanStoreBootstrapValidationResult {
354
398
  }
355
399
  declare function validateUcanStoreBootstrapPackage(value: unknown): UcanStoreBootstrapValidationResult;
356
400
 
357
- export { type AlephAggregateContent, type AlephBroadcastMessage, type AlephBroadcastResponse, type AlephInstanceContent, type AlephMessageType, type AlephSenderChain, type CrnRecord, type CrnSystemUsage, type DeploymentInspectionResult, type DeploymentIntent, type DeploymentIntentEnvelope, type DeploymentProgressEvent, type DeploymentProgressListener, type DeploymentProgressStage, type DeploymentResult, type GatewayProbeStatus, type InstanceAllocation, type InstanceAllocationNode, type InstanceAllocationPeriod, type InstanceExecution, type InstanceExecutionNetworking, type InstanceExecutionStatus, type InstanceRuntimeDetails, type InstanceWebAccess, type MessageHasher, type MessageInspectionResult, type MessageReference, type MessageSigner, type MessageStatus, type PortForwardAggregate, type PortForwardAggregateEntry, type PortForwardFlags, type PortMapping, type ReferenceStatus, type RootfsInstallStrategy, type RootfsManifest, type RootfsManifestState, type RootfsRequiredPortForward, type RootfsResolution, type RuntimeDiagnostics, type RuntimeMetadata, type UcanStoreBootstrapPackage, type UcanStoreBootstrapValidationResult, type VmBootstrapConfigAggregate, type VmBootstrapConfigBootstrap, type VmBootstrapConfigRecord, type VmBootstrapConfigRuntime, type VmBootstrapConfigSignalRecord, type VmBootstrapConfigSignalType, type VmBootstrapConfigStatus, validateUcanStoreBootstrapPackage };
401
+ export { type AlephAggregateContent, type AlephBroadcastMessage, type AlephBroadcastResponse, type AlephInstanceContent, type AlephMessageType, type AlephSenderChain, type CrnRecord, type CrnSystemUsage, type CrnTeeProperties, type DeploymentInspectionResult, type DeploymentIntent, type DeploymentIntentEnvelope, type DeploymentProgressEvent, type DeploymentProgressListener, type DeploymentProgressStage, type DeploymentResult, type GatewayProbeStatus, type InstanceAllocation, type InstanceAllocationNode, type InstanceAllocationPeriod, type InstanceExecution, type InstanceExecutionNetworking, type InstanceExecutionStatus, type InstanceRuntimeDetails, type InstanceWebAccess, type LaunchMeasurement, type MessageHasher, type MessageInspectionResult, type MessageReference, type MessageSigner, type MessageStatus, type PortForwardAggregate, type PortForwardAggregateEntry, type PortForwardFlags, type PortMapping, type ReferenceStatus, type RootfsInstallStrategy, type RootfsManifest, type RootfsManifestState, type RootfsRequiredPortForward, type RootfsResolution, type RuntimeDiagnostics, type RuntimeMetadata, type TeeMode, type TrustedExecution, type UcanStoreBootstrapPackage, type UcanStoreBootstrapValidationResult, type VmBootstrapConfigAggregate, type VmBootstrapConfigBootstrap, type VmBootstrapConfigRecord, type VmBootstrapConfigRuntime, type VmBootstrapConfigSignalRecord, type VmBootstrapConfigSignalType, type VmBootstrapConfigStatus, validateUcanStoreBootstrapPackage };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@le-space/shared-types",
3
- "version": "0.9.9",
3
+ "version": "0.11.0",
4
4
  "description": "Shared type contracts for the Relay Button tooling monorepo.",
5
5
  "license": "MIT",
6
6
  "type": "module",