588
submitted 1 week ago by cm0002@lemy.lol to c/linux@programming.dev
you are viewing a single comment's thread
view the rest of the comments
[-] bearboiblake@pawb.social 5 points 1 week ago* (last edited 1 week ago)

Who said anything about a website? You said browser. You can run fully-local resources in a browser, such as browser extensions, locally hosted tools, even just running in a .html file on your local disk somewhere. Javascript also isn't the only option available to solve this problem.

[-] tux0r@snac.rosaelefanten.org -4 points 1 week ago

Not sure if you're just trolling at this point.

You said:

Of course you can do secure encryption in a browser.

No, you can't. I explained why.

[-] bearboiblake@pawb.social 5 points 1 week ago

...and I just explained to you how you can?

[-] tux0r@snac.rosaelefanten.org -2 points 1 week ago

Ok, I'll bite:

You can run fully-local resources in a browser, such as browser extensions, locally hosted tools, even just running in a .html file on your local disk somewhere.

How would you do that without violating essential security measurements?

[-] bearboiblake@pawb.social 3 points 1 week ago
  1. Create or download an implementation of your preferred encryption algorithm for Javascript (or use some WebAssembly alternative). e.g. https://github.com/ricmoo/aes-js
  2. Run the implementation on your local computer and open it in a browser.

Hope this helps.

[-] tux0r@snac.rosaelefanten.org -1 points 1 week ago

You are aware that WASM requires JS, right?
I mean, yes, running the application itself would be secure, but that's not in the browser. You cannot trust your browser. Ever.

[-] bearboiblake@pawb.social 3 points 1 week ago* (last edited 1 week ago)

You are aware that WASM requires JS, right?

I think you're mistaken, there. WASM is often used alongside Javascript, but beyond the one-liner to fetch and load it, there's actually nothing which inherently requires JS beyond that.

Can you explain why you feel that locally running Javascript is more insecure than using, say, locally running Python code, for encryption?

[-] tux0r@snac.rosaelefanten.org -1 points 1 week ago* (last edited 1 week ago)

WASM is often used alongside Javascript, but there’s actually nothing which inherently requires it.

There is no established way to load WASM in your browser without JavaScript code that does it for you, so there actually is.

Can you explain why you feel that locally running Javascript is more insecure than using, say, locally running Python code, for encryption?

A web browser is the most vulnerable software on your computer.

To stick with the one example I brought, namely GnuPG encrypted e-mails: Running GnuPG locally on my machine to encrypt/decrypt/verify an e-mail before pasting the result into (e.g.) my e-mail client is reasonably secure. GnuPG has been audited thoroughly enough, so it's (relatively) safe to assume that no bad actor will read and/or modify the e-mail on the way. I am not aware of any JavaScript alternative with a similar security record.

I think we're derailing a bit though. My original comment was:

You can’t do that (= secure encryption) in a browser.

Locally and in a browser are, in real life, mostly different things and I assume you know that. GnuPG in webmail software without having used it locally first, which is what I was hinting at, just isn't secure.

[-] bearboiblake@pawb.social 3 points 1 week ago* (last edited 1 week ago)

There is no established way to load WASM in your browser without JavaScript code that does it for you, so there actually is.

I thought you meant like you had to use Javascript to marshal between the WASM module and the user interaction. What you really meant is that you're objecting to, basically, a load call. One line of Javascript code to load and run the WASM module. What possible security risk could that pose?

And again, I've not heard an adequate explanation as to how locally-running JavaScript encryption code would be any less secure than, for example, running a Python script in the terminal.

Locally and in a browser are, in real life, mostly different things and I assume you know that.

I think you're basically admitting that you meant that verifiably secure encryption using a website is impossible (other than e.g. TLS), which I would agree with, but that's not what you wrote. Browser extensions are used all the time to handle all sorts of secure encryption in high risk scenarios, such as for password managers. That is a perfectly valid example of encryption within a browser - and it was the first one I mentioned.

Please just admit you were wrong, or that you meant to say "website" rather than "browser". It's okay, trust me, people respect you more when you can admit that sort of thing, it makes you look strong and capable of taking criticism.

[-] tux0r@snac.rosaelefanten.org 1 points 1 week ago

I might, indeed, have miscommunicated my assumptions. Thank you for pointing it out.

[-] bearboiblake@pawb.social 1 points 1 week ago

No worries! Take care, and sleep well <3

this post was submitted on 27 Apr 2026
588 points (98.4% liked)

Linux

13530 readers
323 users here now

A community for everything relating to the GNU/Linux operating system (except the memes!)

Also, check out:

Original icon base courtesy of lewing@isc.tamu.edu and The GIMP

founded 2 years ago
MODERATORS