Lines Matching refs:plainText
69 …async function encryptMessagePromise(symKey: cryptoFramework.SymKey, plainText: cryptoFramework.Da…
72 let encryptUpdate = await cipher.update(plainText);
95 …let plainText: cryptoFramework.DataBlob = { data: new Uint8Array(buffer.from(message, 'utf-8').buf…
96 let encryptText = await encryptMessagePromise(symKey, plainText);
98 if (plainText.data.toString() === decryptText.data.toString()) {
100 console.info('decrypt plainText: ' + buffer.from(decryptText.data).toString('utf-8'));
136 function encryptMessage(symKey: cryptoFramework.SymKey, plainText: cryptoFramework.DataBlob) {
139 let encryptUpdate = cipher.updateSync(plainText);
162 …let plainText: cryptoFramework.DataBlob = { data: new Uint8Array(buffer.from(message, 'utf-8').buf…
163 let encryptText = encryptMessage(symKey, plainText);
165 if (plainText.data.toString() === decryptText.data.toString()) {
167 console.info('decrypt plainText: ' + buffer.from(decryptText.data).toString('utf-8'));