Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Authentication Not Supported Error #124

Open
Git-Mani opened this issue Dec 20, 2024 · 6 comments
Open

Authentication Not Supported Error #124

Git-Mani opened this issue Dec 20, 2024 · 6 comments

Comments

@Git-Mani
Copy link

We are encountering an issue while attempting to pull content changes using JGit. The operation fails with the following error:

image

Has anyone faced a similar issue? If so, please let me know what the possible cause could be.

@msohn
Copy link
Member

msohn commented Dec 20, 2024

You need to set a CredentialsProvider to authenticate using credentials accepted by your server.

@Git-Mani
Copy link
Author

Git-Mani commented Dec 20, 2024

@msohn I'm using same for authenticate with username and pat(Token classic)

final PullCommand pullCommand = git.pull();
pullCommand.setCredentialsProvider(new UsernamePasswordCredentialsProvider(config.getUsername(), config.getToken()));
final PullResult pullResult = pullCommand.call();

@msohn
Copy link
Member

msohn commented Dec 20, 2024

Do the same credentials work when pulling with C git ?

@Git-Mani
Copy link
Author

It doesn't fail every time, but fails unexpectedly.
Use case:
I have 10 files to push to Git. The workflow I use is as follows:

Pick one file.
Take a pull using the credential provider.
Push the file to Git.

This cycle continues for all files, but at times it fails after 3 or 4 cycles. It’s not consistent—sometimes all cycles complete successfully, but eventually, it throws the error: "Authentication not supported."

@msohn
Copy link
Member

msohn commented Dec 20, 2024

Don't know. Maybe you suffer from some network issues ?

@tomaswolf
Copy link
Contributor

but at times it fails after 3 or 4 cycles

Perhaps you're hitting a server-side rate limit. See https://docs.gitlab.com/ee/security/rate_limits.html and https://docs.gitlab.com/ee/user/gitlab_com/index.html#gitlabcom-specific-rate-limits .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants