Skip to content

Authentication failed while clonning private repo #2338

Closed

Description

@ionastasi

Description

I have an error while trying to clone some private repository. Everything works just find until the very end, when it falls with the following message:

Authentication failed. You may not have permission to access the repository. Open options and verify that you're signed in with an account that has permission to access this repository.

So the app doesn't see this repo, although all files are downloaded. Yeap, I signed in with the correct account, 100%.

Version

GitHub Desktop version: 0.7.0

OS version: 10.0.15063

Steps to Reproduce

  1. File -> clone repository...
  2. Enter the url of the repo (it's private in my case).
  3. Wait.

Expected behavior: Repo works fine with the app. Or, if I really don't have a permission to this private repo, the app shouldn't download all files from it before raising the error.

Actual behavior: Authentication failed, app doesn't see this repo.

Reproduces how often: 100% in my case with this particular repo.

Logs

Additional Information

Activity

  1. added
    bug
    more-info-needed
    on Jul 27, 2017
  2. shiftkey commented on Jul 27, 2017

    @shiftkey
    Member

    @ionastasi a few questions:

    • Are you signed into a GitHub or GitHub Enterprise account at the time of cloning?
    • Is this a GitHub or GitHub Enterprise repository you are cloning? Or some other host?
    • Is this a HTTPS or SSH URL?
    • Are there any errors in the log files at %APPDATA%\\GitHub Desktop\\logs\\*.desktop.production.log that might highlight the underlying error?
  3. joshaber commented on Aug 8, 2017

    @joshaber
    Contributor

    Thank you for your issue!

    We haven't gotten a response to our questions above. With only the information that is currently in the issue, we don't have enough information to take action. I'm going to close this but don't hesitate to reach out if you have or find the answers we need, we'll be happy to reopen the issue.

  4. ionastasi commented on Aug 8, 2017

    @ionastasi
    Author

    @shiftkey @joshaber Oops, I'm sorry for beeing late.

    Are you signed into a GitHub or GitHub Enterprise account at the time of cloning?

    GitHub account.

    Is this a GitHub or GitHub Enterprise repository you are cloning? Or some other host?

    Seems like it's an ordinary GitHub repo. I don't see an information that it's not.

    Is this a HTTPS or SSH URL?

    https

    Are there any errors in the log files at %APPDATA%\GitHub Desktop\logs\*.desktop.production.log that might highlight the underlying error?

    May be. You can take a look here: https://pastebin.com/5YR2YA0G I only changed names and deleted the log about compressing, resolving and etc.

    Also, I need to notice that I successfully downloaded this repo (again, with the same acc and via https and without any special actions) with the official GitHub Desktop (Chocolate-Covered Yaks (3.3.4.0) 50415df).

  5. joshaber commented on Aug 8, 2017

    @joshaber
    Contributor

    No worries @ionastasi!

    It looks like this is the important line:

    Host key verification failed.

    It sounds like some of the submodules are setup with SSH URLs, but your machine doesn't trust GitHub's SSH servers.

    There are a couple ways to fix this:

    1. Change the submodule URLs to HTTPS.
    2. Setup SSH.

    The first option may be easier.

    For the second, check out https://help.github.com/articles/testing-your-ssh-connection/#platform-windows.

  6. ionastasi commented on Aug 10, 2017

    @ionastasi
    Author

    Hi @joshaber

    1. It doesn't work for me because this repo isn't mine.
    2. Looks like ssh connection works well.

    Looks like ssh connection works well.

  7. joshaber commented on Aug 10, 2017

    @joshaber
    Contributor

    Looks like ssh connection works well.

    To be clear, does that mean this issue is resolved?

  8. shiftkey commented on Aug 13, 2017

    @shiftkey
    Member

    I think completing the ssh -T [email protected] steps should add the host entry to your SSH configuration, and remove the Host key verification failed. error.

    @ionastasi could you confirm that you aren't able to reproduce the issue?

  9. ionastasi commented on Aug 14, 2017

    @ionastasi
    Author

    @joshaber @shiftkey Nope, I still have this problem =(
    But it seems like ssh itself works. Indeed, if it didn't, Icouldn't clone the repo with another GitHub Desktop.

  10. shiftkey commented on Aug 31, 2017

    @shiftkey
    Member

    @ionastasi could you clarify which problem you are referring to here? I'm going to close this out until we can understand the current behaviour you're seeing when cloning, so please include a fresh log file so we can understand what's happening...

  11. locked as resolved and limited conversation to collaborators on Jul 20, 2018
  12. unlocked this conversation on Sep 27, 2018
  13. neil-leigh commented on Feb 28, 2019

    @neil-leigh

    Solution by joshaber from Aug 8, 2017
    " Host key verification failed.
    There are a couple ways to fix this:

    1. Change the submodule URLs to HTTPS.
    2. Setup SSH."

    Just switching the URL from SSH to HTTPS solved this issue for me - thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugmore-info-needed

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions