{"id":41959703,"url":"https://github.com/seanpesce/lib2shell","last_synced_at":"2026-01-25T22:54:05.383Z","repository":{"id":186623468,"uuid":"612435921","full_name":"SeanPesce/lib2shell","owner":"SeanPesce","description":"Shared library implementations that transform the containing process into a shell when loaded (useful for privilege escalation, argument injection, file overwrites, LD_PRELOAD, etc.).","archived":false,"fork":false,"pushed_at":"2024-02-15T15:54:11.000Z","size":20,"stargazers_count":27,"open_issues_count":0,"forks_count":11,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-11T22:28:23.109Z","etag":null,"topics":["dll","dlopen","dy","dylib","dynamic","escalation","ld-preload","ldpreload","lib","libraries","library","loadlibrary","object","payload","privesc","privilege","shared","shell","so"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SeanPesce.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2023-03-11T00:16:31.000Z","updated_at":"2025-08-29T16:33:51.000Z","dependencies_parsed_at":null,"dependency_job_id":"3a5681b8-c9f8-4880-8b9b-60f2366154e7","html_url":"https://github.com/SeanPesce/lib2shell","commit_stats":{"total_commits":4,"total_committers":1,"mean_commits":4.0,"dds":0.0,"last_synced_commit":"811a8153f3afdac58984e42cdde05936823d68e1"},"previous_names":["seanpesce/lib2shell"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/SeanPesce/lib2shell","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeanPesce%2Flib2shell","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeanPesce%2Flib2shell/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeanPesce%2Flib2shell/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeanPesce%2Flib2shell/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SeanPesce","download_url":"https://codeload.github.com/SeanPesce/lib2shell/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeanPesce%2Flib2shell/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28761227,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-25T20:56:06.009Z","status":"ssl_error","status_checked_at":"2026-01-25T20:54:48.203Z","response_time":113,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["dll","dlopen","dy","dylib","dynamic","escalation","ld-preload","ldpreload","lib","libraries","library","loadlibrary","object","payload","privesc","privilege","shared","shell","so"],"created_at":"2026-01-25T22:54:03.939Z","updated_at":"2026-01-25T22:54:05.370Z","avatar_url":"https://github.com/SeanPesce.png","language":"C++","readme":"# lib2shell  \n\n**Author: Sean Pesce**  \n\n## Overview  \n\nShared library implementations that transform the containing process into a shell on load (useful for privilege escalation, argument injection, file overwrites, etc.). A write-up of a privilege escalation scenario using this technique can be found on [my blog](https://seanpesce.blogspot.com/2023/03/leveraging-ssh-keygen-for-arbitrary.html).\n\n## Usage  \n\n**([Many examples on GTFOBins](https://gtfobins.github.io/#+library%20load))**  \n\nExamples for Unix operating systems:  \n\n```\nssh-keygen -D ./lib2shell.so\n```\n\n```\nopenssl req -engine ./lib2shell.so\n```\n\n\nExamples on Windows:  \n\n```\nssh-keygen -D .\\lib2shell.dll\n```\n\n```\nopenssl req -engine .\\lib2shell.dll\n```\n\n## Compiling  \n\nUnix:  \n\n```\nmake\n```\n\nWindows:  \n\nOpen the project in Visual studio, select your build configuration (\"Release\" and your target architecture), then in the top menu click *Build*→*Build Solution*.  \n\n---------------------------------------------\n\nFor inquiries and/or information about me, visit my **[personal website](https://SeanPesce.github.io)**.  \n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseanpesce%2Flib2shell","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fseanpesce%2Flib2shell","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseanpesce%2Flib2shell/lists"}