@stablelib/aead
Advanced tools
Comparing version 0.0.1 to 0.1.2
10
aead.ts
@@ -5,3 +5,3 @@ // Copyright (C) 2016 Dmitry Chestnykh | ||
/** | ||
* Authenticated Encryption with Additional Data. | ||
* Authenticated Encryption with Associated Data. | ||
*/ | ||
@@ -21,3 +21,3 @@ export interface AEAD { | ||
/** | ||
* Encrypts and authenticates plaintext, authenticates additional data, | ||
* Encrypts and authenticates plaintext, authenticates associated data, | ||
* and returns ciphertext, which includes authentication tag. | ||
@@ -28,3 +28,3 @@ * | ||
*/ | ||
seal(nonce: Uint8Array, plaintext: Uint8Array, additionalData?: Uint8Array, | ||
seal(nonce: Uint8Array, plaintext: Uint8Array, associatedData?: Uint8Array, | ||
dst?: Uint8Array): Uint8Array; | ||
@@ -34,3 +34,3 @@ | ||
* Authenticates ciphertext (which includes authentication tag) and | ||
* additional data, decrypts ciphertext and returns decrypted plaintext. | ||
* associated data, decrypts ciphertext and returns decrypted plaintext. | ||
* | ||
@@ -42,3 +42,3 @@ * If authentication fails, it returns null. | ||
*/ | ||
open(nonce: Uint8Array, ciphertext: Uint8Array, additionalData?: Uint8Array, | ||
open(nonce: Uint8Array, ciphertext: Uint8Array, associatedData?: Uint8Array, | ||
dst?: Uint8Array): Uint8Array | null; | ||
@@ -45,0 +45,0 @@ |
/** | ||
* Authenticated Encryption with Additional Data. | ||
* Authenticated Encryption with Associated Data. | ||
*/ | ||
@@ -15,3 +15,3 @@ export interface AEAD { | ||
/** | ||
* Encrypts and authenticates plaintext, authenticates additional data, | ||
* Encrypts and authenticates plaintext, authenticates associated data, | ||
* and returns ciphertext, which includes authentication tag. | ||
@@ -22,6 +22,6 @@ * | ||
*/ | ||
seal(nonce: Uint8Array, plaintext: Uint8Array, additionalData?: Uint8Array, dst?: Uint8Array): Uint8Array; | ||
seal(nonce: Uint8Array, plaintext: Uint8Array, associatedData?: Uint8Array, dst?: Uint8Array): Uint8Array; | ||
/** | ||
* Authenticates ciphertext (which includes authentication tag) and | ||
* additional data, decrypts ciphertext and returns decrypted plaintext. | ||
* associated data, decrypts ciphertext and returns decrypted plaintext. | ||
* | ||
@@ -33,3 +33,3 @@ * If authentication fails, it returns null. | ||
*/ | ||
open(nonce: Uint8Array, ciphertext: Uint8Array, additionalData?: Uint8Array, dst?: Uint8Array): Uint8Array | null; | ||
open(nonce: Uint8Array, ciphertext: Uint8Array, associatedData?: Uint8Array, dst?: Uint8Array): Uint8Array | null; | ||
/** | ||
@@ -36,0 +36,0 @@ * Wipes state from memory. |
{ | ||
"name": "@stablelib/aead", | ||
"version": "0.0.1", | ||
"description": "AEAD interface declaration (authenticated encryption with additional data)", | ||
"version": "0.1.2", | ||
"description": "AEAD interface declaration (authenticated encryption with associated data)", | ||
"main": "./dist/aead.js", | ||
@@ -6,0 +6,0 @@ "typings": "./dist/aead.d.ts", |