> For the complete documentation index, see [llms.txt](https://blog.s1rn3tz.ovh/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://blog.s1rn3tz.ovh/pentest-web/.git-expose.md).

# .git exposé

## Extension

### DotGit

DotGit est une extension chrome et firefox recherchant pour chaque page visité la présence d'un fichier ".git" exposé.

ressource: <https://github.com/davtur19/DotGit>

### Dork

`“index of” inurl:.git`

`intitle:"index of" .git/hooks/`

## Téléchargement

*`$ wget --mirror -I https://target.com/.git/`*

## Analyse

### Status

*`$ git status`*

### Récupération des fichiers supprimés

*`$ git restore .`*

ou

*`$ git checkout -- .`*

### Logs

*`$ git log`*

### Lecture des commits

*`$ git show <commit id>`*

## Analyse de code

{% content-ref url="/pages/QqIBc7LpI1uUawCOI9gj" %}
[Analyse statique](/pentest-web/analyse-statique.md)
{% endcontent-ref %}
