Skip to content

Instantly share code, notes, and snippets.

@Bigjango13
Created October 14, 2025 05:28
Show Gist options
  • Select an option

  • Save Bigjango13/0144d08f85a6a4857a7d2a2bd483f61a to your computer and use it in GitHub Desktop.

Select an option

Save Bigjango13/0144d08f85a6a4857a7d2a2bd483f61a to your computer and use it in GitHub Desktop.
import os
cmd = '''
curl 'https://api.uscyberpatriot.org/api/Competitor?userName={EMAIL}&token={TOKEN}' \
-H 'sec-ch-ua-platform: "Linux"' \
-H 'Referer: https://volunteer.uscyberpatriot.org/' \
-H 'sec-ch-ua: "Google Chrome";v="131", "Chromium";v="131", "Not_A Brand";v="24"' \
-H 'sec-ch-ua-mobile: ?0' \
-H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36' \
-H 'Accept: application/json, text/plain, */*' \
-H 'DNT: 1' \
-H 'Content-Type: application/json;charset=UTF-8' \
--data-raw '{"WFAction":"ADD_COMPETITOR","ID":"","VolunteerUserName":"{CEMAIL}","TeamNumber":"{TEAMNUM}","Status":"No","FirstName":"{FNAME}","LastName":"{LNAME}","Email":"{PEMAIL}","ParentConsent":true,"TShirtSize":"{TSIZE}","ageCertification":"Yes"}' \
2>/dev/null 1>&2
'''
tsizes = {
'S/XS': 'Small',
'S': 'Small',
'M': 'Medium',
'L': 'Large',
'2XL': '2X-Large',
'3XL': '3X-Large',
}
email = input('email> ').strip()
print("To get your token, go to the dashboard and run 'javascript:alert(document.cookie.match(new RegExp('(^| )SecurityToken=([^;]+)'))[2])' (note: chrome will remove the 'javascript: part if you paste it in, be sure to add it before you hit enter')");
token = input('token> ').strip()
team = input('team> ').strip()
cmd = cmd.replace('{EMAIL}', email).replace('{CEMAIL}', email).replace('{TOKEN}', token).replace('{TEAMNUM}', team)
while True:
dat = input(f'{team}> ').strip().split()
fname = dat[0];
lname = dat[1]
pemail = dat[2]
tsize = tsizes[dat[3]]
input(f'first name: "{fname}", last name: "{lname}", email: "{pemail}", t-shirt size: "{tsize}"?').strip().lower()
ncmd = cmd.replace("{FNAME}", fname).replace("{LNAME}", lname.replace("'", '%27')).replace("{PEMAIL}", pemail).replace("{TSIZE}", tsize)
os.system(ncmd)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment