envpkt 0.4.2 → 0.6.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.
- package/README.md +14 -14
- package/dist/cli.js +247 -81
- package/dist/index.d.ts +55 -7
- package/dist/index.js +185 -68
- package/package.json +3 -2
- package/schemas/envpkt.schema.json +11 -11
package/README.md
CHANGED
|
@@ -97,7 +97,7 @@ And a more complete one:
|
|
|
97
97
|
|
|
98
98
|
version = 1
|
|
99
99
|
|
|
100
|
-
[
|
|
100
|
+
[identity]
|
|
101
101
|
name = "billing-service"
|
|
102
102
|
consumer = "agent"
|
|
103
103
|
description = "Payment processing agent"
|
|
@@ -158,13 +158,13 @@ age-keygen -o identity.txt
|
|
|
158
158
|
Add the public key to your config and the identity file to `.gitignore`:
|
|
159
159
|
|
|
160
160
|
```toml
|
|
161
|
-
[
|
|
161
|
+
[identity]
|
|
162
162
|
name = "my-agent"
|
|
163
163
|
recipient = "age1ql3z7hjy54pw3hyww5ayyfg7zqgvc7w3j2elw8zmrj2kg5sfn9aqmcac8p"
|
|
164
|
-
|
|
164
|
+
key_file = "identity.txt"
|
|
165
165
|
```
|
|
166
166
|
|
|
167
|
-
The `
|
|
167
|
+
The `key_file` path supports `~` expansion and environment variables (`$VAR`, `${VAR}`), so you can use paths like `~/keys/identity.txt` or `$KEYS_DIR/identity.txt`. Relative paths are resolved from the config file's directory. When omitted, envpkt falls back to `ENVPKT_AGE_KEY_FILE` env var, then `~/.envpkt/age-key.txt`.
|
|
168
168
|
|
|
169
169
|
### Seal
|
|
170
170
|
|
|
@@ -233,7 +233,7 @@ expires = "2026-11-01"
|
|
|
233
233
|
version = 1
|
|
234
234
|
catalog = "../../infra/envpkt.toml"
|
|
235
235
|
|
|
236
|
-
[
|
|
236
|
+
[identity]
|
|
237
237
|
name = "data-pipeline"
|
|
238
238
|
consumer = "agent"
|
|
239
239
|
secrets = ["DATABASE_URL", "REDIS_URL"]
|
|
@@ -255,7 +255,7 @@ This produces a self-contained config with catalog metadata merged in and agent
|
|
|
255
255
|
|
|
256
256
|
- Each field in the agent's `[secret.KEY]` override **replaces** the catalog field (shallow merge)
|
|
257
257
|
- Omitted fields keep the catalog value
|
|
258
|
-
- `
|
|
258
|
+
- `identity.secrets` is the source of truth for which keys the agent needs
|
|
259
259
|
|
|
260
260
|
## How envpkt Compares
|
|
261
261
|
|
|
@@ -267,7 +267,7 @@ The agentic credential space is splitting into approaches. Here's where envpkt f
|
|
|
267
267
|
| **What agents see** | Structured metadata (capabilities, constraints, expiration) | Raw secret values | Nothing (proxy handles it) | Nothing (autofill handles it) | Raw secret values |
|
|
268
268
|
| **MCP server** | Yes | Yes | No | No | Yes |
|
|
269
269
|
| **Encryption at rest** | age sealed packets | Git-crypt | N/A (proxy model) | Vault encryption | Vault encryption |
|
|
270
|
-
| **Per-agent scoping** | Yes (
|
|
270
|
+
| **Per-agent scoping** | Yes (identity.secrets, capabilities) | Yes (policies) | Yes (proxy rules) | No | Yes (policies) |
|
|
271
271
|
| **Fleet health monitoring** | Yes (fleet scan, aggregated audit) | No | No | No | No |
|
|
272
272
|
| **Credential metadata** | Rich (purpose, capabilities, rotation, lifecycle) | Minimal | Minimal | Minimal | Moderate |
|
|
273
273
|
| **Adoption path** | Scan existing env vars, add metadata incrementally | New secret storage workflow | Proxy configuration | Browser extension | API integration |
|
|
@@ -285,9 +285,9 @@ Generate an `envpkt.toml` template in the current directory.
|
|
|
285
285
|
```bash
|
|
286
286
|
envpkt init # Basic template
|
|
287
287
|
envpkt init --from-fnox # Scaffold from fnox.toml
|
|
288
|
-
envpkt init --
|
|
288
|
+
envpkt init --identity --name "my-agent" # Include identity section
|
|
289
289
|
envpkt init --catalog "../infra/envpkt.toml" # Reference a shared catalog
|
|
290
|
-
envpkt init --
|
|
290
|
+
envpkt init --identity --name "bot" --capabilities "read,write" --expires "2027-01-01"
|
|
291
291
|
```
|
|
292
292
|
|
|
293
293
|
### `envpkt audit`
|
|
@@ -354,13 +354,13 @@ envpkt seal -c path/to/envpkt.toml # Specify config path
|
|
|
354
354
|
envpkt seal --profile staging # Use a specific fnox profile for value resolution
|
|
355
355
|
```
|
|
356
356
|
|
|
357
|
-
Requires `
|
|
357
|
+
Requires `identity.recipient` (age public key) in your config. Values are resolved via cascade:
|
|
358
358
|
|
|
359
359
|
1. **fnox** (if available)
|
|
360
360
|
2. **Environment variables** (e.g. `OPENAI_API_KEY` in your shell)
|
|
361
361
|
3. **Interactive prompt** (asks you to paste each value)
|
|
362
362
|
|
|
363
|
-
After sealing, each secret gets an `encrypted_value` field. At boot time, `envpkt exec` or `boot()` automatically decrypts sealed values using the `
|
|
363
|
+
After sealing, each secret gets an `encrypted_value` field. At boot time, `envpkt exec` or `boot()` automatically decrypts sealed values using the `identity.key_file` path (or the default `~/.envpkt/age-key.txt`).
|
|
364
364
|
|
|
365
365
|
See [`examples/sealed-agent.toml`](./examples/sealed-agent.toml) for a complete example.
|
|
366
366
|
|
|
@@ -645,12 +645,12 @@ Each `[secret.<KEY>]` section describes a secret:
|
|
|
645
645
|
| **Sealed** | `encrypted_value` | Age-encrypted secret value (safe to commit) |
|
|
646
646
|
| **Enforcement** | `required`, `tags` | Filtering, grouping, and policy |
|
|
647
647
|
|
|
648
|
-
###
|
|
648
|
+
### Identity
|
|
649
649
|
|
|
650
|
-
The optional `[
|
|
650
|
+
The optional `[identity]` section identifies the consumer of these credentials:
|
|
651
651
|
|
|
652
652
|
```toml
|
|
653
|
-
[
|
|
653
|
+
[identity]
|
|
654
654
|
name = "data-pipeline-agent"
|
|
655
655
|
consumer = "agent" # agent | service | developer | ci
|
|
656
656
|
description = "ETL pipeline processor"
|