In this type of attack, an attacker tricks a user into running a specially crafted script on the web server. The specially crafted script can then cause buffer overflow on the web server and execute arbitrary code on the server. In GitHub, we have a variety of ways to login to the application from our browser. We can login via GitHub.com, GitHub Enterprise, GitHub Pages, GitHub Mobile, GitHub Enterprise, GitHub Learning, GitHub Gists, GitHub Enterprise, GitHub Open Source, GitHub Enterprise, GitHub Pro, GitHub Enterprise, GitHub on the App Store, or via SSH. Once we login to GitHub, we can then create a new repository or fork an existing one. The next step depends on the type of application. For applications hosted on GitHub.com, we can edit the repository pages to add a “Get started” link that directs users to the documentation. For GitHub Enterprise, GitHub Pages, GitHub Mobile, GitHub Enterprise, GitHub Learning, GitHub Gists, GitHub Enterprise, GitHub Open Source, GitHub Enterprise, GitHub Pro, GitHub Enterprise, GitHub on the App Store, or GitHub SSH, we can add instructions in the README on how to access the repository. Next, we need to find a vulnerable script in the repository. In GitHub, all the repositories are public and can be viewed by anyone. GitHub provides a search feature that enables us to search the repository for any specific phrase or keyword. The next step is to craft a malicious URL to add to the search query. The URL
Step 2: Open the Vulnerable Script in a Browser
We can then add the malicious URL in the search query to find any vulnerable scripts. This will take us to a URL with a specially crafted script that, when opened, will execute arbitrary code on our machine.
GitHub login URLs
The following are vulnerable URLs that can be used to exploit GitHub.com or GitHub Enterprise:
Create account and create new repository
Once we find a vulnerable script, we will create an account on GitHub and then create a new repository. The next step is to add the malicious URL to the search query.