Open Greenheart opened 2 years ago
I currently have a website that i want the pagecrypt on but i would like it to look more like my site, this is how my website looks: https://prnt.sc/AChehinQfhXX so i would like it to look more like that. Is that possible? And how can i do that. I have forked the project.
I used the command npx pagecrypt index.html encrypted-index.html mypassword
?
Add option to use a custom HTML template, and use the JS decryption code together with any html template that provides the right elements like a password form.
Or export the decryption helpers and let users create custom templates with more control.
If anyone wants this feature, feel free to submit a PR implementing this! 😊
Notes from initial research:
pagecrypt
(like the<pre>
element for writing/reading the encrypted data), and a script tag to handle the decryption logic.decryptFile({ salt, iv, ciphertext }, password)
which would expose a simple API. Or perhaps even betterdecryptFile(encryptedBase64Data, password)
, and letting the core decrypt function take care of base64 conversion, parsing the raw bytes, and then decrypting. This would be a nice separation between presentation and decryption logic.sessionStorage
support for caching keys during the same session. Perhaps there is a way to allow users to implement these features for their custom templates in some way.