9,417 reputation
12345
bio website github.com/CodesInChaos
location Frankfurt, Germany
age
visits member for 3 years
seen 1 hour ago

Jun
6
comment Pick faster private exponent
You could consider multi-prime RSA if your implementation supports it.
Jun
4
comment Padding to increase entropy and size of (otherwise) small JSON objects
If you're using proper encryption (with a per-message IV) you don't need to pad the message.
Jun
4
comment Comparing two values without revealing them
This may be usable as fallback solution, but generally order preserving encryption leaks a bit much. If there is an efficient ZKP, it will be much stronger than OPE.
Jun
4
comment Comparing two values without revealing them
This seems to be a combination of a commitment and a zero knowledge proof. Your hashes solve the commitment part, but make the ZKP part impossible. There is a similar problem called Yao's Millionaires' Problem but there alice knowns one value and bob the other. You should search for "Zero knowledge proof" or perhaps "secure multi party computation".
Jun
3
comment Montgomery Ladder vs Double-and-Add
On montgomery curves montgomery ladders enable cheap addition via differential addition in x/z form. In most other situations I'd rather create a lookup table with 32 or so entries and then double 5 times followed by one lookup and one addition.
Jun
2
comment Measure ECC key size
When talking about the size in ECC we generally refer to the field size.
Jun
1
comment Parallel hash construction
Related question: Counter mode secure hash algorithm
May
28
comment RSA and ECDSA performances
Concerning optimized implementations, ECC has one big advantage: A fixed modulus which usually has been chosen to allow efficient reductions. Certain academics like publishing papers about their world record speed ECC implementations, so ECC has seen quite a bit of optimization work targeting modern CPUs. ECC is more complex mathematically, but I think it's actually easier to write a fast ECC implementation compared to a fast RSA implementation.
May
28
comment Is TEA considered secure?
@user54609 8 byte blocks are annoying to use since it makes encrypting more than a GB using a fixed key problematic. In a quick test TEA was rather slow at 45 cycles per byte. Why do you claim it's "super fast"?
May
25
comment Efficiency of chaining AES “groups” of blocks
This technique is responsible for the famous BEAST attack against TLS.
May
21
comment Which tamper-protection algorithm provides the shortest output?
@Vilx- With HMAC the chance of accepting a forgery is $2^{-n}$ for an $n$ bit MAC. With GCM every successful forgery reveals a big part of the key whereas for HMAC the only effect is that you accept a forgery. So if you really need to go below 128 bit MACs, I recommend against GCM. Another issue with GCM is that it needs a nonce and reuse is fatal, whereas HMAC doesn't need a nonce.
May
21
comment Which tamper-protection algorithm provides the shortest output?
I'd go with truncated HMAC-SHA-2 with a length somewhere between 64 and 128 bits. Truncation is fine with HMAC, but do not truncate a GCM / GHash MAC.
May
20
comment how to use common modulus attack?
Didn't realize RSA had this property. Even though this is a low effort question, +1 for making be learn something new.
May
19
comment Do I need two keys for AES CBC and HMAC or can I use the same key for both operations?
Related: Why can't I use the same key for encryption and MAC?
May
16
comment Is concatenated data hashed with scrypt vulunarable to a length extension attack?
I think scrypt inherits the zero padding length extension from PBKDF2. scrypt(s, salt) == scrypt(s + \0, salt) for short enough s shorter than 64 bytes.
May
14
comment ECDSA vs RSA: Performance on Android platform and surprising results
@user13397 My point is that the main reason for ECDSA being slow in your test is not that it's implemented in pure java, it's because the implementation has not been optimized. Native code usually results in a speedup, but a smaller one. I'd guess a good java implementation would be 50 times faster than your code and native code would result in a factor 2-3 speedup beyond the best possible java implementation. But I don't have java/android experience, so these are very rough guesses coming from my experience with writing crypto code in C#.
May
13
comment ECDSA vs RSA: Performance on Android platform and surprising results
@mikeazo It uses its own BigInteger library. But even with pure java code you can get much better performance.
May
11
comment How to decrypt a text which is ciphered same length key?
See also: How does one attack a two-time pad (i.e. one time pad with key reuse)?
May
9
comment Point addition and doubling in Ed25519 (ref10)?
sc_clamp makes no sense on encoded points. It operations on scalars.
May
9
comment Why is Triple DES not vulnerable to meet in the middle attacks?
Very similar to the question Why is triple-DES using three different keys vulnerable to a meet-in-the-middle-attack?