GithubHelp home page GithubHelp logo

bbhunter / gitlab-unauth-parser Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ldionmarcil/gitlab-unauth-parser

0.0 0.0 0.0 33 KB

Parses unauthenticated Gitlab APIs for users, repos, groups and secrets.

License: GNU General Public License v3.0

Python 100.00%

gitlab-unauth-parser's Introduction

gitlab-unauth-parser

Parses interesting Gitlab v4 unauthenticated APIs to extract useful information such as:

  • Public Repositories
  • Users
  • Groups

Usage

$ poetry run python -m gitlab_unauth_parser -h
usage: gitlab_unauth_parser.py [-h] [-u URL] [-f] [-c CLONE] [-w WRITE]

optional arguments:
  -h, --help            show this help message and exit
  -u URL, --url URL     URL containing the Gitlab instance
  -f, --fingerprint     Don't try to detect valid Gitlab instance
  -c CLONE, --clone CLONE
                        Repository to clone projects to. Will not clone if unspecified
  -w WRITE, --write WRITE
                        Write output to file (repos.txt, groups.txt, users.txt)

Example: $ poetry run python -m gitlab_unauth_parser -u https://gitlab.gnome.org/ -c /tmp/foobar

Purpose

Repositories

Unbeknownst to many Gitlab administrators, "public" repositories do not mean "public to the organization". They mean public to all, even if the Gitlab instance has no public registration. Using the Gitlab API, it is possible to find these repositories and then clone them.

Users

The Gitlab user API starts at user ID 1 and is incremented by 1 for each user. With this knowledge, this script starts at the begining and requests user IDs until 20 subsequent user IDs are not found, indicating that the last user has likely been found. Using this, we can extract the list of users of some Gitlab instances without authentication.

Groups

Groups can help understand the kind of data this Gitlab instance is responsible for hosting.

For more information on the visibility of users, consult the Gitlab documentation: https://gitlab.com/gitlab-org/gitlab-foss/-/blob/master/doc/public_access/public_access.md#visibility-of-users

Installation

git clone https://github.com/ldionmarcil/gitlab-unauth-parser/
cd gitlab-unauth-parser
poetry install

Once done, you can run $ poetry run python -m gitlab_unauth_parser -h

gitlab-unauth-parser's People

Contributors

ldionmarcil avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.