mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-04-19 14:53:50 +02:00
Linter bracket spacing 1
This commit is contained in:
@@ -27,12 +27,12 @@ async function encrypt(plaintext, key) {
|
||||
let sharedKey = await window.crypto.subtle.importKey(
|
||||
'raw',
|
||||
stdAESKey(key),
|
||||
{name: 'AES-GCM', length: 256},
|
||||
{ name: 'AES-GCM', length: 256 },
|
||||
true,
|
||||
['encrypt']
|
||||
);
|
||||
let cipher = await window.crypto.subtle.encrypt(
|
||||
{name: 'AES-GCM', iv},
|
||||
{ name: 'AES-GCM', iv },
|
||||
sharedKey,
|
||||
new TextEncoder().encode(plaintext)
|
||||
);
|
||||
@@ -49,12 +49,12 @@ async function decrypt(ciphertext, key) {
|
||||
let sharedKey = await window.crypto.subtle.importKey(
|
||||
'raw',
|
||||
stdAESKey(key),
|
||||
{name: 'AES-GCM', length: 256},
|
||||
{ name: 'AES-GCM', length: 256 },
|
||||
true,
|
||||
['decrypt']
|
||||
);
|
||||
let plaintext = await window.crypto.subtle.decrypt(
|
||||
{name: 'AES-GCM', iv: text.slice(0, 12)},
|
||||
{ name: 'AES-GCM', iv: text.slice(0, 12) },
|
||||
sharedKey,
|
||||
text.slice(12)
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user