Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

What about sslstrip? What about the fact that CAs are being hacked left and right, and that governments such as China are known to produce fake certs to wiretap dissidents? What about the fact that the server can still read your data? Again, how can you trust the server with your plaintext if you can't trust it to serve you good JS crypto code? There have been attempts to mitigate this problem in JS crypto anyway, using browser plugins that perform integrity checks.


> What about the fact that CAs are being hacked left and right, and that governments such as China are known to produce fake certs to wiretap dissidents?

This is an authentication and a trust issue. JS crypto does not solve this at all.

> What about the fact that the server can still read your data? Again, how can you trust the server with your plaintext if you can't trust it to serve you good JS crypto code?

If you don't trust the server, why are you sending it the data? And how is JS crypto any better?

If you're trying to bash SSL to promote JS crypto as a better alternative, you should probably choose problems that JS crypto doesn't also have.

> There have been attempts to mitigate this problem in JS crypto anyway, using browser plugins that perform integrity checks.

This isn't JS crypto. This is "browser plugin crypto, that we're choosing to compromise by tacking on a huge JS part that someone can backdoor".


> If you don't trust the server, why are you sending it the data? And how is JS crypto any better?

JS crypto remains better since there exists techniques to verify the crypto, and the server does not receive plaintext.

> This isn't JS crypto. This is "browser plugin crypto, that we're choosing to compromise by tacking on a huge JS part that someone can backdoor".

That's ridiculous. Integrity checks exist for many crypto-systems, don't perform crypto - they are an extension.


For an unmodified and basically functional browser, in a way there isn't a "client" and a "server" context. There's only a server context. The client is actually a sandbox that has been designed to carefully partition off the server code from everything else that the server doesn't authorize, and hasn't got enough of an "identity" to be its own thing. A normal, correctly-functioning browser is designed to basically be an extension of the server in question, and there are no effective mechanisms for the client to have any state placed in it and fed back to that server that did not come from that server. Even when you type a comment into a text box and hit 'submit', what comes back to you is fed to you by the server in question.

When a server serves you a page, it basically owns that context. Crypto can secure further communication between that page and the server (via SSL), but there's basically no room to hide something from the server, and if there was that would probably be considered a browser bug at some level. If the server does not receive plaintext, which a network-level analysis may say it does not, it is only because the server has graciously consented to not receive some plaintext, not because you have actually somehow built a webpage that can prevent the server from getting that plaintext. One tweak to the server, it serves slightly different JS and offers a slightly different API and bam, it's getting plaintext.

Web pages just don't have enough identity of their own to do anything like this separate from the server, without further extensions (which is why the topic of plugins keeps coming up).


What cryptosystem are you talking about in which integrity checking is an optional feature?


> JS crypto remains better since there exists techniques to verify the crypto, and the server does not receive plaintext.

You are giving the plaintext to code that has (at best) the same trust level as the server itself.

What data is it safe to give to that code, that isn't safe to send (in a way that can't be mitm'd) to the server?

> That's ridiculous. Integrity checks exist for many crypto-systems, don't perform crypto - they are an extension.

I'm not sure what you're saying here - you might want to clarify exactly what you mean.

In doing so, perhaps you could tell me why you think "browser plugin validator + untrusted JS crypto code" is more secure or otherwise better than "browser plugin crypto with no JS".


Don't get me wrong, browser plugin crypto probably works fine, but it's also possible to use a browser plugin to turn untrusted JS crypto code into trusted JS crypto code. The plus side of that is that the crypto code would still work without the plugin.


So your answer as to why JS+validator is better than a plugin doing crypto is that "it still appears to work fine even when the system is utterly broken".

...

When it comes to security, that is actually a negative.


Whether you consider it "utterly broken" or not without the validator depends on your trust of the server - similarly to HTTPS, which is vulnerable from the trust standpoint thanks to CA vulnerabilities.

Furthermore, it's possible to verify the code manually, although tediously, whereas a CA impersonation is perfectly transparent and very difficult to detect. The validator plugin usually does the job.


...and your trust of the network itself, unless you're using HTTPS in addition to your ad-hoc solution.

And vulnerabilities in the trust chain are not HTTPS vulnerabilities - they are trust chain vulnerabilities. It's straightforward to address them yourself simply by not trusting any CAs you don't trust.


> unless you're using HTTPS in addition to your ad-hoc solution.

Yes, I don't see why not.

> It's straightforward to address them yourself simply by not trusting any CAs you don't trust.

From that standpoint, we're assuming that everyone with a browser knows what a CA is and discerns between trustworthy CAs. I could equally say that it's straightforward for users to simply review the JavaScript code they don't trust - but the problem is that there exist many users who don't know how to review JavaScript and don't know what a CA is, and will just rely on what their browser tells them (which is where a plugin comes in handy.)


Why is a plugin trustworthy where the root CAs are not?


Simply because a plugin can be verified locally at length whereas a compromised CA can issue a fake cert that is very, very difficult to detect.


> but the problem is that there exist many users who don't know how to review JavaScript and don't know what a CA is, and will just rely on what their browser tells them (which is where a plugin comes in handy.)

> a plugin can be verified locally at length whereas a compromised CA can issue a fake cert that is very, very difficult to detect.

Which is it?

Either you're claiming that verifying a plugin is easier than not trusting CAs that you don't trust, or you're arguing two completely contrary positions.

edit:

And this then brings us back to the earlier point, which is why not just use the plugin for crypto in the first place?


Um, no.

The plugin is the same for all users - not everyone who downloads and runs GnuPG knows how to verify it - but some people might go as far as to either compile it from source or ever decompile it. If they find something suspicious, they will report it so that other people who have downloaded the software can be aware. Same thing goes for the plugin (except that the plugin is easier to verify than a compiled binary.)

When I talk about people who can't review JavaScript or CAs, I'm talking about the average computer user. I am not saying that "verifying a plugin is easier than not trusting CAs that you don't trust." The average computer user doesn't care about CAs or JavaScript.

My point remains: a plugin can be verified by others who have downloaded it - a compromised CA is extremely difficult to detect.


To that point, what is the difference :-

1. just trusting the cert say for Amazon directly rather than trusting the chain of trust using CA (distrust all the root CA and just trust the cert of Amazon)

between

2. Trusting verified Javascript directly.


So once again:

> And this then brings us back to the earlier point, which is why not just use the plugin for crypto in the first place?


I'm sorry, but I've already answered this, as a reply to one of your own comments. Please scroll up.


And I disputed it, which is what lead us here. You are literally making a circular argument by trying to use your answer to support itself.


It's you who's being circular, sir.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: