CVE-2022-31670
Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.
NVD · uneditedHarbor fails to validate the user permissions when updating tag retention policies. By sending a request to update a tag retention policy with an id that belongs to a project that the currently authenticated user doesn’t have access to, the attacker could modify tag retention policies configured in other projects.
Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.
dbcve analysis · high confidenceHarbor container registry has a broken access control vulnerability where the API endpoint for updating tag retention policies fails to verify that the authenticated user has permission to modify policies for the specified project. An authenticated attacker can modify retention rules in projects they don't have access to by supplying arbitrary project IDs in the request.
Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.
Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.
NVD · CPE data>= 1.0.0, < 1.10.13>= 2.0.0, < 2.4.3>= 2.5.0, < 2.5.2CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.
From the vector- Attack vector
- Network
- Complexity
- Low
- Privileges
- Low
- User interaction
- None
- Scope
- Changed
- Confidentiality
- None
- Integrity
- High
- Availability
- None
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:N
Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.
dbcve checksWork through these to decide whether this CVE applies to you.
-
Check Harbor version via UILog into the Harbor web interface. The version is displayed in the bottom-left corner of the web interface footer.Affected if The displayed version falls within these ranges: 1.0.0 to 1.10.12, 2.0.0 to 2.4.2, or 2.5.0 to 2.5.1.
-
Check Harbor version via APIMake a GET request to the Harbor API endpoint /api/v2.0/systeminfo. The version is returned in the response body under the 'harbor_version' field.Affected if The returned version falls within the affected ranges: 1.0.0 to 1.10.12, 2.0.0 to 2.4.2, or 2.5.0 to 2.5.1.
-
Check Harbor version via Docker/KubernetesIf Harbor is deployed via Docker, run 'docker ps' to find the Harbor container, then 'docker exec <container_id> harbor --version' or check the Helm chart values. For Kubernetes, check the deployment manifest or 'kubectl get deployment -n <harbor-namespace>' and inspect the image tag.Affected if The image tag or version matches the affected ranges: 1.0.0 to 1.10.12, 2.0.0 to 2.4.2, or 2.5.0 to 2.5.1.
-
Verify API access is enabledConfirm the Harbor REST API is accessible. The vulnerable endpoint is /api/v2.0/retentions. Check that the API service is running and network-accessible.Affected if The Harbor API is exposed and the server version is in the affected ranges.
You are affected if your Harbor installation version is 1.0.0-1.10.12, 2.0.0-2.4.2, or 2.5.0-2.5.1 and the API endpoint is accessible.
Generated from the published advisory. Verify against your own configuration.
Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.
dbcve · scoped1.10.132.4.32.5.2
Apply the vendor patch which adds proper project permission validation before allowing tag retention policy modifications. Upgrade to the fixed Harbor version.
Harbor 1.10.13 (for 1.x), 2.4.3 (for 2.0.x-2.3.x), or 2.5.2 (for 2.5.x)
- 1. Identify the currently running Harbor version by checking the harbor.yml configuration file or the Harbor interface
- 2. Determine which upgrade path applies based on current version: for 1.x versions upgrade to 1.10.13; for 2.0.x-2.3.x versions upgrade to 2.4.3; for 2.5.0-2.5.1 versions upgrade to 2.5.2
- 3. Backup the current Harbor database and configuration files
- 4. Stop the Harbor services using 'docker-compose down' or the equivalent Kubernetes helm commands
- 5. For Docker Compose deployments: update the harbor.yml with the new version tag and run './install.sh' or 'docker-compose up -d'; for Helm deployments: update the Helm chart version and run 'helm upgrade'
- 6. Verify the upgrade completed successfully by checking the Harbor interface and confirming all services are running
- 7. Test that the authorization fix is working by attempting to modify a tag retention policy in a project the test user has no access to (this should now be denied)
Generated from the published advisory — verify against the referenced sources before acting.
- Consultation3.0 h
- Implementation6.0 h
- Testing3.0 h
- Review / QA2.0 h
An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $3,984.
Scan for this in your stack
Free · runs locallyCheck whether your project pulls in CVE-2022-31670 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.
References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.
Primary sourcesPractitioner notes
ContributedPeer-ranked notes from engineers who’ve handled CVE-2022-31670 in production — separate from our analysis above.
The advisory tells you what broke. It rarely tells you what actually worked. If you’ve dealt with this one, that detail is what the next engineer is searching for.
- The version that genuinely resolved it — not the one the vendor claimed
- A config change or rule that shut the vector down
- A gotcha in the upgrade path that cost you an afternoon
No notes yet
Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.
A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.
- Verified mitigations, workarounds, and config changes
- Version or environment caveats, and links to real fixes
- No weaponised exploit code, or anything meant to cause harm
- No spam, self-promotion, credentials, or personal data