@cipherstash/stack 0.15.2 → 0.15.3
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/CHANGELOG.md +6 -0
- package/README.md +19 -19
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -47,7 +47,7 @@ pnpm add @cipherstash/stack
|
|
|
47
47
|
### 1. Initialize and authenticate your project
|
|
48
48
|
|
|
49
49
|
```bash
|
|
50
|
-
npx
|
|
50
|
+
npx stash init
|
|
51
51
|
```
|
|
52
52
|
|
|
53
53
|
The wizard will authenticate you, walk you through choosing a database connection method, build an encryption schema, and install the required dependencies.
|
|
@@ -438,25 +438,25 @@ await secrets.delete("DATABASE_URL")
|
|
|
438
438
|
|
|
439
439
|
## CLI Reference
|
|
440
440
|
|
|
441
|
-
The CLI is available via `npx
|
|
441
|
+
The CLI is available via `npx stash` after install.
|
|
442
442
|
|
|
443
|
-
### `npx
|
|
443
|
+
### `npx stash auth`
|
|
444
444
|
|
|
445
445
|
Authenticate with CipherStash.
|
|
446
446
|
|
|
447
447
|
```bash
|
|
448
|
-
npx
|
|
448
|
+
npx stash auth login
|
|
449
449
|
```
|
|
450
450
|
|
|
451
451
|
This runs the device code flow: it opens your browser, you confirm the code, and a token is saved to `~/.cipherstash/auth.json`. No environment variables or credentials files are needed for local development.
|
|
452
452
|
|
|
453
|
-
### `npx
|
|
453
|
+
### `npx stash init`
|
|
454
454
|
|
|
455
455
|
Initialize CipherStash for your project with an interactive wizard.
|
|
456
456
|
|
|
457
457
|
```bash
|
|
458
|
-
npx
|
|
459
|
-
npx
|
|
458
|
+
npx stash init
|
|
459
|
+
npx stash init --supabase
|
|
460
460
|
```
|
|
461
461
|
|
|
462
462
|
The wizard will:
|
|
@@ -464,31 +464,31 @@ The wizard will:
|
|
|
464
464
|
2. Bind your device to the default Keyset
|
|
465
465
|
3. Choose your database connection method (Drizzle ORM, Supabase JS, Prisma, or Raw SQL)
|
|
466
466
|
4. Build an encryption schema interactively or use a placeholder, then generate the encryption client file
|
|
467
|
-
5. Install
|
|
467
|
+
5. Install `stash` as a dev dependency for database tooling
|
|
468
468
|
|
|
469
|
-
After init, run `npx
|
|
469
|
+
After init, run `npx stash db setup` to configure your database.
|
|
470
470
|
|
|
471
471
|
| Flag | Description |
|
|
472
472
|
|------|-------------|
|
|
473
473
|
| `--supabase` | Use Supabase-specific setup flow |
|
|
474
474
|
|
|
475
|
-
### `npx
|
|
475
|
+
### `npx stash secrets`
|
|
476
476
|
|
|
477
477
|
Manage encrypted secrets from the terminal.
|
|
478
478
|
|
|
479
479
|
```bash
|
|
480
|
-
npx
|
|
481
|
-
npx
|
|
482
|
-
npx
|
|
483
|
-
npx
|
|
480
|
+
npx stash secrets set -name DATABASE_URL -value "postgres://..." -environment production
|
|
481
|
+
npx stash secrets get -name DATABASE_URL -environment production
|
|
482
|
+
npx stash secrets list -environment production
|
|
483
|
+
npx stash secrets delete -name DATABASE_URL -environment production
|
|
484
484
|
```
|
|
485
485
|
|
|
486
486
|
| Command | Flags | Aliases | Description |
|
|
487
487
|
|-----|----|-----|-------|
|
|
488
|
-
| `npx
|
|
489
|
-
| `npx
|
|
490
|
-
| `npx
|
|
491
|
-
| `npx
|
|
488
|
+
| `npx stash secrets set` | `-name`, `-value`, `-environment` | `-n`, `-V`, `-e` | Encrypt and store a secret |
|
|
489
|
+
| `npx stash secrets get` | `-name`, `-environment` | `-n`, `-e` | Retrieve and decrypt a secret |
|
|
490
|
+
| `npx stash secrets list` | `-environment` | `-e` | List all secret names in an environment |
|
|
491
|
+
| `npx stash secrets delete` | `-name`, `-environment`, `-yes` | `-n`, `-e`, `-y` | Delete a secret (prompts for confirmation unless `-yes`) |
|
|
492
492
|
|
|
493
493
|
## Configuration
|
|
494
494
|
|
|
@@ -676,7 +676,7 @@ If you are migrating from `@cipherstash/protect`, the following table maps the o
|
|
|
676
676
|
| `csColumn(name)` | `encryptedColumn(name)` | `@cipherstash/stack/schema` |
|
|
677
677
|
| `import { LockContext } from "@cipherstash/protect/identify"` | `import { LockContext } from "@cipherstash/stack/identity"` | `@cipherstash/stack/identity` |
|
|
678
678
|
| N/A | `Secrets` class | `@cipherstash/stack/secrets` |
|
|
679
|
-
| N/A | CLI | `npx
|
|
679
|
+
| N/A | CLI | `npx stash` |
|
|
680
680
|
|
|
681
681
|
All method signatures on the encryption client (`encrypt`, `decrypt`, `encryptModel`, etc.) remain the same. The `Result` pattern (`data` / `failure`) is unchanged.
|
|
682
682
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cipherstash/stack",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.3",
|
|
4
4
|
"description": "CipherStash Stack for TypeScript and JavaScript",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"encrypted",
|
|
@@ -197,7 +197,7 @@
|
|
|
197
197
|
},
|
|
198
198
|
"dependencies": {
|
|
199
199
|
"@byteslice/result": "0.2.0",
|
|
200
|
-
"@cipherstash/protect-ffi": "0.21.
|
|
200
|
+
"@cipherstash/protect-ffi": "0.21.4",
|
|
201
201
|
"evlog": "1.9.0",
|
|
202
202
|
"uuid": "13.0.0",
|
|
203
203
|
"zod": "3.24.2"
|