GHSA-33p6-fx42-7rf5 BIT-harbor-2020-13788 CVE-2020-13788 GO-2022-0781
Harbor is vulnerable to a limited Server-Side Request Forgery (SSRF) (CVE-2020-13788)
- Severity
- 4.4 / 10
- Medium · CVSS 3.1
- Exploit chance (EPSS)
- 1.30%
- Chance of exploitation in the next 30 days. Higher than 70.50% of scored vulnerabilities.
- Known exploited
- No
- Not in CISA's catalog
- Weakness
- CWE-918 Server-Side Request Forgery (SSRF)
- Fix
2.0.1- Upgrade github.com/goharbor/harbor to this version or later
Description
Impact
Matt Hamilton from Soluble has discovered a limited Server-Side Request Forgery (SSRF) that allowed Harbor project owners to scan the TCP ports of hosts on the Harbor server's internal network.
The vulnerability was immediately fixed by the Harbor team.
Issue
The “Test Endpoint” API, part of the functionality for ensuring a project Webhook is accessible and functional, is vulnerable to a limited SSRF attack. A malicious user that is also a project administrator can use this API for internal port scanning.
Known Attack Vectors
Successful exploitation of this issue will lead to bad actors identifying open TCP ports on any network that is accessible by the Harbor core services
Patches
If your product uses the affected releases of Harbor, update to version 2.0.1 to patch this issue immediately.
https://github.com/goharbor/harbor/releases/tag/v2.0.1
Workarounds
Since only project administrators (the user that created the project) are allowed to test the webhook endpoints configured in Harbor, a Harbor system administrator can control who is a project admin. In addition, Harbor system administrators can enforce a setting where only an administrator is allowed to create new projects instead of the default Everyone. This further restricts who can be a project administrator in Harbor.
For more information
If you have any questions or comments about this advisory, contact cncf-harbor-security@lists.cncf.io View our security policy at https://github.com/goharbor/harbor/security/policy https://nvd.nist.gov/vuln/detail/CVE-2020-13788 https://www.soluble.ai/blog/harbor-ssrf-cve-2020-13788
Affected versions
Go
| Package | Vulnerable | Fixed in |
|---|---|---|
| github.com/goharbor/harbor | >= 1.8.0, < 2.0.1 |
2.0.1 |
| github.com/goharbor/harbor | >= 1.8.0, < 2.0.1+incompatible |
2.0.1+incompatible |
How to fix
Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.
github.com/goharbor/harbor Go → 2.0.1
- go
go get github.com/goharbor/harbor@v2.0.1 && go mod tidy
Severity breakdown
CVSS 3.1 4.4
CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:N/A:N/E:P/RL:O/RC:C
- Attack vector
- Network
- Attack complexity
- High
- Privileges required
- High
- User interaction
- None
- Scope
- Unchanged
- Confidentiality
- High
- Integrity
- None
- Availability
- None
- Exploit maturity
- Proof of concept
Weakness
CWE-918: Server-Side Request Forgery (SSRF)
The web server receives a URL or similar request from an upstream component and retrieves the contents of this URL, but it does not sufficiently ensure that the request is being sent to the expected destination.
References
Advisories
Other links
Timeline
- Published
- Last updated by the source
- Latest EPSS score
Related advisories
| Advisory | Severity | Why it's related |
|---|---|---|
| GHSA-prh4-vhfh-24mj Harbor: LDAP password and OIDC secret are not redacted in the audit log | Medium | Also affects github.com/goharbor/harbor |
| GHSA-hj7x-hmf2-hc2p Harbor allows the use of the default password for web UI login | Critical | Also affects github.com/goharbor/harbor |
| GHSA-h27m-3qw8-3pw8 Possible ORM Leak Vulnerability in the Harbor | Medium | Also affects github.com/goharbor/harbor |
| GHSA-f9vc-vf3r-pqqq Harbor repository description page has Cross-site Scripting vulnerability | Medium | Also affects github.com/goharbor/harbor |
| GHSA-r864-28pw-8682 Harbor fails to validate the user permissions when updating p2p preheat policies | High | Also affects github.com/goharbor/harbor |
| GHSA-hw28-333w-qxp3 Harbor fails to validate the user permissions when updating project configurations | Medium | Also affects github.com/goharbor/harbor |
| GHSA-vw63-824v-qf2j SQL Injection in Harbor scan log API | Medium | Also affects github.com/goharbor/harbor |
| GHSA-5757-v49g-f6r7 Open Redirect URL in Harbor | Medium | Also affects github.com/goharbor/harbor |
MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.
Check your repos with MergeHarbor