Upgrade dependency "github.com/pavlo-v-chernykh/keystore-go"
Ben131-Go opened this issue · 1 comments
Background
Repo github.com/banzaicloud/koperator
depends on github.com/pavlo-v-chernykh/keystore-go/v4@v4.4.0
.
https://github.com/banzaicloud/koperator/blob/master/go.mod#L23
However, comparing version v4.4.0
of github.com/pavlo-v-chernykh/keystore-go
from proxy.golang.org and github, there are inconsistencies.
"committer": {
"name": "Pavlo Chernykh",
"email": "526266+pavlo-v-chernykh@users.noreply.github.com",
"date": "2022-06-08T08:34:32Z"
}
{"Version":"v4.4.0","Time":"2022-06-01T13:03:22Z"}
So the checksum from the code in github does not match the checksum saved in sum.golang.org. The v4.4.0
tag of github.com/pavlo-v-chernykh/keystore-go
might have been retagged after a minor edition on github. I guess you use proxy.golang.org to get dependencies, but that also shows that your project is depending on the copy of github.com/pavlo-v-chernykh/keystore-go@v4.4.0
before its edition. Depending upon such inconsistent tag version may also result in some unexpected errors as well as build errors due to different proxy settings.
For example, when someone who does not use proxy.golang.org, say GOPROXY=direct
, attempts to get github.com/pavlo-v-chernykh/keystore-go/v4@v4.4.0
, the following error occurs.
go: downloading github.com/pavlo-v-chernykh/keystore-go/v4 v4.4.0
go: github.com/pavlo-v-chernykh/keystore-go/v4@v4.4.0: verifying module: checksum mismatch
downloaded: h1:fBO1dUIpQgrrZ7gXJsvDhpNYsfxCuPr6NNtGHiv8FYo=
sum.golang.org: h1:y9azNmMzvkNBPyczpNRwaV4bm0U6e7Oyrj7gi2/SNFI=
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'.
So, this is a reminder in the hope that you can get rid of this problematic version of project github.com/pavlo-v-chernykh/keystore-go
.
Solution
1. Bump the version of dependency github.com/pavlo-v-chernykh/keystore-go
I would recommend bumping the version of github.com/pavlo-v-chernykh/keystore-go
to a new release to ensure dependency copy in proxy.golang.org and github in sync.
References
Dear @Ben131-Go!
Thank you for sharing this information with us.