Skip to content

Sciter binding for Botan crypto library

License

Notifications You must be signed in to change notification settings

MustafaHi/Sciter-Botan

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

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