{"answers":{"affected":"5 open source packages ship an affected version, including org.apache.nifi.registry:nifi-registry-core, nifi and org.apache.nifi:nifi. It affects 2 products.","exploited":"There is no known exploitation of CVE-2022-33140 in the wild and no public exploit code.","fix":"Upgrade org.apache.nifi.registry:nifi-registry-core to 1.16.3 or later.","what":"CVE-2022-33140 is a high-severity command injection vulnerability in Apache Nifi, published on 15 Jun 2022. Any signed-in user can exploit it over the network, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2022-33140 and fix it if it is affected.\n\nWhat it is: CVE-2022-33140 is a high-severity command injection vulnerability in Apache Nifi, published on 15 Jun 2022. Any signed-in user can exploit it over the network, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2022-33140 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- org.apache.nifi.registry:nifi-registry-core (Maven): affected from 0.6.0; fixed in 1.16.3\n- org.apache.nifi.registry:nifi-registry-core (Maven): affected from 0.6.0; fixed in 1.16.3\n- nifi (Bitnami): affected from 1.10.0 up to 1.16.2; no fix listed\n- org.apache.nifi:nifi (Maven): affected from 1.10.0; fixed in 1.16.3\n- org.apache.nifi:nifi (Maven): affected from 1.10.0; fixed in 1.16.3\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2022-33140/ (Markdown: https://insights.sbomify.com/CVE-2022-33140/index.md)","id":"CVE-2022-33140","markdown":"https://insights.sbomify.com/CVE-2022-33140/index.md","name":"CVE-2022-33140","record":{"aliases":["BIT-nifi-2022-33140","GHSA-77hf-23pq-2g7c"],"analysis":{"component_type":"server_software","fix_type":"patch","impacts":["code_execution"],"network_reachable":"yes","non_default_config":true,"product_category":"Apache NiFi","requires_auth":"low_privilege","summary":"Authenticated privileged users can execute arbitrary OS commands via ShellUserGroupProvider in Apache NiFi when this optional provider is enabled.","user_interaction":"not_required","vuln_class":"command_injection"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"apache","cpe":[{"product":"nifi","vendor":"apache"},{"product":"nifi_registry","vendor":"apache"}],"cvss":{"score":8.8,"severity":"high","source":"nvd","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-78","name":"Improper Neutralization of Special Elements used in an OS Command"}],"description":"The optional ShellUserGroupProvider in Apache NiFi 1.10.0 to 1.16.2 and Apache NiFi Registry 0.6.0 to 1.16.2 does not neutralize arguments for group resolution commands, allowing injection of operating system commands on Linux and macOS platforms. The ShellUserGroupProvider is not included in the default configuration. Command injection requires ShellUserGroupProvider to be one of the enabled User Group Providers in the Authorizers configuration. Command injection also requires an authenticated user with elevated privileges. Apache NiFi requires an authenticated user with authorization to modify access policies in order to execute the command. Apache NiFi Registry requires an authenticated user with authorization to read user groups in order to execute the command. The resolution removes command formatting based on user-provided arguments.","ecosystems":["Bitnami","Maven"],"exploits":{"exploitdb":0,"first_seen":"2025-08-17","github_poc":1,"max_poc_stars":0,"metasploit":0,"nuclei":0,"refs":[{"date":"2025-08-17T08:04:19Z","kind":"github_poc","ref":"https://github.com/shoucheng3/apache__nifi_CVE-2022-33140_1-16-22","stars":0,"title":null}],"tier":"poc_unverified"},"has_fix":true,"headline":"Improper Neutralization of Command Elements in Shell User Group Provider","id":"CVE-2022-33140","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"Bitnami","product":"apache:nifi","products":["apache:nifi"],"type":"command_injection","year":"2022"},"n_packages":5,"n_references":2,"next":{"headline":"This CVE ID has been rejected or withdrawn by its CVE Numbering Authority because it is Unused","id":"CVE-2022-33141"},"packages":[{"ecosystem":"Bitnami","fixed":[],"introduced":["1.10.0"],"last_affected":["1.16.2"],"package":"nifi","purl":"pkg:bitnami/nifi","source":"BIT-nifi-2022-33140"},{"ecosystem":"Maven","fixed":["1.16.3"],"introduced":["0.6.0"],"last_affected":[],"package":"org.apache.nifi.registry:nifi-registry-core","purl":null,"source":"GHSA-77hf-23pq-2g7c"},{"ecosystem":"Maven","fixed":["1.16.3"],"introduced":["0.6.0"],"last_affected":[],"package":"org.apache.nifi.registry:nifi-registry-core","purl":"pkg:maven/org.apache.nifi.registry/nifi-registry-core","source":"GHSA-77hf-23pq-2g7c"},{"ecosystem":"Maven","fixed":["1.16.3"],"introduced":["1.10.0"],"last_affected":[],"package":"org.apache.nifi:nifi","purl":null,"source":"GHSA-77hf-23pq-2g7c"},{"ecosystem":"Maven","fixed":["1.16.3"],"introduced":["1.10.0"],"last_affected":[],"package":"org.apache.nifi:nifi","purl":"pkg:maven/org.apache.nifi/nifi","source":"GHSA-77hf-23pq-2g7c"}],"prev":{"headline":"Auth bypass in Cerberus DMS","id":"CVE-2022-33139"},"products":["Apache NiFi","Apache NiFi Registry"],"published":"2022-06-15","related":[{"cvss_score":9.8,"headline":"Improper Restriction of XML External Entity Reference in Apache NiFi","id":"CVE-2018-1309","kev_date_added":null,"published":"2018-05-23"},{"cvss_score":9.8,"headline":"Apache NiFi XSS issue in context path handling","id":"CVE-2017-15697","kev_date_added":null,"published":"2018-01-23"},{"cvss_score":9.8,"headline":"Injection in Apache NiFi","id":"CVE-2017-5636","kev_date_added":null,"published":"2017-10-19"},{"cvss_score":8.8,"headline":"Apache NiFi: Uncontrolled Resource Consumption through Decompression of HTTP Requests","id":"CVE-2026-68981","kev_date_added":null,"published":"2026-08-03"},{"cvss_score":8.8,"headline":"Apache NiFi: Potential Code Injection with Properties Referencing Remote Resources","id":"CVE-2023-36542","kev_date_added":null,"published":"2023-07-29"},{"cvss_score":8.8,"headline":"Apache NiFi: Potential Code Injection with Database Services using H2","id":"CVE-2023-34468","kev_date_added":null,"published":"2023-06-12"}],"sources":[{"class":"attribution","licence":"Apache-2.0","name":"Bitnami","prefix":"BIT"},{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"},{"class":"open","licence":"CC0","name":"PoC-in-GitHub"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","updated":"2024-08-03","vendors":["Apache Software Foundation"]},"summary":"Authenticated privileged users can execute arbitrary OS commands via ShellUserGroupProvider in Apache NiFi when this optional provider is enabled.","url":"https://insights.sbomify.com/CVE-2022-33140/"}