to clone my bitbucket project,I changed the /.ssh/authorized_keys content by adding my bitbucket key and I am able to clone into my bitbucket,but after that I was not able to access my server at EC2 because I have deleted the whole content of /.ssh/authorized_keys and replaced with the key
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDHMcFczzNgh1z97zMrpyV0b+NOU7yMSZBDuH5BhvG5XDNN2CaOiwNg2iVjIR2U5laGpGMV8VC5G2N2jevXnOFyXUoe7HUuCjGK9IeG0iBsuq8GWlqC6EY0H6JbTqQK94QJIgxB2Ib+NRGYpKiLkXBO7FR7ZIcv8cv+aZdLQgNDMQTHvcHvqK8N/swBgzW1qjp+hhnkJC5ozUhFFIDTJqxTN3v9bG4CV2qYpk8axfR003X7BRVkcFZsCSq56fJ9ueB+wnqnXSZ+9WDXDPcB8AQQQ+8jNTbAE/bgQbNpztssvsBdy8+zxe7LEMlfmM8vEoyE333jSZLtvF1q+upfxzZh
Now how do I access my server ? I have generated a key file using puttygen and replaced this code in public key and tried to login but it failed showing the error message
---------------------------
Error
---------------------------
Disconnected: No supported authentication methods available (server sent: publickey)
---------------------------
Authentication log (see session log for details):
Using username "ubuntu".
Server refused our key.
Authentication failed.
---------------------------
OK Reconnect (2 s) Help
---------------------------
Note I access bibucket in windows, ~/.ssh/ has these contents config.txt,id_rsa.pub,id_rsa,known_hosts,personalid,personalid.txt and I didn't push into bitbucket after replacing text,but I cloned the private bitbucket repository