Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Git command requires a remote named origin to operate #304

Closed
opie4624 opened this issue Apr 6, 2022 · 1 comment · Fixed by #313
Closed

Git command requires a remote named origin to operate #304

opie4624 opened this issue Apr 6, 2022 · 1 comment · Fixed by #313
Assignees
Labels

Comments

@opie4624
Copy link

opie4624 commented Apr 6, 2022

test on  main
➜ git remote -v

test on  main
➜ cd ..

~
➜ ./trufflehog git file://test
🐷🔑🐷  TruffleHog. Unearth your secrets. 🐷🔑🐷

FATA[0000] could not scan repo                           error="error getting repo remote origin: remote not found"

~
➜ cd test

test on  main
➜ git remote add bob git@example.com/bob.git

test on  main
➜ cd ..

~
➜ ./trufflehog git file://test
🐷🔑🐷  TruffleHog. Unearth your secrets. 🐷🔑🐷

FATA[0000] could not scan repo                           error="error getting repo remote origin: remote not found"

~ took 2s
➜ cd test

test on  main
➜ git remote add origin git@example.com/bob.git

test on  main
➜ cd ..

~
➜ ./trufflehog git file://test
🐷🔑🐷  TruffleHog. Unearth your secrets. 🐷🔑🐷


~ took 2s
@mcastorina
Copy link
Collaborator

Hey, good find! It looks like scanner uses the remote just for metadata so I made a PR that does a best-effort approach. It should continue scanning if there are no remotes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging a pull request may close this issue.

4 participants