Skip to content

Latest commit

 

History

History
37 lines (26 loc) · 1.15 KB

README.md

File metadata and controls

37 lines (26 loc) · 1.15 KB

Sciter-Botan

Sciter binding for Botan cryptography library

Version : 2.0
API / Usage Guide
Setup Guide
Change Log & Features
Dev Guide
More information in the wiki

Provide easy to use API for Botan to Sciter's script

var key  = Botan.hash("SHA-256", "secret");
var data = "will be secret";

const crypto = await Botan.cipher("AES-256/CBC", data, key);
// returns Object with Data and IV(nonce)

crypto.data
// hex code of the encrypted data

crypto.iv
// IV(nonce) used for encryption

And to decrypt that data

const decrypt = await Botan.decipher("AES-256/CBC", crypto.data, key, crypto.iv);

decrypt.data
// String "will be secret"

More examples and the entire API in the wiki