Skip to content

Instantly share code, notes, and snippets.

View ethicalanuj's full-sized avatar
🎯
Focusing

Anuj ethicalanuj

🎯
Focusing
View GitHub Profile

GitHub Search Syntax for Finding API Keys/Secrets/Tokens

As a security professional, it is important to conduct a thorough reconnaissance. With the increasing use of APIs nowadays, it has become paramount to keep access tokens and other API-related secrets secure in order to prevent leaks. However, despite technological advances, human error remains a factor, and many developers still unknowingly hardcode their API secrets into source code and commit them to public repositories. GitHub, being a widely popular platform for public code repositories, may inadvertently host such leaked secrets. To help identify these vulnerabilities, I have created a comprehensive search list using powerful search syntax that enables the search of thousands of leaked keys and secrets in a single search.

Search Syntax:

(path:*.{File_extension1} OR path:*.{File_extension-N}) AND ({Keyname1} OR {Keyname-N}) AND (({Signature/pattern1} OR {Signature/pattern-N}) AND ({PlatformTag1} OR {PlatformTag-N}))

Examples:

**1.

@ethicalanuj
ethicalanuj / wordlistfinder.py
Created July 8, 2024 20:26 — forked from nullenc0de/wordlistfinder.py
Find Best Wordlist
import os
def find_best_wordlists(user_word, max_wordlists):
wordlists_dir = '/opt/OneListForAll/dict'
wordlists = os.listdir(wordlists_dir)
matched_wordlists = []
for wordlist in wordlists:
if user_word.lower() in wordlist.lower():
@ethicalanuj
ethicalanuj / content_discovery_all.txt
Created June 17, 2024 17:14 — forked from jhaddix/content_discovery_all.txt
a masterlist of content discovery URLs and files (used most commonly with gobuster)
This file has been truncated, but you can view the full file.
`
~/
~
ים
___
__
_
@ethicalanuj
ethicalanuj / all.txt
Created June 10, 2024 11:41 — forked from jhaddix/all.txt
all wordlists from every dns enumeration tool... ever. Please excuse the lewd entries =/
This file has been truncated, but you can view the full file.
.
..
........
@
*
*.*
*.*.*
🐎