Basic auth deprecation on github and its impact

developerhelp

developer-help

Posted on January 5, 2021

Basic auth deprecation on github and its impact

Basic auth deprecation on github and its impact.

Till now Github was supporting basic Authentication for making an API call for git.
But starting nov-20 git stopped supporting basic Authentication as mechanism for authentication.

As per git alternative is to use personal token for authentication for GIT API calls.

Though personal token is there from long time but there is no clear cut details about
what exactly works that is how i scrambled over net to figure out what works.

Below set of details with curl, that works and does not work.

curl -H "Authorization: Bearer " -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/developer-help/Test-Token/contents/pipeline.json

Does not work
curl -H "Authorization: Token " -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/developer-help/Test-Token/contents/pipeline.json

Does not work
curl -H "Authorization: Basic " -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/developer-help/Test-Token/contents/pipeline.json

💖 💪 🙅 🚩
developerhelp
developer-help

Posted on January 5, 2021

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related