{"id":25405954,"url":"https://github.com/CBLabresearch/PhantomExecution","last_synced_at":"2025-10-31T01:31:46.504Z","repository":{"id":256133466,"uuid":"854405718","full_name":"CBLabresearch/PhantomExecution","owner":"CBLabresearch","description":"Self Cleanup in post-ex job","archived":false,"fork":false,"pushed_at":"2024-09-10T10:43:22.000Z","size":441,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2024-09-10T12:03:07.739Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","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/CBLabresearch.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":"2024-09-09T05:42:10.000Z","updated_at":"2024-09-10T10:57:32.000Z","dependencies_parsed_at":"2024-09-10T11:56:45.970Z","dependency_job_id":null,"html_url":"https://github.com/CBLabresearch/PhantomExecution","commit_stats":null,"previous_names":["cblabresearch/phantomexecution"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CBLabresearch%2FPhantomExecution","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CBLabresearch%2FPhantomExecution/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CBLabresearch%2FPhantomExecution/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CBLabresearch%2FPhantomExecution/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CBLabresearch","download_url":"https://codeload.github.com/CBLabresearch/PhantomExecution/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239088378,"owners_count":19579434,"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":[],"created_at":"2025-02-16T05:03:30.652Z","updated_at":"2025-10-31T01:31:46.080Z","avatar_url":"https://github.com/CBLabresearch.png","language":"C++","funding_links":[],"categories":["C++"],"sub_categories":[],"readme":"# PhantomExecution\n![](https://github.com/user-attachments/assets/4578b633-0874-433e-8011-fdddc3330f9f)\n\n\u003e Self Cleanup in post-ex job, suit for CobaltStrike \n\n\n\nWhen the target of process injection is the current process, and when the post-ex job is executed and the thread exits, the memory will look like this\n\n![](https://images-1258433570.cos.ap-beijing.myqcloud.com/imagesimage-20240910183625105.png)\n\nThen, perform 5 screenshots:\n\n![](https://images-1258433570.cos.ap-beijing.myqcloud.com/imagesimage-20240910183718333.png)\n\nSo, we use the RDI  itself to clean up itself and the memory area  which the post-ex job is executed.\n\nThis is also a general memory execution plugin\n\n![](https://images-1258433570.cos.ap-beijing.myqcloud.com/imagesimage-20240910184202951.png)\n\nThe code is not beautiful, and many IOCs are not evasioned. Please modify it according to OPSEC principles. This code only shows the self clean technology.\n\n\n\nwriteup: https://mp.weixin.qq.com/s/V4EdhGzyzxln0LzU99hqpA\n\nconference: https://github.com/knownsec/KCon/blob/master/2024/%E9%AB%98%E7%BA%A7%E6%81%B6%E6%84%8F%E8%BD%AF%E4%BB%B6%E5%BC%80%E5%8F%91%E4%B9%8BRDI%E7%9A%84%E8%BF%9B%E5%8C%96.pdf\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCBLabresearch%2FPhantomExecution","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FCBLabresearch%2FPhantomExecution","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCBLabresearch%2FPhantomExecution/lists"}