# Tag Info

6

The point of cryptography is having algorithms that are secure even when the attacker knows them. Google security by obscurity to see why it's bad. I'll add the following based on otus comment. Python can be reverse engineered, so you can't hide your algorithms. Basically, if someone can run your code, they can reverse engineer the algorithms. The point of ...

5

I'll assume that the plaintext consists entirely of capital ASCII letters as in the example. This implies the high 3 bits of each byte of plaintext are 010. It is useful to visualize how 3 consecutive bytes of plaintext map to 4 consecutive Base64 characters. 1. Frequency analysis of the last character of 4-char blocks in ciphertext We see there is a ...

3

Compared to fixed rotations, data-dependent rotations improve resistance to differential and linear cryptanalysis. A fixed rotation has no effect (beyond helping with diffusion) in the probability of a (xor-)differential characteristic, whereas a data-dependent rotation also introduces differences in the rotation amounts, which brings probabilities down. ...

2

Python is a scripting language, so if you've got the program, you usually also have the source code. So you don't even have to reverse-engineer. That doesn't matter much for two reasons: other languages are pretty easy to reverse engineer (or they are complex for both the programmer and the attacker); the algorithm does not have to be kept safe anyway, due ...

2

The encryption is weak This encryption is more susceptible to frequency analysis than original "substitution ciphers" because the frequency tables should be much more Non-uniform. In my opinion, it should be less secure than substitution cipher although the key space is much much bigger (compare $64!$ to $26!$). Some evidences of the weakness If I assume ...

1

Since you already know $K$, you just need to know the length of $H$ based on the hash algorithm you are using, which should be constant, then simply split the output of $D_k$ into the 2 parts of appropriate length. You can then perform the keyed hash on the first part and match it against the last part, which will match if the decryption was successful. It ...

1

You should not just "pick the highest frequency character and assume it should be E" because it will probably fail most of the time, except if your ciphertext is really long. If your alphabet is small enough (usually either 26 or 255), it would be wiser to try all the possibilities for each group, and to check if the output looks like real english ...

Only top voted, non community-wiki answers of a minimum length are eligible