browserPGP | Decrypt
-
+
@@ -16,6 +16,7 @@
openpgp.initWorker({ path:'openpgp.worker.min.js' }) // set the relative web worker path
const encryptDecryptFunction = async() => {
+ document.getElementById("progressbar").className = "progress-bar progress-bar-striped progress-bar-animated";
// put keys in backtick (``) to avoid errors caused by spaces or tabs
const privkey = document.getElementById("privKey").value
const passphrase = document.getElementById("pass").value
@@ -32,8 +33,8 @@
}
openpgp.decrypt(options).then(plaintext => {
- console.log(plaintext.data)
document.getElementById("result").value = plaintext.data;
+ document.getElementById("progressbar").className = "progress-bar bg-success";
})
}
@@ -91,12 +92,15 @@
+
+
+
-
+
diff --git a/encrypt.html b/encrypt.html
index 84011e8..cf071d6 100644
--- a/encrypt.html
+++ b/encrypt.html
@@ -2,7 +2,7 @@
browserPGP | Encrypt
-
+
@@ -16,6 +16,7 @@
openpgp.initWorker({ path:'openpgp.worker.min.js' }) // set the relative web worker path
const encryptDecryptFunction = async() => {
+ document.getElementById("progressbar").className = "progress-bar progress-bar-striped progress-bar-animated";
// put keys in backtick (``) to avoid errors caused by spaces or tabs
const pubkey = document.getElementById("pubKey").value
@@ -29,6 +30,7 @@
openpgp.encrypt(options).then(ciphertext => {
encrypted = ciphertext.data // '-----BEGIN PGP MESSAGE ... END PGP MESSAGE-----'
document.getElementById("result").value = encrypted;
+ document.getElementById("progressbar").className = "progress-bar bg-success";
})
}
@@ -80,7 +82,7 @@
-
+
diff --git a/gen.html b/gen.html
index 81df982..56a1303 100644
--- a/gen.html
+++ b/gen.html
@@ -2,7 +2,7 @@
browserPGP | Key Gen
-
+
@@ -93,6 +93,9 @@
This may take some time and cause browser lag.
+