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

Upgrade 'go-swagger/go-swagger' to avoid build error. #1179

Open
3 of 5 tasks
HappyHacker123 opened this issue Aug 27, 2024 · 6 comments
Open
3 of 5 tasks

Upgrade 'go-swagger/go-swagger' to avoid build error. #1179

HappyHacker123 opened this issue Aug 27, 2024 · 6 comments
Labels
bug Something is not working.

Comments

@HappyHacker123
Copy link

Preflight checklist

Ory Network Project

No response

Describe the bug

Currently oathkeeper depends on go-swagger/go-swagger@v0.30.0. But go-swagger may have retagged version v0.30.0, so the checksum from the code in github does not match the checksum saved in sum.golang.org.
So when trying to download go-swagger directly from Github, the following error will occur.

root@iZj6c5flh0q5ax3d1ttfuhZ:~/temp# GOPROXY=direct go get github.com/go-swagger/go-swagger@v0.30.0
go: downloading github.com/go-swagger/go-swagger v0.30.0
go: github.com/go-swagger/go-swagger@v0.30.0: verifying module: checksum mismatch
        downloaded: h1:USeysUi8+GLwjRR8riKERrBmISIL3bnyOnvmhSB8vrA=
        sum.golang.org: h1:HakSyutD7Ek9ndkR8Fxy6WAoQtgu7UcAmZCTa6SzawA=

SECURITY ERROR
This download does NOT match the one reported by the checksum server.
The bits may have been replaced on the origin server, or an attacker may
have intercepted the download attempt.

For more information, see 'go help module-auth'.

Reproducing the bug

Run the following command.

GOPROXY=direct go get github.com/go-swagger/go-swagger@v0.30.0

Relevant log output

No response

Relevant configuration

No response

Version

0.40.7-pre.0

On which operating system are you observing this issue?

None

In which environment are you deploying?

None

Additional Context

github.com/go-swagger/go-swagger@v0.30.4 doesn't have such error, upgrade to v0.30.4 might be a good choice

@HappyHacker123 HappyHacker123 added the bug Something is not working. label Aug 27, 2024
@alnr
Copy link
Collaborator

alnr commented Sep 9, 2024

Very odd. Let's see if there's any movement in this issue: go-swagger/go-swagger#3118

@HappyHacker123
Copy link
Author

@alnr Thanks for your reply! I add some background information on the upstream issue, hope it can help.

@alnr
Copy link
Collaborator

alnr commented Sep 11, 2024

The oathkeeper build seems to work with the existing version, is there even a reason to upgrade?

@HappyHacker123
Copy link
Author

I guess you use proxy.golang.org to get dependencies. If you set GOPROXY=direct and try to download go-swagger as i mentioned before, errors will occur.

So this issue more like a reminder in the hope that you can get rid of this problematic version of go-swagger if possible. As it might be a problem for users who have to set GOPROXY=direct.

@alnr
Copy link
Collaborator

alnr commented Sep 11, 2024

Ah, got it, thanks! Surely you must be curious why the version was re-tagged though? I don't have time to comb through the diffs in go-swagger since this event, so I'm hesitant to change versions now.

@HappyHacker123
Copy link
Author

Surely you must be curious why the version was re-tagged though?

Yeah, i guess maybe a minor mistake was found, they don't want to release a new version so they retagged it :).

I don't have time to comb through the diffs in go-swagger since this event, so I'm hesitant to change versions now.

No hurry, you can come back at this whenever possible. I'm using proxy.golang.org to temporarily avoid the situation. Hope someday it will be fixed :)

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

No branches or pull requests

3 participants
@alnr @HappyHacker123 and others