4 ms·
Took me a little while to realise you set the password in the blue box above the text entry. Interesting concept though. For those interested it uses crypto-js
by dekz 15y ago
Took me a little while to realise you set the password in the blue box above the text entry. Interesting concept though.
For those interested it uses crypto-js (http://code.google.com/p/crypto-js/ http://code.google.com/p/crypto-js/).
Might want to increase the random entropy source, from what I can see it's just DateTime.
Also I'd use a better hashing algorithm than SHA1 with AES-256.
I understand the need for PBDKF2, but I'm not so sure about using the password as the key and salt.
- tptacek 15y agoThey aren't using SHA1; they're using HMAC-SHA1. Not the same thing. That said: this is an idiosyncratic (rekeying AES every 500ms?) and not particularly resilient cryptosystem. As a commenter said below: don't use this for anything serious. You're equally well off with a server that simply sends "plaintext" messages over TLS.
- magikarp 15y agoAFAIK, the server does not rekey AES every 500ms - and your suggestion to use a server over TLS opens you up to the problem of the server itself being able to read all plaintext.
- tptacek 15y agoThe server can read all the plaintext anyways.
- magikarp 15y agoRight...
- magikarp 15y agoNo it can't, that's the whole point! Are you trolling?
- tptacek 15y agoNo, what's happening here is that that you don't actually understand the threat model for encryption code running in Javascript fed by a server, and you're getting more and more frustrated by the fact that I'm not handholding you through it. Reasoning about security systems (click my name to see that I do that for a living) is frustrating. To see what's happening in this case, steel yourself for a headache, sit down, and think hard through all the different things that attackers can potentially influence. Then ask yourself, "what could an attacker accomplish by manipulating that thing?".