Skip to content

Instantly share code, notes, and snippets.

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.

@raisabelatrix
raisabelatrix / rainbow-tags.css
Last active March 4, 2025 09:54
Obsidian 1.0+ snippet for rainbow-colored tags. Comes with style settings option
/* ——————————————————————————————————————————— ╗
                 STYLE SETTINGS
╚ ——————————————————————————————————————————— */
/* @settings
name: Rainbow Tags by raisabelatrix
id: rb-tags-rsbltrx
settings:
-
id: rainbow-tags
@mandiwise
mandiwise / Count lines in Git repo
Last active March 4, 2025 09:54
A command to calculate lines of code in all tracked files in a Git repo
// Reference: http://stackoverflow.com/questions/4822471/count-number-of-lines-in-a-git-repository
$ git ls-files | xargs wc -l
@kione
kione / image-build.sh
Created November 15, 2021 22:34 — forked from HackingGate/image-build.sh
upgrade ipk on OpenWrt
VERSION=19.07.7
# Download imagebuilder for R7800.
aria2c -c -x4 -s4 https://downloads.openwrt.org/releases/${VERSION}/targets/ipq806x/generic/openwrt-imagebuilder-${VERSION}-ipq806x-generic.Linux-x86_64.tar.xz
# Extract & remove used file & cd to the directory
tar -xvf openwrt-imagebuilder-${VERSION}-ipq806x-generic.Linux-x86_64.tar.xz
rm openwrt-imagebuilder-${VERSION}-ipq806x-generic.Linux-x86_64.tar.xz
cd openwrt-imagebuilder-${VERSION}-ipq806x-generic.Linux-x86_64/

How to setup Vortex Race 3 (firmware v1.02.05) for Mac OS

The Vortex Race 3 is a great mechanical keyboard, but using it with MacOS requires some adjustments. We need to reposition and reprogram the modifier keys. Unfortunately the Race 3 does not support the online MPC, so we will have to do this using the on-board programming mode.

This guide is heavily based on a gist by arogulin. It only adds a bit of formatting and a few minor notes.

For better understanding we will use the following naming convention for the key positions: L1L2L3SpaceR1R2R3

  1. Reset everything. Press L3+R1 for 5 seconds. Release the keys when the white led stops blinking.
  2. Choose a progammable layer (and led color) by pressing R2+RShift several times. I chose red (layer 1).
@antonbabenko
antonbabenko / amz_content_sha256.js
Created November 19, 2024 16:11
Lambda@Edge (origin-request) for CloudFront OAC with Lambda Function URL integration for POST/PUT
'use strict';
const crypto = require('crypto');
exports.handler = (event, context, callback) => {
const request = event.Records[0].cf.request;
const headers = request.headers;
const method = request.method;
const body = Buffer.from(request.body.data, 'base64').toString();
@FabulousCupcake
FabulousCupcake / windows-bluetooth-autoconnect.md
Created August 27, 2021 18:49
Actually Disabling Bluetooth Autoconnect on Startup in Windows

Actually Disabling Bluetooth Autoconnect on Startup in Windows

Situation

I use multiple devices with my bluetooth earphone connected to my mac machine, phone, or tablet.
When I boot my windows machine, it automatically connects to and snatches my bluetooth earphone. This is very annoying.

Results from google on ways to disable this are unhelpful:

  • Unpair the device (???)
  • Disable bluetooth support system service via services.msc
  • Disable the device via Device Manager
@carafelix
carafelix / README.md
Last active March 4, 2025 09:50
All default VS code file.associations

Pulled from VS Code official repository which itself pulls from Seti UI repository. It's possible to manually edit the vs-seti-icon-theme.json file located in $VSCODE_PATH/resources/app/extensions/theme-seti/icons/vs-seti-icon-theme.json. WithVSCODE_PATH being the installation folder. In Linux defaults to /usr/share/code/

Anytime you wonder which and where were all the file.associations for customizing the file extension icons in VS Code? Well here they are.

Your settings.json would look the following example (first one being place holders and the second one being a working icon file association)

"files.associations": {
        "REGEX_PATTERN": "FILE.ASSOCIATION",
        "*.xcu": "xml"
@devnoname120
devnoname120 / My macOS setup.md
Last active March 4, 2025 09:49
My macOS setup

ℹ️ Enable iCloud end-to-end encryption:

  • Nobody knows that, but iCloud actually supports end-to-end encryption (see “Advanced Data Protection for iCloud”) but it's disabled by default. If you care about data privacy, you should turn it on.
    • System settingsApple IDiCloud → Set Advanced Data Protection to On.
    • System settingsApple IDiCloud → Disable Access iCloud Data on the Web.
  • It supports almost all the native Apple apps, with the notable exceptions of iCloud Mail, Contacts, and Calendars. See official data protection matrix for more info.

Table of Contents

import pygame
import math
# Initialize Pygame
pygame.init()
# Constants
WIDTH, HEIGHT = 512, 512
TILE_SIZE = 16
FPS = 30