npm host key verification failed code example

Example 1: git host key verification failed

#Windows:
ssh-keyscan -t rsa github.com >> %userprofile%/.ssh/known_hosts

#Mac:
ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts

# (If it says 'Command not found', try to run the command in your Git Bash.)

Example 2: host key verification failed

#Windows:
ssh-keyscan -t rsa github.com >> %userprofile%/.ssh/known_hosts

#Mac:
ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts

Example 3: Host key verification failed.

$ ssh -o StrictHostKeyChecking=no [email protected] uptime