New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

sqlite-crypto

Package Overview
Dependencies
Maintainers
2
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sqlite-crypto

Handles SQLite databases that need to be encrypted

latest
Source
npmnpm
Version
1.1.0
Version published
Maintainers
2
Created
Source

SQLite Crypto

Using node-sqlite3, handles SQLite databases that need to be encrypted. It comes with SQLite so there's no need to install an external library.

Install

npm install sqlite-crypto

Usage

var crypts = require('sqlite-crypto');

// Initialize it.
var db = crypts.init({
    file: 'Path to your .db file relative to root', // Default '/db.db'
    password: 'supersecretpassword', // Default '6yhbVFT6AlSkDjFhG'
    algorithm: 'aes-256-ctr',
    encrypt_offset: 700, //Default 700. The time in milliseconds to wait before re-encrypting the database file. Helps avoid unnecessary decrypt/encrypt in rapid succession
});

//Run a query and get a promises. Promise returns errors, response.
db.run({
  sql: "SOME cray SQLs",
  method: "sqlite3 methods(like all, get, etc). Default is run"
}).then(function(error, response){
  console.log(errors);
  console.log(respnse);  
});

More information

See the node-sqlite3 API documentation in the wiki. Written by Mediafly Inc.

Keywords

Node

FAQs

Package last updated on 06 Jan 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts