7.5high
Arbitrary File Write
- Severity
- 7.5high CVSS:3.1 by snyk
- Exploit likelihood
- 1.88% (higher than 80% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- snyk
- Also known as
- GHSA-jcxc-rh6w-wf49GO-2022-0272
Description
This affects all versions of package github.com/kataras/iris; all versions of package github.com/kataras/iris/v12. The unsafe handling of file names during upload using UploadFormFiles method may enable attackers to write to arbitrary locations outside the designated target folder.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| github.com/kataras/iris | before unspecified | CVE List |
| github.com/kataras/iris/v12 | before unspecified | CVE List |
| github.com/kataras/iris/v12 (Go) | before 12.2.0-alpha8 | GitHub Advisory Database, Go Vulnerability Database |
| github.com/kataras/iris (Go) | up to 0.0.2, all versions | GitHub Advisory Database, Go Vulnerability Database |
| iris-go iris | up to 12.1.8, 12.2.0 | NVD |
All scores
| snyk | 7.5high CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H |
| GitHub | 7.5high CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H |
| NVD | 8.8high CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| NVD | 6.8medium CVSS:2.0 | AV:N/AC:M/Au:N/C:P/I:P/A:P |
Classification
What each source says
CVE List
This affects all versions of package github.com/kataras/iris; all versions of package github.com/kataras/iris/v12. The unsafe handling of file names during upload using UploadFormFiles method may enable attackers to write to arbitrary locations outside the designated target folder.
Go Vulnerability Database
The Context.UploadFormFiles function is vulnerable to directory traversal attacks, and can be made to write to arbitrary locations outside the destination directory.
This vulnerability only occurs when built with Go versions prior to 1.17. Go 1.17 and later strip directory paths from filenames returned by "mime/multipart".Part.FileName, which avoids this issue.
NVD (es)
Esto afecta a todas las versiones del paquete github.com/kataras/iris; todas las versiones del paquete github.com/kataras/iris/v12. Un manejo no seguro de los nombres de archivo durante la carga usando el método UploadFormFiles puede permitir a atacantes escribir en ubicaciones arbitrarias fuera de la carpeta de destino designada
References
| https://snyk.io/vuln/SNYK-GOLANG-GITHUBCOMKATARASIRIS-2325169 | exploit, patch, third-party-advisory, web | |
| https://snyk.io/vuln/SNYK-GOLANG-GITHUBCOMKATARASIRISV12-2325170 | exploit, patch, third-party-advisory, web | |
| https://github.com/kataras/iris/commit/e213dba0d32ff66653e0ef124bc5088817264b08 | fix, patch, third-party-advisory, web | |
| https://nvd.nist.gov/vuln/detail/CVE-2021-23772 | advisory | |
| https://github.com/kataras/iris | package | |
| https://pkg.go.dev/vuln/GO-2022-0272 | web | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2021-23772 changed 2024-09-16 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-jcxc-rh6w-wf49 changed 2025-01-14 | CC-BY-4.0 |
| Go Vulnerability Database | GO-2022-0272 changed 2025-01-14 | CC-BY-4.0 |
| NVD | CVE-2021-23772 changed 2026-06-17 | Public domain |