I have a question related to git and security.
Assume that someone has access to your .git folder of your project.
Will he be able, in some ways, to get the source code of the project from that?
If yes, how will he do that?
I'm curious.
Thanks!
Absolutely. All they have to do is clone it:
git clone C:\Repo\.git Copy
The content of the .git
directory is the repository with all its objects, references and packfiles.
Cloning the .git
directory is no different than cloning any repository. In fact, you can create a so called bare repository and you would get the same contents that you usually see in the .git
directory:
git init --bare C:\Repo
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With