0.1.2 • Published 3 years ago

j3crypto v0.1.2

Weekly downloads
5
License
GPL-3.0-or-later
Repository
gitlab
Last release
3 years ago

J3Crypto

0J3's Crypto Wrapper

this is an experiment, and wasn't intended for usage with important data in a production environement

API

(Required Arguments are bold - Format: FunctionName(Type ArgumentName = Default,Type2 ArgumentName2 = Default2) => ReturnType)

J3Crypto.genKey(String password = '', Int KeyLength = 4096) => String

Generates a public and private keypair with a length of KeyLength and the password of password

Example:

const { publicKey, privateKey } = J3Crypto.genKey('SomePassword', 8192);

J3Crypto.encrypt(String data, String publicKey) => String

Encrypts 'data' using 'publicKey'

Example:

const encryptedData = J3Crypto.encrypt('SomeString', publicKey);

J3Crypto.decrypt(String encrData, String privateKey, String keyPassword = '')

Decrypts 'encrData' using 'privateKey'

Example:

const decryptedData = J3Crypto.decrypt(
	encryptedData,
	privateKey,
	'SomePassword'
);
0.1.2

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago