From 0e5b37ed6f37a80eb5ec5be6fbe9a86ed67ee95f Mon Sep 17 00:00:00 2001 From: Jaisurya <106684947+JaiSuryaPrabu@users.noreply.github.com> Date: Thu, 16 May 2024 21:42:04 +0530 Subject: [PATCH] Update security-git-ssh.md In this commit, I have added an extra step that is to start the SSH agent before adding the key to the SSH agent --- docs/hub/security-git-ssh.md | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/docs/hub/security-git-ssh.md b/docs/hub/security-git-ssh.md index 34daa6531..a182cd4cf 100644 --- a/docs/hub/security-git-ssh.md +++ b/docs/hub/security-git-ssh.md @@ -30,8 +30,20 @@ $ ssh-keygen -t ed25519 -C "your.email@example.co" We recommend entering a passphrase when you are prompted to. A passphrase is an extra layer of security: it is a password that will be prompted whenever you use your SSH key. -Once your new key is generated, add it to your SSH agent with `ssh-add`: +Once your new key is generated, add it to your SSH agent with `ssh-add`. +At first you have to open a connection to your authentication agent. To do this follow this step: + +1. **Start the SSH agent** : You need to start the ssh-agent before using it. Run the following command in your terminal : +``` +$ eval `ssh-agent -s` +``` +If you're using Git Bash, you can also use: +``` +eval $(ssh-agent s) +``` + +2. **Add your key** : After starting the ssh-agent, add your key using : ``` $ ssh-add ~/.ssh/id_ed25519 ``` @@ -83,4 +95,4 @@ hf.co ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDtPB+snz63eZvTrbMY2Qt39a6HYile89JOum hf.co ssh-dss AAAAB3NzaC1kc3MAAACBAORXmoE8fn/UTweWy7tCYXZxigmODg71CIvs/haZQN6GYqg0scv8OFgeIQvBmIYMnKNJ7eoo5ZK+fk1yPv8aa9+8jfKXNJmMnObQVyObxFVzB51x8yvtHSSrL4J3z9EAGX9l9b+Fr2+VmVFZ7a90j2kYC+8WzQ9HaCYOlrALzz2VAAAAFQC0RGD5dE5Du2vKoyGsTaG/mO2E5QAAAIAHXRCMYdZij+BYGC9cYn5Oa6ZGW9rmGk98p1Xc4oW+O9E/kvu4pCimS9zZordLAwHHWwOUH6BBtPfdxZamYsBgO8KsXOWugqyXeFcFkEm3c1HK/ysllZ5kM36wI9CUWLedc2vj5JC+xb5CUzhVlGp+Xjn59rGSFiYzIGQC6pVkHgAAAIBve2DugKh3x8qq56sdOH4pVlEDe997ovEg3TUxPPIDMSCROSxSR85fa0aMpxqTndFMNPM81U/+ye4qQC/mr0dpFLBzGuum4u2dEpjQ7B2UyJL9qhs1Ubby5hJ8Z3bmHfOK9/hV8nhyN8gf5uGdrJw6yL0IXCOPr/VDWSUbFrsdeQ== hf.co ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBL0wtM52yIjm8gRecBy2wRyEMqr8ulG0uewT/IQOGz5K0ZPTIy6GIGHsTi8UXBiEzEIznV3asIz2sS7SiQ311tU= hf.co ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINJjhgtT9FOQrsVSarIoPVI1jFMh3VSHdKfdqp/O776s -``` \ No newline at end of file +```