Graphorin API reference v0.1.0
Graphorin API reference / @graphorin/store-sqlite-encrypted / EncryptDatabaseOptions
Interface: EncryptDatabaseOptions
Defined in: packages/store-sqlite-encrypted/src/encrypt.ts:36
Options for encryptDatabase.
Stable
Properties
| Property | Modifier | Type | Description | Defined in |
|---|---|---|---|---|
cipher? | readonly | EncryptionCipher | Cipher selection. Default 'sqlcipher' (SQLCipher v4 compatible). | packages/store-sqlite-encrypted/src/encrypt.ts:44 |
overwriteTarget? | readonly | boolean | If true, overwrite an existing targetPath instead of failing. Default false. | packages/store-sqlite-encrypted/src/encrypt.ts:56 |
passphrase | readonly | string | Buffer<ArrayBufferLike> | Passphrase for the new encrypted DB. | packages/store-sqlite-encrypted/src/encrypt.ts:42 |
sourcePath | readonly | string | Path to the existing unencrypted source DB. | packages/store-sqlite-encrypted/src/encrypt.ts:38 |
swap? | readonly | boolean | If true, atomically rename targetPath -> sourcePath after the integrity check passes. The original sourcePath is renamed to ${sourcePath}.bak.${timestamp} so an operator can recover. Default false — the CLI does the swap explicitly. | packages/store-sqlite-encrypted/src/encrypt.ts:51 |
targetPath | readonly | string | Path the encrypted output is written to. Must not exist. | packages/store-sqlite-encrypted/src/encrypt.ts:40 |