Skip to content

Instantly share code, notes, and snippets.

@TheFlash2k
Created January 12, 2024 01:55
Show Gist options
  • Save TheFlash2k/41b1ffa9d4781ccfc34e704c5b4ce26c to your computer and use it in GitHub Desktop.
Save TheFlash2k/41b1ffa9d4781ccfc34e704c5b4ce26c to your computer and use it in GitHub Desktop.
Generate format string patterns for fuzzy testing
#!/usr/bin/env python3
import sys
try: start = int(sys.argv[1])
except: start = 1
try: max = int(sys.argv[2])
except: max = 4
try: full = sys.argv[3]
except: full = None
payload = ""
for i in range(start,start+max):
base = "" if not full else f"{i}="
payload += f"|{base}%{i}$p"
print(payload)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment