Reputation
4,050
Top tag
Next privilege 5,000 Rep.
Approve tag wiki edits
Badges
9 30
Newest
 Pundit
Impact
~118k people reached

Mar
2
comment Dangers of using CTR mode for encryption
Furthermore, cipher modes like XTS are practically purpose-built for filesystem encryption.
Feb
26
comment Hash + Salt v. Hash + Encryption
Saying a salt makes a hash harder to brute force is misleading. It does not make brute forcing a particular hash harder, but it can make brute forcing a corpus of hashes harder, by tying each guess to a specific hash rather than to the corpus as a whole. Encrypting hashes does in fact make brute forcing much more difficult as long as the key is kept secret — the attacker must now brute force the key as well as the password.
Feb
26
comment Hash + Salt v. Hash + Encryption
More effective for what use-case? Password hashing?
Feb
26
revised Could a key derivation function be used to encrypt data with a weaker key?
added 26 characters in body
Feb
26
answered Could a key derivation function be used to encrypt data with a weaker key?
Feb
26
comment How easily could this method of cryptography be cracked?
If you're going to write your own crypto, please don't publish it. Someone will use it without realizing its unsuitability, even if you put flashing red warnings everywhere.
Feb
26
comment Applicability of birthday attack to AES brute force
Yes, a birthday attack scenario comes when a user generates many keys, and an attacker need only collide with one at random.
Feb
19
comment How to construct encrypted functions (with either public or private data)?
Assuming an FHE scheme with encryption function $E$ that calculates $F(X)$ given public $F$ and encrypted $X$, instead of $F = f(x)$, $X = E(x)$, you would use $F = g(X,Y)$, $X = E(x), Y = E(f))$, where $g(f, x) = f(x)$.
Feb
19
comment How to construct encrypted functions (with either public or private data)?
@sashank In typical FHE, the function is public and the data is encrypted. What Mike Azo is proposing is one further step of abstraction. The function is now "given a circuit and some input, return the output of applying those inputs to the circuit", and the encrypted data is, "a circuit and some input".
Feb
19
answered Why does a hacker need to crack the key to an encrypted file, instead of just brute forcing the password?
Feb
16
comment How does hash speed vary based on string length?
@SLC To reiterate fgrieu's point, SHA-256 is not a suitable function for storing and verifying passwords, precisely because it is fast. Use a dedicated password hashing function like bcrypt, scrypt, or PBKDF2.
Feb
9
comment How is a message digest decrypted?
@RobertFlook Encryption is not authentication. Just because an attacker can't read a message doesn't mean they can't either manipulate it in a predictable way, or (as is typical with computer systems) at random until they get the result they're hoping for. Being able to discard a forged message before processing it can even prevent an attacker from recovering the plaintext in adaptive chosen-ciphertext attacks.
Feb
7
reviewed Approve What is wrong with simple concatenation in salted password hashes?
Feb
7
comment What is wrong with simple concatenation in salted password hashes?
None of these constructs are secure, and unfortunately, length extension attacks have nothing to do with it. Please just use bcrypt or scrypt. See this answer for more details.
Feb
1
comment Would a Rubik's cube be a trapdoor function?
The algorithm to solve a cube is not brute forcing it — trying every possible permutation is. The algorithm to solve a cube is equivalent to a catastrophic known-plaintext cryptanalytic attack against the "Rubiks cipher".
Jan
27
comment Which cryptography technique does not increase the size of the plain data?
If you can store an initialization vector (typically 16 bytes) per encryption, this becomes trivial (use any stream cipher with a unique IV). However, the IV must be available to the decryption process. This IV can be stored separately from the encrypted data, or in some cases it can be inferred through context.
Jan
27
comment How can a message encrypted with the public key be decrypted with the private key?
You might find the Wikipedia article on RSA helpful. There are other asymmetric cryptosystems based on other principles, but RSA is relatively easy to understand. Long story short, it's based on modular exponentiation.
Jan
22
comment Which cryptography technique does not increase the size of the plain data?
Can 16 bytes of extra data be sent, in or out of band, once per file/session/stream?
Jan
8
comment Is it secure to use hexadecimal data for IV instead of raw binary?
An IV isn't necessarily always random bits. In some modes, it can be a simple counter. That said, the gist of your answer is correct: you should only ever provide an IV, key, or ciphertext in the format expected by your cryptographic library; usually, that is in the form of raw binary data. Encode this data however you wish for storage and transport, but always convert it back before sending it through cryptographic routines.
Jan
5
awarded  Enlightened