[BREAKGLASS] A fast N-API-based Node.js addon wrapping sqlcipher and FTS5 segmenting APIs.
Go to file
Fedor Indutny 26e1566203 2.2.1
2025-08-04 14:50:11 -07:00
.github/workflows chore: build profiling and production versions 2025-08-04 14:01:37 -07:00
bench v1.0.0 2025-03-12 13:44:29 -07:00
deps fix: profiling build 2025-08-04 14:50:02 -07:00
docker v1.0.0 2025-03-12 13:44:29 -07:00
lib feat: stmt.scanStats() 2025-08-04 13:40:00 -07:00
patches v1.0.0 2025-03-12 13:44:29 -07:00
src feat: stmt.scanStats() 2025-08-04 13:40:00 -07:00
test feat: include string version of error in err.code 2025-06-30 10:33:30 -07:00
.gitignore v1.0.0 2025-03-12 13:44:29 -07:00
.nvmrc v1.0.0 2025-03-12 13:44:29 -07:00
.prettierignore v1.0.0 2025-03-12 13:44:29 -07:00
.prettierrc.json v1.0.0 2025-03-12 13:44:29 -07:00
binding.gyp v1.0.0 2025-03-12 13:44:29 -07:00
docker-prebuildify.sh v1.0.0 2025-03-12 13:44:29 -07:00
Dockerfile v1.0.0 2025-03-12 13:44:29 -07:00
eslint.config.mjs v1.0.0 2025-03-12 13:44:29 -07:00
LICENSE v1.0.0 2025-03-12 13:44:29 -07:00
package.json 2.2.1 2025-08-04 14:50:11 -07:00
pnpm-lock.yaml v1.0.0 2025-03-12 13:44:29 -07:00
README.md Update sqlcipher to 4.7.0 2025-04-03 11:26:32 -07:00
rust-toolchain v1.0.0 2025-03-12 13:44:29 -07:00
tsconfig.json v1.0.0 2025-03-12 13:44:29 -07:00

@signalapp/sqlcipher

npm

A fast N-API-based Node.js addon wrapping sqlcipher and Signal-specific FTS5 segmenting APIs.

Usage

import Database from '@signalapp/sqlcipher';

const db = new Database('/path/to/db');

db.exec(`
  CREATE TABLE t (
    a INTEGER,
    b TEXT,
    c BLOB
  );
`);

const insert = db.prepare('INSERT INTO t (a, b, c) VALUES ($a, $b, $c)');
insert.run({ a: 1, b: 'hello', c: Buffer.from('world') });
insert.run({ a: 2, b: 'world', c: Buffer.from('hello') });

console.log(db.prepare('SELECT * FROM t').all());

Updating sqlcipher

On macOS:

cd deps/sqlcipher
export OPENSSL_PREFIX=`brew --prefix openssl`
export CFLAGS="-I $OPENSSL_PREFIX/include"
export LIBRARY_PATH="$LIBRARY_PATH:$OPENSSL_PREFIX/lib"
./update.sh v4.7.0
cd -

License

Copyright 2025 Signal Messenger, LLC.

Licensed under the AGPLv3: http://www.gnu.org/licenses/agpl-3.0.html