GitHub: invalid username or password

Eurydice

I have a project hosted on GitHub. I fail when trying to push my modifications on the master. I always get the following error message

Password for 'https://[email protected]': 
remote: Invalid username or password.
fatal: Authentication failed for 'https://[email protected]/eurydyce/MDANSE.git/'

However, setting my ssh key to github seems ok. Indeed, when I do a ssh -T [email protected] I get

Hi eurydyce! You've successfully authenticated, but GitHub does not provide shell access.

Which seems to indicate that everything is OK from that side (eurydyce being my github username). I strictly followed the instructions given on github and the recommendations of many stack discussion but no way. Would you have any idea of what I may have done wrong?

VonC

https://[email protected]/eurydyce/MDANSE.git is not an ssh url, it is an https one (which would require your GitHub account name, instead of 'git').

Try to use ssh://[email protected]:eurydyce/MDANSE.git or just [email protected]:eurydyce/MDANSE.git

git remote set-url origin [email protected]:eurydyce/MDANSE.git

The OP Pellegrini Eric adds:

That's what I did in my ~/.gitconfig file that contains currently the following entries [remote "origin"] [email protected]:eurydyce/MDANSE.git

This should not be in your global config (the one in ~/).
You could check git config -l in your repo: that url should be declared in the local config: <yourrepo>/.git/config.

So make sure you are in the repo path when doing the git remote set-url command.


As noted in Oliver's answer, an HTTPS URL would not use username/password if two-factor authentication (2FA) is activated.

In that case, the password should be a PAT (personal access token) as seen in "Using a token on the command line".

That applies only for HTTPS URLS, SSH is not affected by this limitation.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

How to resolve unable to push to GitHub due to "Invalid username or password"?

From Java

Sourcetree remote: Invalid username or password

From Dev

Invalid Username or Password in Codeigniter 3

From Dev

PHP login "invalid username and password"

From Dev

orientdb connect invalid password and username

From Dev

C# Error 401 - Invalid username or password

From Dev

Domino Web SSO : Invalid username or password was specified

From Dev

Google app engine launcher: Invalid username or password

From Dev

Cannot deploy with goapp - invalid username or password

From Dev

remote: Invalid username or password, fatal: Authentication failed for

From Dev

Invalid username and password on login, CakePHP 2.5.5

From Dev

Username/Password Invalid Login Android Apps

From Dev

Php login "Invalid username and password" using mysql

From Dev

Github ask for Username & password after Configure ssh?

From Dev

How to stop github always asking for username / password?

From Dev

Issue cloning github repository with Username/Password

From Dev

Github ask for Username & password after Configure ssh?

From Java

git remote: Invalid username or password. fatal: Authentication failed - ubuntu

From Dev

remote: Invalid username or password. fatal: Authentication failed for

From Dev

kuali - ORA-01017: invalid username/password; logon denied

From Dev

Invalid username or password at login() using BlowfishPasswordHasher in CakePHP 2.x

From Dev

New One or both of Username and Password are invalid. Error

From Dev

spring security bad credentials distinguish between invalid username or password

From Dev

How to throw an error for Invalid username or password if the data is not matched with the DB?

From Dev

Display Error message when connection or Invalid Username or Password in VBA

From Java

Use Invoke-WebRequest with a username and password for basic authentication on the GitHub API

From Dev

GitHub Authentication from a WPF Application using Username & Password

From Dev

Why github doesn't ask me for username/password?

From Dev

How to take the username and password of a user to register in GitHub via the API?

Related Related

  1. 1

    How to resolve unable to push to GitHub due to "Invalid username or password"?

  2. 2

    Sourcetree remote: Invalid username or password

  3. 3

    Invalid Username or Password in Codeigniter 3

  4. 4

    PHP login "invalid username and password"

  5. 5

    orientdb connect invalid password and username

  6. 6

    C# Error 401 - Invalid username or password

  7. 7

    Domino Web SSO : Invalid username or password was specified

  8. 8

    Google app engine launcher: Invalid username or password

  9. 9

    Cannot deploy with goapp - invalid username or password

  10. 10

    remote: Invalid username or password, fatal: Authentication failed for

  11. 11

    Invalid username and password on login, CakePHP 2.5.5

  12. 12

    Username/Password Invalid Login Android Apps

  13. 13

    Php login "Invalid username and password" using mysql

  14. 14

    Github ask for Username & password after Configure ssh?

  15. 15

    How to stop github always asking for username / password?

  16. 16

    Issue cloning github repository with Username/Password

  17. 17

    Github ask for Username & password after Configure ssh?

  18. 18

    git remote: Invalid username or password. fatal: Authentication failed - ubuntu

  19. 19

    remote: Invalid username or password. fatal: Authentication failed for

  20. 20

    kuali - ORA-01017: invalid username/password; logon denied

  21. 21

    Invalid username or password at login() using BlowfishPasswordHasher in CakePHP 2.x

  22. 22

    New One or both of Username and Password are invalid. Error

  23. 23

    spring security bad credentials distinguish between invalid username or password

  24. 24

    How to throw an error for Invalid username or password if the data is not matched with the DB?

  25. 25

    Display Error message when connection or Invalid Username or Password in VBA

  26. 26

    Use Invoke-WebRequest with a username and password for basic authentication on the GitHub API

  27. 27

    GitHub Authentication from a WPF Application using Username & Password

  28. 28

    Why github doesn't ask me for username/password?

  29. 29

    How to take the username and password of a user to register in GitHub via the API?

HotTag

Archive