Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
]],
AESDecryptGCM: [types.int32, [
refType(types.uchar),
types.int32,
refType(types.uchar),
types.int32,
refType(types.uchar),
types.uint32,
refType(types.uchar),
refType(types.uchar),
types.uint32,
refType(types.uchar),
]],
getVersion: [types.CString, []],
});
interface ICryptoLib {
AESGCMEncrypt: (name: string, base64IV: string, base64AAD: string, base64Key: string, base64In: string) => string | null;
AESGCMDecrypt: (base64IV: string, base64AAD: string, base64Key: string, base64In: string) => string | null;
}
class CryptoLibrary implements ICryptoLib {
/**
* Encrypt / Decrypt
*
* @param name {string} Method name to execute
* @param base64IV {string}
* @param base64AAD {string}
* @param base64Key {string}