symfony — security advisory
An issue was discovered in Symfony 2.7.x before 2.7.50, 2.8.x before 2.8.49, 3.x before 3.4.20, 4.0.x before 4.0.15, 4.1.x before 4.1.9, and 4.2.x before 4.2.1. When using the scalar type hint `string` in a setter method (e.g. `setName(string $name)`) of a class that's the `data_class` of a form, and when a file upload is submitted to the corresponding field instead of a normal text input, then `UploadedFile::__toString()` is called which will then return and disclose the path of the uploaded file. If combined with a local file inclusion issue in certain circumstances this could escalate it to a Remote Code Execution.
- Products
- symfony
- Affected versions
- Not specified
- Fixed versions
- 3.4.20+dfsg-1
- CVEs
- CVE-2018-19789
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 00:29 UTC · Revision 1
Source evidence
An issue was discovered in Symfony 2.7.x before 2.7.50, 2.8.x before 2.8.49, 3.x before 3.4.20, 4.0.x before 4.0.15, 4.1.x before 4.1.9, and 4.2.x before 4.2.1. When using the scalar type hint `string` in a setter method (e.g. `setName(string $name)`) of a class that's the `data_class` of a form, and when a file upload is submitted to the corresponding field instead of a normal text input, then `UploadedFile::__toString()` is called which will then return and disclose the path of the uploaded file. If combined with a local file inclusion issue in certain circumstances this could escalate it to a Remote Code Execution.
osv:DEBIAN-CVE-2018-19789
symfony
Fixed versions: 3.4.20+dfsg-1
symfony
Fixed versions: 3.4.20+dfsg-1
symfony
Fixed versions: 3.4.20+dfsg-1
Complete source record
{
"id": "931d6b59429b43f8fa02383c0abbec71ac7a1b9bb6b4cfbb71a6be524e15598d",
"url": "https://osv.dev/vulnerability/DEBIAN-CVE-2018-19789",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "DEBIAN-CVE-2018-19789",
"summary": "An issue was discovered in Symfony 2.7.x before 2.7.50, 2.8.x before 2.8.49, 3.x before 3.4.20, 4.0.x before 4.0.15, 4.1.x before 4.1.9, and 4.2.x before 4.2.1. When using the scalar type hint `string` in a setter method (e.g. `setName(string $name)`) of a class that's the `data_class` of a form, and when a file upload is submitted to the corresponding field instead of a normal text input, then `UploadedFile::__toString()` is called which will then return and disclose the path of the uploaded file. If combined with a local file inclusion issue in certain circumstances this could escalate it to a Remote Code Execution.",
"evidence": "osv:DEBIAN-CVE-2018-19789",
"products": [
{
"name": {
"value": "symfony",
"evidence": "/affected/0/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "3.4.20+dfsg-1",
"evidence": "/affected/0/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "symfony",
"evidence": "/affected/1/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "3.4.20+dfsg-1",
"evidence": "/affected/1/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "symfony",
"evidence": "/affected/2/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "3.4.20+dfsg-1",
"evidence": "/affected/2/ranges"
}
],
"affected_versions": []
}
],
"severity": "medium",
"structured": {
"id": "DEBIAN-CVE-2018-19789",
"aliases": [
"DEBIAN-CVE-2018-19789"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N"
}
],
"affected": [
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "3.4.20+dfsg-1"
}
]
}
],
"package": {
"name": "symfony",
"purl": "pkg:deb/debian/symfony?arch=source&distro=bookworm",
"ecosystem": "Debian:12"
},
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2018-19789.json"
},
"ecosystem_specific": {
"urgency": "not yet assigned"
}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "3.4.20+dfsg-1"
}
]
}
],
"package": {
"name": "symfony",
"purl": "pkg:deb/debian/symfony?arch=source&distro=trixie",
"ecosystem": "Debian:13"
},
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2018-19789.json"
},
"ecosystem_specific": {
"urgency": "not yet assigned"
}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "3.4.20+dfsg-1"
}
]
}
],
"package": {
"name": "symfony",
"purl": "pkg:deb/debian/symfony?arch=source&distro=forky",
"ecosystem": "Debian:14"
},
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2018-19789.json"
},
"ecosystem_specific": {
"urgency": "not yet assigned"
}
}
],
"modified": "2026-10-23T18:03:20.638364807Z",
"provider": "osv",
"upstream": [
"CVE-2018-19789"
],
"references": [
"https://security-tracker.debian.org/tracker/CVE-2018-19789"
]
},
"related_cves": [
{
"value": "CVE-2018-19789",
"evidence": "/upstream"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 421225,
"published_at": "2018-12-18T22:29:04.947+00:00"
}