CRLF vulnerability in Fiber (gofiber fiber)
At a glance
- Source
- NVD
- EPSS
- EPSS 0.86 % · percentile 59 ()
- State
- PUBLISHED
- Published
- Updated
- Assigner
- GitHub_M
- NVD status
- Modified
Description
In Fiber before version 1.12.6, the filename that is given in c.Attachment() (https://docs.gofiber.io/ctx#attachment) is not escaped, and therefore vulnerable for a CRLF injection attack. I.e. an attacker could upload a custom filename and then give the link to the victim. With this filename, the attacker can change the name of the downloaded file, redirect to another site, change the authorization header, etc. A possible workaround is to serialize the input before passing it to ctx.Attachment().
Weaknesses (CWE)
- CWE-74 — Improper Neutralization of Special Elements in Output Used by a Downstream Component
- CWE-93 — Improper Neutralization of CRLF Sequences
References
Scores
| Version | Score | Vector | Scored by |
|---|---|---|---|
| CVSS 3.1 | MEDIUM 4.2 | CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:N | GitHub_M |
| CVSS 3.1 | MEDIUM 4.2 | CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:N | NVD · security-advisories@github.com (Secondary) |
| CVSS 3.1 | MEDIUM 5.4 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N | NVD · nvd@nist.gov (Primary) |
| CVSS 2.0 | MEDIUM 5.8 | AV:N/AC:M/Au:N/C:P/I:P/A:N | NVD · nvd@nist.gov (Primary) |
Advisories
- GHSA-9cx9-x2gp-9qvh — CRLF vulnerability in Fiber
- GO-2021-0108 — CRLF vulnerability in Fiber in github.com/gofiber/fiber
European references
- ENISA EUVD · EUVD-2021-1299
- GCVE · GCVE-0-2020-15111
Affected configurations (NVD CPE)
cpe:2.3:a:gofiber:fiber:*:*:*:*:*:*:*:*< 1.12.6
Affected products
| Product | Versions |
|---|---|
| gofiber · fiber | affected < 1.12.6 |
Sources
| Source | Licence |
|---|---|
| CVE List (CVEProject cvelistV5) | CVE Program Terms of Use |
| EPSS (FIRST.org) | FIRST — attribution requested |
| ENISA EUVD | ENISA — reproduction authorised, source acknowledged |
| NVD (NIST) via fkie-cad/nvd-json-data-feeds | Public domain — this product uses data from the NVD API but is not endorsed or certified by the NVD |