Comments (2)
好主意!
from githacker.
Done, @shashade250 , thanks for your brilliant idea!
This feature will be released in v1.1.4.
Experiment Setup
$ mkdir repo
$ cd repo
$ git init
$ echo 'master' > README.md
$ git add --all
$ git commit -m "init commit in master branch"
$ git checkout -b private_branch
$ echo 'private_branch' >> README.md
$ git add --all
$ git commit -m "second commit in private branch"
$ git status
On branch private_branch
nothing to commit, working tree clean
$ python3 -m http.server
Test Results
Old version (v1.1.3)
$ githacker --version
1.1.3
$ githacker --url "http://127.0.0.1:8000/" --output-folder v1.1.3
2022-07-27 21:08:34 INFO 1 urls to be exploited
2022-07-27 21:08:34 INFO Exploiting http://127.0.0.1:8000/ into v1.1.3/17abf5259517d604cc9599a00b7385d6
2022-07-27 21:08:34 INFO Downloading basic files...
2022-07-27 21:08:34 INFO [73 bytes] 200 .git/description
2022-07-27 21:08:34 INFO [32 bytes] 200 .git/COMMIT_EDITMSG
...
2022-07-27 21:08:34 INFO [22 bytes] 200 .git/objects/1f/7391f92b6a3792204e07e99f71f643cc35e7e1
2022-07-27 21:08:34 INFO [22 bytes] 200 .git/objects/1f/7391f92b6a3792204e07e99f71f643cc35e7e1
2022-07-27 21:08:34 INFO Cloning downloaded repo from /tmp/tmpe8tp_0j9 to v1.1.3/17abf5259517d604cc9599a00b7385d6
2022-07-27 21:08:34 ERROR Cloning into 'v1.1.3/17abf5259517d604cc9599a00b7385d6'...
done.
warning: remote HEAD refers to nonexistent ref, unable to checkout.
2022-07-27 21:08:34 INFO Check it out: v1.1.3/17abf5259517d604cc9599a00b7385d6
2022-07-27 21:08:34 INFO 1 / 1 were exploited successfully
2022-07-27 21:08:34 INFO http://127.0.0.1:8000/ -> v1.1.3/17abf5259517d604cc9599a00b7385d6
$ cd v1.1.3/17abf5259517d604cc9599a00b7385d6
$ git status
On branch master
No commits yet
nothing to commit (create/copy files and use "git add" to track)
As the above log goes, a warning appears. And the current repo branch is master
, but private_branch
is expected.
warning: remote HEAD refers to nonexistent ref, unable to checkout.
New version (v1.1.4)
$ githacker --version
1.1.4
$ githacker --url "http://127.0.0.1:8000/" --output-folder v1.1.4
2022-07-27 21:13:52 INFO 1 urls to be exploited
2022-07-27 21:13:52 INFO Exploiting http://127.0.0.1:8000/ into v1.1.4/17abf5259517d604cc9599a00b7385d6
2022-07-27 21:13:52 INFO Downloading basic files...
2022-07-27 21:13:52 INFO [73 bytes] 200 .git/description
2022-07-27 21:13:52 ERROR [469 bytes] 404 .git/FETCH_HEAD
...
2022-07-27 21:13:53 INFO [22 bytes] 200 .git/objects/1f/7391f92b6a3792204e07e99f71f643cc35e7e1
2022-07-27 21:13:53 INFO [22 bytes] 200 .git/objects/1f/7391f92b6a3792204e07e99f71f643cc35e7e1
2022-07-27 21:13:53 INFO Cloning downloaded repo from /tmp/tmppr2gv75n to v1.1.4/17abf5259517d604cc9599a00b7385d6
2022-07-27 21:13:53 ERROR Cloning into 'v1.1.4/17abf5259517d604cc9599a00b7385d6'...
done.
2022-07-27 21:13:53 INFO Check it out: v1.1.4/17abf5259517d604cc9599a00b7385d6
2022-07-27 21:13:53 INFO 1 / 1 were exploited successfully
2022-07-27 21:13:53 INFO http://127.0.0.1:8000/ -> v1.1.4/17abf5259517d604cc9599a00b7385d6
$ cd v1.1.4/17abf5259517d604cc9599a00b7385d6
$ git status
On branch private_branch
Your branch is up to date with 'origin/private_branch'.
nothing to commit, working tree clean
No warning, no errors. The current branch name is private_branch
as expected.
from githacker.
Related Issues (20)
- 未找到命令 HOT 8
- 如何在 docker 中找回进程 HOT 11
- Support git pack file HOT 1
- UnicodeDecodeError: 'utf-8' codec can't decode HOT 5
- Disable SSLCertVerification? HOT 7
- python: can't open file 'GitHacker.py': [Errno 2] No such file or directory HOT 2
- 在win10中无法在创建文件夹 HOT 2
- Support exploiting multiple urls HOT 1
- Vulnerabilities reported by Justin Steven
- git log not compelete in master branch HOT 2
- git log -relog 版本不全 HOT 6
- Infinit downloading 404 files (Deny of Service) HOT 2
- Why does not work? HOT 8
- IsADirectoryError: [Errno 21] Is a directory: '/tmp/tmpqouh7cck/.git/objects/pack' HOT 2
- AssertionError: Invalid index file header: b'cons' HOT 2
- Git-dumper and dvcs-ripper appears twice on readme HOT 4
- more ERROR ERROR FileExistsError(17, 'File exists')
- Cannot see the result
- error after success message HOT 12
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from githacker.