CWE-427
Allowed-with-ReviewUncontrolled Search Path Element
Abstraction: Base · Status: Draft
The product uses a fixed or controlled search path to find resources, but one or more locations in that path can be under the control of unintended actors.
1859 vulnerabilities reference this CWE, most recent first.
GHSA-79V3-H2VF-VCG6
Vulnerability from github – Published: 2022-05-24 16:49 – Updated: 2024-04-04 01:09A non-privileged user or program can put code and a config file in a known non-privileged path (under C:/usr/local/) that will make curl <= 7.65.1 automatically run the code (as an openssl "engine") on invocation. If that curl is invoked by a privileged user it can do anything it wants.
{
"affected": [],
"aliases": [
"CVE-2019-5443"
],
"database_specific": {
"cwe_ids": [
"CWE-427",
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2019-07-02T19:15:00Z",
"severity": "HIGH"
},
"details": "A non-privileged user or program can put code and a config file in a known non-privileged path (under C:/usr/local/) that will make curl \u003c= 7.65.1 automatically run the code (as an openssl \"engine\") on invocation. If that curl is invoked by a privileged user it can do anything it wants.",
"id": "GHSA-79v3-h2vf-vcg6",
"modified": "2024-04-04T01:09:04Z",
"published": "2022-05-24T16:49:17Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2019-5443"
},
{
"type": "WEB",
"url": "https://curl.haxx.se/docs/CVE-2019-5443.html"
},
{
"type": "WEB",
"url": "https://security.netapp.com/advisory/ntap-20191017-0002"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuapr2020.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuoct2020.html"
},
{
"type": "WEB",
"url": "https://www.oracle.com/technetwork/security-advisory/cpuoct2019-5072832.html"
},
{
"type": "WEB",
"url": "http://www.openwall.com/lists/oss-security/2019/06/24/1"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/108881"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-7C4J-4VWF-C9VR
Vulnerability from github – Published: 2026-06-15 12:32 – Updated: 2026-06-15 12:32Multiple printer drivers provided by Ricoh Company, Ltd. and KONICA MINOLTA JAPAN, INC. contain a privilege escalation vulnerability. If this vulnerability is exploited, an attacker who can log in to a computer running an affected printer driver could elevate privileges by using a specially crafted driver.
{
"affected": [],
"aliases": [
"CVE-2026-50100"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-06-15T10:16:28Z",
"severity": "HIGH"
},
"details": "Multiple printer drivers provided by Ricoh Company, Ltd. and KONICA MINOLTA JAPAN, INC. contain a privilege escalation vulnerability. If this vulnerability is exploited, an attacker who can log in to a computer running an affected printer driver could elevate privileges by using a specially crafted driver.",
"id": "GHSA-7c4j-4vwf-c9vr",
"modified": "2026-06-15T12:32:44Z",
"published": "2026-06-15T12:32:44Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-50100"
},
{
"type": "WEB",
"url": "https://jp.ricoh.com/security/products/vulnerabilities/vul?id=ricoh-2025-000002"
},
{
"type": "WEB",
"url": "https://jvn.jp/en/jp/JVN55319858"
},
{
"type": "WEB",
"url": "https://www.konicaminolta.jp/business/support/important/260615_01_01.html"
},
{
"type": "WEB",
"url": "https://www.ricoh.com/products/security/vulnerabilities/vul?id=ricoh-2025-000002"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
},
{
"score": "CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X",
"type": "CVSS_V4"
}
]
}
GHSA-7C65-3HQV-HVMM
Vulnerability from github – Published: 2024-11-19 18:31 – Updated: 2025-11-04 00:32Qualys discovered that needrestart, before version 3.8, allows local attackers to execute arbitrary code as root by tricking needrestart into running the Python interpreter with an attacker-controlled PYTHONPATH environment variable.
{
"affected": [],
"aliases": [
"CVE-2024-48990"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2024-11-19T18:15:21Z",
"severity": "HIGH"
},
"details": "Qualys discovered that needrestart, before version 3.8, allows local attackers to execute arbitrary code as root by tricking needrestart into running the Python interpreter with an attacker-controlled PYTHONPATH environment variable.",
"id": "GHSA-7c65-3hqv-hvmm",
"modified": "2025-11-04T00:32:04Z",
"published": "2024-11-19T18:31:06Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-48990"
},
{
"type": "WEB",
"url": "https://github.com/liske/needrestart/commit/fcc9a4401392231bef4ef5ed026a0d7a275149ab"
},
{
"type": "WEB",
"url": "https://lists.debian.org/debian-lts-announce/2024/11/msg00014.html"
},
{
"type": "WEB",
"url": "https://www.cve.org/CVERecord?id=CVE-2024-48990"
},
{
"type": "WEB",
"url": "https://www.openwall.com/lists/oss-security/2024/11/19/1"
},
{
"type": "WEB",
"url": "https://www.qualys.com/2024/11/19/needrestart/needrestart.txt"
},
{
"type": "WEB",
"url": "http://seclists.org/fulldisclosure/2024/Nov/17"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-7C9C-6HFM-P3HX
Vulnerability from github – Published: 2022-10-13 12:00 – Updated: 2022-10-14 19:00Dell GeoDrive, versions prior to 2.2, contains Multiple DLL Hijacking Vulnerabilities. A low privilege attacker could potentially exploit this vulnerability, leading to the execution of arbitrary code in the SYSTEM security context.
{
"affected": [],
"aliases": [
"CVE-2022-33921"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2022-10-12T20:15:00Z",
"severity": "HIGH"
},
"details": "Dell GeoDrive, versions prior to 2.2, contains Multiple DLL Hijacking Vulnerabilities. A low privilege attacker could potentially exploit this vulnerability, leading to the execution of arbitrary code in the SYSTEM security context.",
"id": "GHSA-7c9c-6hfm-p3hx",
"modified": "2022-10-14T19:00:42Z",
"published": "2022-10-13T12:00:28Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-33921"
},
{
"type": "WEB",
"url": "https://www.dell.com/support/kbdoc/000203632"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-7FQV-676X-QPRH
Vulnerability from github – Published: 2022-05-13 01:23 – Updated: 2022-05-13 01:23SolarWinds Orion Platform before 2018.4 Hotfix 2 allows privilege escalation through the RabbitMQ service.
{
"affected": [],
"aliases": [
"CVE-2019-9546"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2019-03-01T22:29:00Z",
"severity": "CRITICAL"
},
"details": "SolarWinds Orion Platform before 2018.4 Hotfix 2 allows privilege escalation through the RabbitMQ service.",
"id": "GHSA-7fqv-676x-qprh",
"modified": "2022-05-13T01:23:04Z",
"published": "2022-05-13T01:23:04Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2019-9546"
},
{
"type": "WEB",
"url": "https://github.com/active-labs/Advisories/blob/master/2019/ACTIVE-2019-005.md"
},
{
"type": "WEB",
"url": "https://support.solarwinds.com/SuccessCenter/s/article/CVE-2019-9546-Orion-Platform-Vulnerability"
},
{
"type": "WEB",
"url": "https://support.solarwinds.com/Success_Center/Orion_Platform/Orion_Documentation/Additional_Resources/Orion_Platform_2018-4_Hotfix_2"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-7FW8-2J3X-V679
Vulnerability from github – Published: 2023-12-12 15:30 – Updated: 2023-12-14 21:31In BeyondTrust Privilege Management for Windows (aka PMfW) through 5.7, a SYSTEM installation causes Cryptbase.dll to be loaded from the user-writable location %WINDIR%\Temp.
{
"affected": [],
"aliases": [
"CVE-2020-28369"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-12-12T15:15:07Z",
"severity": "HIGH"
},
"details": "In BeyondTrust Privilege Management for Windows (aka PMfW) through 5.7, a SYSTEM installation causes Cryptbase.dll to be loaded from the user-writable location %WINDIR%\\Temp.",
"id": "GHSA-7fw8-2j3x-v679",
"modified": "2023-12-14T21:31:15Z",
"published": "2023-12-12T15:30:59Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-28369"
},
{
"type": "WEB",
"url": "https://www.beyondtrust.com/privilege-management/windows-mac"
},
{
"type": "WEB",
"url": "https://www.beyondtrust.com/trust-center/security-advisories/bt22-08"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-7G57-82XX-WRWM
Vulnerability from github – Published: 2025-01-24 00:31 – Updated: 2025-01-25 00:33A DLL hijacking vulnerability in iTop VPN v16.0 allows attackers to execute arbitrary code via placing a crafted DLL file into the path \ProgramData\iTop VPN\Downloader\vpn6.
{
"affected": [],
"aliases": [
"CVE-2024-53588"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-01-23T22:15:13Z",
"severity": "HIGH"
},
"details": "A DLL hijacking vulnerability in iTop VPN v16.0 allows attackers to execute arbitrary code via placing a crafted DLL file into the path \\ProgramData\\iTop VPN\\Downloader\\vpn6.",
"id": "GHSA-7g57-82xx-wrwm",
"modified": "2025-01-25T00:33:09Z",
"published": "2025-01-24T00:31:46Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-53588"
},
{
"type": "WEB",
"url": "https://github.com/JonathanLauener/iTop-privesc"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-7G6H-CV4C-GW4Q
Vulnerability from github – Published: 2022-11-11 19:00 – Updated: 2022-11-17 15:30Uncontrolled search path element in the Intel(R) Advanced Link Analyzer Pro before version 22.2 and Standard edition software before version 22.1.1 STD may allow an authenticated user to potentially enable escalation of privilege via local access.
{
"affected": [],
"aliases": [
"CVE-2022-27638"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2022-11-11T16:15:00Z",
"severity": "HIGH"
},
"details": "Uncontrolled search path element in the Intel(R) Advanced Link Analyzer Pro before version 22.2 and Standard edition software before version 22.1.1 STD may allow an authenticated user to potentially enable escalation of privilege via local access.",
"id": "GHSA-7g6h-cv4c-gw4q",
"modified": "2022-11-17T15:30:23Z",
"published": "2022-11-11T19:00:31Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-27638"
},
{
"type": "WEB",
"url": "https://www.intel.com/content/www/us/en/security-center/advisory/intel-sa-00715.html"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-7G7R-GX96-252G
Vulnerability from github – Published: 2026-07-24 14:00 – Updated: 2026-07-24 14:00Summary
AppImage targets built by app-builder-lib could use an empty path component when setting the LD_LIBRARY_PATH environment variable at runtime. This causes the current working directory to be added to the dynamic linker search path, which may allow an attacker to execute arbitrary code by placing a malicious shared library in the directory from which the AppImage is launched.
This vulnerability is the same class as CVE-2024-41817.
Details
The vulnerability existed in two independent code paths within app-builder-lib (toolset 1.0.0) and through upstream dependency app-builder-bin (toolset 0.0.0).
Path 1 — Modern static runtime (AppRun generated by TypeScript)
The AppRun script generated by app-builder-lib contained this line:
export LD_LIBRARY_PATH="${APPDIR}/usr/lib:${LD_LIBRARY_PATH}"
When LD_LIBRARY_PATH is not set in the environment at launch time, this evaluates to:
/path/to/app.AppDir/usr/lib:
The trailing : is treated by the dynamic linker as an empty path component, which resolves to the current working directory. If an attacker can place a malicious shared library (e.g., libfoo.so) in the directory from which the AppImage is executed, that library will be loaded in place of the legitimate one, resulting in arbitrary code execution.
The same issue affected PATH, XDG_DATA_DIRS, and GSETTINGS_SCHEMA_DIR in the same script.
export LD_LIBRARY_PATH="${APPDIR}/usr/lib${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}"
Path 2 — Legacy FUSE2 toolset (app-builder-bin)
AppImage targets built using the legacy FUSE2 toolset (toolsets.appimage = "0.0.0") delegated AppRun script generation to the app-builder-bin Go binary, which contained the same vulnerable template:
https://github.com/develar/app-builder/blob/7004925f95d8f034fc88d7e782c9aa7583debb8e/pkg/package-format/appimage/templates/AppRun.sh#L27
Impact
An attacker with the ability to write files to the directory from which a vulnerable AppImage is executed can cause arbitrary shared libraries to be loaded into the application process, resulting in arbitrary code execution with the privileges of the user running the AppImage.
Affected Versions
This was fully resolved in app-builder-lib@26.15.0 (commit 01b8ba979, PR #9829) when app-builder-bin was removed from the dependency tree entirely and all AppImage construction was migrated to the TypeScript implementation.
Workarounds
Set LD_LIBRARY_PATH to a non-empty value before launching the AppImage, so that the concatenation does not produce an empty path component. Alternatively, avoid running AppImage files from world-writable directories such as /tmp.
{
"affected": [
{
"package": {
"ecosystem": "npm",
"name": "app-builder-lib"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "26.15.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-54672"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": true,
"github_reviewed_at": "2026-07-24T14:00:59Z",
"nvd_published_at": "2026-06-30T23:17:27Z",
"severity": "HIGH"
},
"details": "### Summary\n\n`AppImage` targets built by `app-builder-lib` could use an empty path component when setting the `LD_LIBRARY_PATH` environment variable at runtime. This causes the current working directory to be added to the dynamic linker search path, which may allow an attacker to execute arbitrary code by placing a malicious shared library in the directory from which the `AppImage` is launched.\n\nThis vulnerability is the same class as [`CVE-2024-41817`](https://github.com/ImageMagick/ImageMagick/security/advisories/GHSA-8rxc-922v-phg8).\n\n### Details\n\nThe vulnerability existed in two independent code paths within `app-builder-lib` (toolset `1.0.0`) and through upstream dependency `app-builder-bin` (toolset `0.0.0`).\n\n#### Path 1 \u2014 Modern static runtime (`AppRun` generated by TypeScript)\n\nThe `AppRun` script generated by `app-builder-lib` contained this line:\n\n```bash\nexport LD_LIBRARY_PATH=\"${APPDIR}/usr/lib:${LD_LIBRARY_PATH}\"\n```\n\nWhen `LD_LIBRARY_PATH` is not set in the environment at launch time, this evaluates to:\n\n```\n/path/to/app.AppDir/usr/lib:\n```\n\nThe trailing `:` is treated by the dynamic linker as an empty path component, which resolves to the current working directory. If an attacker can place a malicious shared library (e.g., `libfoo.so`) in the directory from which the `AppImage` is executed, that library will be loaded in place of the legitimate one, resulting in arbitrary code execution.\n\nThe same issue affected `PATH`, `XDG_DATA_DIRS`, and `GSETTINGS_SCHEMA_DIR` in the same script.\n\n```bash\nexport LD_LIBRARY_PATH=\"${APPDIR}/usr/lib${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}\"\n```\n\n#### Path 2 \u2014 Legacy FUSE2 toolset (`app-builder-bin`)\n\n`AppImage` targets built using the legacy FUSE2 toolset (`toolsets.appimage = \"0.0.0\"`) delegated `AppRun` script generation to the `app-builder-bin` Go binary, which contained the same vulnerable template:\n\nhttps://github.com/develar/app-builder/blob/7004925f95d8f034fc88d7e782c9aa7583debb8e/pkg/package-format/appimage/templates/AppRun.sh#L27\n\n### Impact\n\nAn attacker with the ability to write files to the directory from which a vulnerable `AppImage` is executed can cause arbitrary shared libraries to be loaded into the application process, resulting in arbitrary code execution with the privileges of the user running the `AppImage`.\n\n### Affected Versions\n\nThis was fully resolved in **`app-builder-lib@26.15.0`** (commit [`01b8ba979`](https://github.com/electron-userland/electron-builder/commit/01b8ba979), PR [#9829](https://github.com/electron-userland/electron-builder/pull/9829)) when `app-builder-bin` was removed from the dependency tree entirely and all AppImage construction was migrated to the TypeScript implementation.\n\n### Workarounds\n\nSet `LD_LIBRARY_PATH` to a non-empty value before launching the `AppImage`, so that the concatenation does not produce an empty path component. Alternatively, avoid running `AppImage` files from world-writable directories such as `/tmp`.",
"id": "GHSA-7g7r-gx96-252g",
"modified": "2026-07-24T14:00:59Z",
"published": "2026-07-24T14:00:59Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/electron-userland/electron-builder/security/advisories/GHSA-7g7r-gx96-252g"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-54672"
},
{
"type": "WEB",
"url": "https://github.com/electron-userland/electron-builder/commit/01b8ba979d1db44543e18d07b4ad94953deb10ea"
},
{
"type": "PACKAGE",
"url": "https://github.com/electron-userland/electron-builder"
},
{
"type": "WEB",
"url": "https://github.com/electron-userland/electron-builder/releases/tag/electron-builder@26.15.0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "electron-updater: Uncontrolled search path elements within `AppImage` built by `app-builder-lib`"
}
GHSA-7GQQ-55WR-J9W3
Vulnerability from github – Published: 2024-06-11 03:30 – Updated: 2024-06-11 03:30Dell OpenManage Server Administrator, versions 11.0.1.0 and prior, contains a Local Privilege Escalation vulnerability via XSL Hijacking. A local low-privileged malicious user could potentially exploit this vulnerability and escalate their privilege to the admin user and gain full control of the machine. Exploitation may lead to a complete system compromise.
{
"affected": [],
"aliases": [
"CVE-2024-37130"
],
"database_specific": {
"cwe_ids": [
"CWE-427"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2024-06-11T02:15:08Z",
"severity": "HIGH"
},
"details": "Dell OpenManage Server Administrator, versions 11.0.1.0 and prior, contains a Local Privilege Escalation vulnerability via XSL Hijacking. A local low-privileged malicious user could potentially exploit this vulnerability and escalate their privilege to the admin user and gain full control of the machine. Exploitation may lead to a complete system compromise.",
"id": "GHSA-7gqq-55wr-j9w3",
"modified": "2024-06-11T03:30:57Z",
"published": "2024-06-11T03:30:57Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-37130"
},
{
"type": "WEB",
"url": "https://www.dell.com/support/kbdoc/en-us/000225914/dsa-2024-264-dell-openmanage-server-administrator-omsa-security-update-for-local-privilege-escalation-via-xsl-hijacking-vulnerability"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
Mitigation
Strategy: Attack Surface Reduction
Hard-code the search path to a set of known-safe values (such as system directories), or only allow them to be specified by the administrator in a configuration file. Do not allow these settings to be modified by an external party. Be careful to avoid related weaknesses such as CWE-426 and CWE-428.
Mitigation
Strategy: Attack Surface Reduction
When invoking other programs, specify those programs using fully-qualified pathnames. While this is an effective approach, code that uses fully-qualified pathnames might not be portable to other systems that do not use the same pathnames. The portability can be improved by locating the full-qualified paths in a centralized, easily-modifiable location within the source code, and having the code refer to these paths.
Mitigation
Strategy: Attack Surface Reduction
Remove or restrict all environment settings before invoking other programs. This includes the PATH environment variable, LD_LIBRARY_PATH, and other settings that identify the location of code libraries, and any application-specific search paths.
Mitigation
Check your search path before use and remove any elements that are likely to be unsafe, such as the current working directory or a temporary files directory. Since this is a denylist approach, it might not be a complete solution.
Mitigation
Use other functions that require explicit paths. Making use of any of the other readily available functions that require explicit paths is a safe way to avoid this problem. For example, system() in C does not require a full path since the shell can take care of finding the program using the PATH environment variable, while execl() and execv() require a full path.
CAPEC-38: Leveraging/Manipulating Configuration File Search Paths
This pattern of attack sees an adversary load a malicious resource into a program's standard path so that when a known command is executed then the system instead executes the malicious component. The adversary can either modify the search path a program uses, like a PATH variable or classpath, or they can manipulate resources on the path to point to their malicious components. J2EE applications and other component based applications that are built from multiple binaries can have very long list of dependencies to execute. If one of these libraries and/or references is controllable by the attacker then application controls can be circumvented by the attacker.
CAPEC-471: Search Order Hijacking
An adversary exploits a weakness in an application's specification of external libraries to exploit the functionality of the loader where the process loading the library searches first in the same directory in which the process binary resides and then in other directories. Exploitation of this preferential search order can allow an attacker to make the loading process load the adversary's rogue library rather than the legitimate library. This attack can be leveraged with many different libraries and with many different loading processes. No forensic trails are left in the system's registry or file system that an incorrect library had been loaded.