VDB
Sign up
MEDIUM

GHSA-8hqg-whrw-pv92

Ollama does not validate the format of the digest (sha256 with 64 hex digits)

Quick fix

GHSA-8hqg-whrw-pv92 — github.com/ollama/ollama: upgrade to the fixed version with the command below.

go get github.com/ollama/ollama@v0.1.34

Details

Ollama before 0.1.34 does not validate the format of the digest (sha256 with 64 hex digits) when getting the model path, and thus mishandles the TestGetBlobsPath test cases such as fewer than 64 hex digits, more than 64 hex digits, or an initial `../` substring.

Are you affected?

Enter the version of the package you're using.

Affected packages

Go/github.com/ollama/ollama
Introduced in: 0Fixed in: 0.1.34
Fixgo get github.com/ollama/ollama@v0.1.34

References

Check it before you install it

One call answers whether to add this package: known advisories, CISA KEV, and whether the name is a hallucinated or freshly squatted one. No key needed to try it.

curl -s https://vdb.ai.kr/v1/ai/check-packages \
  -H 'Content-Type: application/json' \
  -d '{"packages":["pkg:golang/github.com/ollama/ollama"]}'