This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import os | |
from functools import wraps | |
from hashlib import sha256 | |
from typing import Dict, Optional | |
from uuid import uuid4 as uuid | |
from bottle import get, post, request, response, run |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MYSQL_ROOT_PASSWORD=CHANGE_ME_PLS | |
MYSQL_PASSWORD=CHANGE_ME_PLS | |
MYSQL_USER=domjudge | |
MYSQL_DATABASE=domjudge | |
MYSQL_HOST=db | |
CONTAINER_TIMEZONE=Asia/Jakarta | |
JUDGEDAEMON_PASSWORD_FILE=/judgehost_password |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
const char nothing_here[18] = "\x00/bin/true/bin/sh"; | |
const _Bool true = 1; | |
int (*_printf)(const char*, ...) = &scanf; | |
int (*_memset)(FILE*, char*, int, size_t) = &setvbuf; | |
int (*_scanf)(const char*) = &puts; | |
int (*_strlen)(const char*) = &system; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
from flask import Flask | |
from flask import request, Response, render_template, send_from_directory, send_file, session | |
import os | |
import tarfile, io | |
import json | |
import random | |
from string import digits, ascii_letters | |
app = Flask(__name__) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# pwndbg scripting | |
gdb.execute('b* 0x555555554982') # call rdx | |
gdb.execute('r < input') | |
gdb.execute('s') # step into call | |
flag = [] | |
while True: | |
instr = pwndbg.disasm.one() # get current instruction | |
# instr is a part of capstone object, https://www.capstone-engine.org/lang_python.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
get_system_call: | |
mov ecx, 0xc0000082 | |
rdmsr ; eax = low, edx = high | |
sal rdx, 32 | |
cdqe | |
or rax, rdx ; rax = guess | |
.loop_init: | |
mov rcx, rax | |
add rcx, 500 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Copyright © 2015 Serpent7776. All Rights Reserved. | |
# Redistribution and use in source and binary forms, with or without | |
# modification, are permitted provided that the following conditions are met: | |
# 1. Redistributions of source code must retain the above copyright | |
# notice, this list of conditions and the following disclaimer. | |
# 2. Redistributions in binary form must reproduce the above copyright | |
# notice, this list of conditions and the following disclaimer in the |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source ~/git/pwndbg/gdbinit.py | |
#source ~/git/peda/peda.py | |
set context-code-lines 7 | |
set dereference-limit 3 | |
set context-source-code-lines 5 | |
set context-stack-lines 5 | |
set context-sections regs disasm code stack expressions | |
add-auto-load-safe-path /home/kyra/ctf/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ $# -ne 1 ]; then | |
echo -e "$0 - get last gists from a user" | |
echo -e "Usage:" | |
echo -e "\t$0 <username>\n" | |
echo -e "Example:" | |
echo -e "\t$0 circleous" | |
else | |
url=`curl -s https://api.github.com/users/$1/gists | grep url | head -n 1 | awk '{print $2}' | sed 's/"\(.*\)",/\1/'` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://github.com/ray-cp/pwn_debug/blob/master/build.sh | |
#!/bin/sh | |
# echo "install some deps" | |
# sudo apt-get install gawk -y | |
# sudo apt-get install bison -y | |
# sudo apt-get install gcc-multilib -y | |
# sudo apt-get install g++-multilib -y |
NewerOlder