How to add a passphrase?

0128

To add a passphrase when generating an SSH key, follow these steps:

  1. Open your terminal.

  2. Run the ssh-keygen command:

    ssh-keygen -t rsa -b 4096 -C "your_email@example.com"
  3. When prompted for the file location:

    • Press Enter to accept the default location (e.g., ~/.ssh/id_rsa).
  4. When prompted for a passphrase:

    • Type your desired passphrase. This passphrase will be used to encrypt your private key.
    • Press Enter.
  5. When prompted to confirm the passphrase:

    • Type the same passphrase again and press Enter.

After completing these steps, your SSH key will be generated with a passphrase. You will need to enter this passphrase each time you use the private key for SSH connections.

0 Comments

no data
Be the first to share your comment!