Skip to content

C crypto functions to be used in Vibrato Notes desktop & mobile.

Notifications You must be signed in to change notification settings

Open-App-Library/Vibrato-Crypto-Utils

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Vibrato-Crypto

To compile:

The whole library is just two files vibrato-crypto.h and vibrato-crypto.c.

The library depends on libsodium.

API

int vcrypto_init();

int vcrypto_get_privatekey(unsigned char *privatekey, const unsigned char *email, const char *password);
int vcrypto_get_publickey(unsigned char *publickey, const unsigned char *privatekey);

int vcrypto_encrypt_string_len(const int message_len);
int vcrypto_decrypt_string_len(const unsigned char *encrypted_string, const int encrypted_string_len);

int vcrypto_encrypt_string(char *encrypted,
                           const unsigned char *key,
                           const unsigned char *message, const unsigned long long message_len);

int vcrypto_decrypt_string(unsigned char *decrypted, int decrypted_len,
                           const unsigned char *key,
                           const unsigned char *encrypted_string, const int encrypted_string_len);

About

C crypto functions to be used in Vibrato Notes desktop & mobile.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published