1. Brief description of public key and private key (two-key encryption technology:
Assume that data transmission from data transmitter A to data receiver B (take server a and client B as an example ). B now has a pair of key pairs (public and private keys). B sends the public key to a, and a encrypts the data to B, b. After receiving the data, use the private key in the hand to decrypt the data (the public key and the private key exist in pairs, that is, only the private key that matches the public key exists, to decrypt data encrypted by using the public key. This ensures the relative security of data transmission.
2. Generate a key pair:
# Ssh-keygen-c "[email protected]"-T RSA
After executing this command, there are two files in the/root/. Ssh/directory. These two files are the private key and public key files.
Bytes ----------------------------------------------------------------------------------------------
References:
1. Public Key, private key and digital signature is the best understanding: http://blog.csdn.net/21aspnet/article/details/7249401
2. Basic knowledge of Linux: Generate public key: http://www.examw.com/linux/all/199494/
3. Ssh Public Key Authentication: http://blog.sina.com.cn/s/blog_4b5039210102e3r1.html
Generate a key pair (Public Key and private key) in centos)