Common symmetric encryption algorithms include Swiss international data encryption algorithm (IDEA) and American Date Encryption Standard (DES).
DES is an iterative block cipher. Both plaintext and ciphertext are 64 bits, using a 56-bit key and an additional 8-bit parity bit. The main technology to attack DES is exhaustive method. Because the key length of DES is short, in order to improve the security, an algorithm (3DES) using 112-bit key to encrypt data for three times appeared, that is, using two 56-bit keys K1 and K2, the sender encrypts with K1, decrypts with K2, and then encrypts with K1; The receiver uses K1 to decrypt, K2 to encrypt, and then K1 to decrypt, which is equivalent to doubling the key length.
IDEA is developed on the basis of DES, similar to 3DES. The plaintext and ciphertext of IDEA are both 64 bits, and the key length is 128 bits.
asymmetric encryption algorithm, also known as public key encryption algorithm, means that the encryption key and decryption key are completely different, one of which is the public key and the other is the private key, and it is impossible to deduce the other from either one. Its advantage is that it can adapt to the open use environment and realize digital signature and verification.
the most common asymmetric encryption algorithm is RSA, and the name of this algorithm is named after the inventors: Ron Rivest, AdiShamir and Leonard Adleman. The key length of RSA algorithm is 512 bits. The confidentiality of RSA algorithm depends on the difficulty of decomposing a large number into two prime numbers in mathematics. According to the existing mathematical methods, its calculation is extremely large and it is difficult to crack. However, when encrypting/decrypting, large exponential modulus operation is needed, so the encryption/decryption speed is very slow, and it is mainly used in digital signature.
encrypt with public key and decrypt with private key.