GitFall 2023

Git is a distributed version control system that helps developers track changes to their source code over time. GitHub, on the other hand, is a web-based platform that hosts Git repositories and provides collaboration tools for developers. This course makes use of both Git and GitHub to distribute project code to students.

This guide consists of two parts. The first will walk you through the process of creating a private repository from a GitHub template repository. This is a general guide and can be used for all projects and labs in this course.

The second part will walk you through cloning the repository you created inside the Application Security Project VM using VS Code. It was written for the first project but should be re-usable for other projects and labs in the course by performing the same actions on your host OS instead of the VM.

Create a private repository from a GitHub template

  1. First things first, if you’re not already logged in, go to Georgia Tech GitHub and log in to your account using your GT username and password.

  2. Open the link to the GitHub template from the lab or project write-up.

  3. To create a new private repository from the template,

    • Choose a name for your new repository and select whether you want it to be public or private. In this case, select “Private”.
    • Click the “Create repository from template” button.

    Create new repository

  4. Once the new repository is created, you’ll be redirected to its page. You can find it in your GitHub profile under “Repositories”.

Clone the repository using VS Code

Before proceeding, ensure that you have completed the setup process for the Application Security Project VM.

  1. First, launch VS Code and connect to the Application Security Project VM via SSH.

    If you’re reading this while doing projects 2, 3, or 4, skip the part about connecting to the VM via SSH. You need to clone the repository to a folder on your host OS.

  2. Next, go to the repository that you created on GitHub. Click on the green dropdown button that says “Code” and copy the HTTPS link to your repository.

    Repository Link

  3. Come back to VS Code and open the Integrated Terminal. To do this, navigate to “View” > “Terminal” or press Ctrl+` (backtick).

    In the terminal, type the following command and replace <repository-url> with the copied repository URL:

    git clone <repository-url>
    
    Press Enter to clone the repository.

  4. At this point, VS Code should prompt you to enter your credentials for GitHub. Enter your GT username and password.

    Authentication Prompt

    If you get an error stating, “fatal: Authentication failed” or similar, it might be because you have 2FA enabled on your GitHub account. You will have to use a personal access token instead of your password. GitHub has documentation on how to create one.

    If everything goes well, the you should have a clone of the starterfiles in your home directory!

    Clone Success

  5. Open the starterfiles in VS Code by navigating to “File” > “Open Folder” and selecting the cloned repository directory.

    Folder Select

    The window should exit and re-open shortly, at which point you’ll be prompted for a password. This is the password for the cs3235 user, which is cs3235.

    VS Code might also prompt you asking whether you trust the authors of the files in the folder. You can select “Yes, I trust the authors” to proceed. However, as future security professionals, you should exercise caution before clicking this button on code you don’t know about.

    If you’ve gotten this far, you’re done. Congratulations! You’ve successfully created a private repository from a GitHub template and cloned it inside the VM using VS Code. You can now code and manage your project code seamlessly.