{"answers":{"affected":"It affects 1 product.","exploited":"There is no known exploitation of CVE-2017-7692 in the wild and no public exploit code.","fix":"Apply the vendor's patch.","what":"CVE-2017-7692 is a high-severity command injection vulnerability in Squirrelmail Squirrelmail, published on 20 Apr 2017. Any signed-in user can exploit it over the network, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2017-7692 and fix it if it is affected.\n\nWhat it is: CVE-2017-7692 is a high-severity command injection vulnerability in Squirrelmail Squirrelmail, published on 20 Apr 2017. Any signed-in user can exploit it over the network, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2017-7692 in the wild and no public exploit code.\n\nAffected product: Squirrelmail Squirrelmail. No package-level version data is available, so check the vendor advisory linked from the reference page.\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-2017-7692/ (Markdown: https://insights.sbomify.com/CVE-2017-7692/index.md)","id":"CVE-2017-7692","markdown":"https://insights.sbomify.com/CVE-2017-7692/index.md","name":"CVE-2017-7692","record":{"aliases":["CVE-2017-5181","DLA-941-1","DSA-3852-1","GHSA-w6jv-pvcq-chp4","MGASA-2017-0121","UBUNTU-CVE-2017-7692"],"analysis":{"component_type":"web_application","fix_type":"patch","impacts":["code_execution"],"network_reachable":"yes","non_default_config":true,"product_category":"SquirrelMail webmail","requires_auth":"low_privilege","summary":"Authenticated attackers can execute arbitrary shell commands on the server by injecting parameters into the sendmail command via email attachments and settings.","user_interaction":"not_required","vuln_class":"command_injection"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"mitre","cpe":[{"product":"squirrelmail","vendor":"squirrelmail"}],"cvss":{"score":8.8,"severity":"high","source":"nvd","vector":"CVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","version":"3.0"},"cwes":[{"id":"CWE-20","name":"Improper Input Validation"}],"description":"SquirrelMail 1.4.22 (and other versions before 20170427_0200-SVN) allows post-authentication remote code execution via a sendmail.cf file that is mishandled in a popen call. It's possible to exploit this vulnerability to execute arbitrary shell commands on the remote server. The problem is in the Deliver_SendMail.class.php with the initStream function that uses escapeshellcmd() to sanitize the sendmail command before executing it. The use of escapeshellcmd() is not correct in this case since it doesn't escape whitespaces, allowing the injection of arbitrary command parameters. The problem is in -f$envelopefrom within the sendmail command line. Hence, if the target server uses sendmail and SquirrelMail is configured to use it as a command-line program, it's possible to trick sendmail into using an attacker-provided configuration file that triggers the execution of an arbitrary command. For exploitation, the attacker must upload a sendmail.cf file as an email attachment, and inject the sendmail.cf filename with the -C option within the \"Options \u003e Personal Informations \u003e Email Address\" setting.","ecosystems":[],"exploits":{"exploitdb":1,"first_seen":"2017-04-23","github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[{"date":"2017-04-23","kind":"exploitdb","ref":"41910","stars":null,"title":"SquirrelMail \u003c 1.4.22 - Remote Code Execution"}],"tier":"poc_unverified"},"has_fix":true,"headline":"Command injection in n/a","id":"CVE-2017-7692","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":null,"product":"squirrelmail:squirrelmail","products":["squirrelmail:squirrelmail"],"type":"command_injection","year":"2017"},"n_packages":0,"n_references":8,"next":{"headline":"Path traversal in n/a","id":"CVE-2017-7693"},"packages":[],"prev":{"headline":"Code injection in n/a","id":"CVE-2017-7691"},"products":["n/a"],"published":"2017-04-20","related":[{"cvss_score":10,"headline":"Command injection in n/a","id":"CVE-2002-0516","kev_date_added":null,"published":"2003-04-02"},{"cvss_score":9.8,"headline":"Deserialization in n/a","id":"CVE-2020-14932","kev_date_added":null,"published":"2020-06-20"},{"cvss_score":8.8,"headline":"Deserialization in n/a","id":"CVE-2020-14933","kev_date_added":null,"published":"2020-06-20"},{"cvss_score":7.5,"headline":"Cross-site request forgery in n/a","id":"CVE-2007-2631","kev_date_added":null,"published":"2007-05-13"},{"cvss_score":7.5,"headline":"Code injection in n/a","id":"CVE-2006-2842","kev_date_added":null,"published":"2006-06-06"},{"cvss_score":7.5,"headline":"Cross-site request forgery in n/a","id":"CVE-2002-1648","kev_date_added":null,"published":"2005-03-28"}],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"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":"attribution","licence":"GPL-2.0-or-later","name":"Exploit-DB"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","updated":"2024-08-05","vendors":["n/a"]},"summary":"Authenticated attackers can execute arbitrary shell commands on the server by injecting parameters into the sendmail command via email attachments and settings.","url":"https://insights.sbomify.com/CVE-2017-7692/"}