Linked Questions

177 votes
7 answers
139k views

Why can't we reverse hashes?

First off, I know hashes are 1 way. There are an infinite number of inputs that can result in the same hash output. Why can't we take a hash and convert it to an equivalent string that can be hashed ...
2 votes
1 answer
421 views

Choosing encryption algorithms and protocols in military systems

Militaries use their own cryptographic algorithms, those of a private third party, or ones that are openly available. However, fear of a backdoor having been planted in publicly-available encryption ...
30 votes
4 answers
24k views

How cryptographically secure was the original WW2 Enigma machine, from a modern viewpoint?

If cryptanalysts today were to crack the original Enigma machine, “how fast” or “how easily” could they do it? What methods would they use? The original cracking was significantly helped by operator ...
2 votes
4 answers
2k views

An unbreakable book cipher?

In a recent press interview, a former terrorist of the 1970s described the cipher his group used to communicate. He claimed that method was unbreakable and I wonder if cryptographers today would agree....
1 vote
1 answer
309 views

Value of new symmetric key algorithm

When I was in grad school, I invented (discovered?) a new PRNG algorithm. This algorithm has an infinite period length (given infinite memory). This in itself cannot be new, because all you need to ...
0 votes
2 answers
2k views

What are the exceptions to Kerckhoffs's principle?

Kerckhoffs's principle: A cryptosystem should be secure even if everything about the system, except the key, is public knowledge. Yet the following are three exceptions:- NSA Suite A cryptographic ...
3 votes
1 answer
2k views

How do you test the security of your cipher?

I got asked this question and I didn't know what to answer. How do you test the security of your cipher? What comes to my mind now would be to test it with famous attacks: padding attacks, ...
1 vote
2 answers
2k views

Decrypting ciphertext that is missing a block

In the AES encryption, suppose that the key is known. The ciphertext is also known except for a block of the same size as the key. For example, the adversary knows $k, c_0, c_1, \dots, c_{n - 1}$; ...
68 votes
2 answers
25k views

Is truncating a SHA512 hash to the first 160 bits as secure as using SHA1?

I am from a web development background (I don't know an awful lot about cryptography or how the algorithms themselves work), so I am asking this question in simple terms. Consider a hash of the word '...
9 votes
4 answers
2k views

Is there a way to generate sound one-time pads out of public information?

Is there a way to 'mangle' a public data-source (for example, the current date in YYYYMMDD or the top New York Times headline) to form a one-time pad that will sufficiently hide the pad's source? ...
1 vote
3 answers
9k views

Writing your own Encryption algorithm?

Simple answer (and I know this is a simple yes or no) is it possible to write an encryption that is 100% uncrackable, as long as I keep certain parts private? It's just for personal use. I'm a ...
3 votes
1 answer
3k views

How vulnerable is one-time pad (OTP) encryption, if the OTP is used twice, with a random substitution scheme

After reading up on the one-time pad (OTP) encryption method, I could see how it would offer unbreakable encryption if used properly. Moreover, I looked at how the OTP could be broken if the OTP-key ...
7 votes
1 answer
457 views

Does a conditional statement depending on a round number introduce timing attack problems?

In a cryptographic implementation I’m playing with, there’s a round function which includes a conditional if statement. Stripping the superfluous stuff, the C ...
-2 votes
1 answer
1k views

Is it possible to attack an SHA-256 hash seeded with PHP’s mt_rand function?

Is it possible to attack this construction if the attacker only knows the hash? ...
1 vote
4 answers
364 views

Including the next random One Time Pad as part of the encoded message?

I've tried to do something very simple here, which is to encrypt a message with a one-time-pad (OTP) and include the next OTP as part of that same encrypted message. i.e. The first message consists of ...

15 30 50 per page