In cryptography world there are different ways that you can encrypt data (files). We explain both here a bit:
1- In one of these methods you encrypt a file with a secret key. The other party has the same secret key in order to be able to decrypt data. This way of encryption and decryption is called
2- The other method is
#cryptography #asymmetric #symmetric #rsa #gpg
1- In one of these methods you encrypt a file with a secret key. The other party has the same secret key in order to be able to decrypt data. This way of encryption and decryption is called
Symmetric
.2- The other method is
Asymmetric
encryption. Asymmetric encryption involves the use of a public key and a private key. As can be guessed from the names, only the private key needs to be kept private. The public key is made available for anybody that wants to encrypt data to send to the owner of the public key. Using the usual names Alice and Bob as examples: If Bob wanted to send an encrypted file or email to Alice, Bob would encrypt the data using Alice's public key then send the data to Alice. Alice can then decrypt the data using her private key that only she has access to. Once Bob has encrypted the data, nobody but Alice can decrypt it. Note that a private key is usually protected by a passphrase, so even on her own Ubuntu box where the key resides, Alice will still need to enter a passphrase to "unlock" the private key. Bob will have his own public/private key pair so people can send encrypted data to him. So should Alice want to send encrypted data to Bob, she'd encrypt it using Bob's public key whilst Bob could then decrypt it using his own private key. The best asymmetric cryptographic algorithm supported by gpg is called RSA.#cryptography #asymmetric #symmetric #rsa #gpg