Skip to content

Instantly share code, notes, and snippets.

View domenukk's full-sized avatar
🦥

Dominik Maier domenukk

🦥
View GitHub Profile
@domenukk
domenukk / scansubnet.js
Last active July 27, 2017 16:01
Scan the surrounding subnet for http hosts using iframes and timeouts.
var subnet = "http://192.168.178."
var timeout = 4000;
var TIMEOUT = "timeout";
var ERROR = "error";
var LOADED = "loaded";
function request(url, wait) {
return new Promise((resolve, reject) => {
setTimeout(function () {
@domenukk
domenukk / py
Created January 3, 2019 20:19
Calling Foreground Functions from Background Processes in Python
#!/bin/env python
"""
A simple example calling any functon in the foreground from background threads, including a response, using Queues.
"""
from multiprocessing import Queue, Process, cpu_count
from collections import namedtuple
import traceback
Event = namedtuple("Event", "thread_id function args kwargs")
@domenukk
domenukk / funsafe.sh
Last active August 21, 2023 03:14
Funsafe Rust Jail (for HackIM CTF 2023)
#!/bin/bash
echo "Your code please."
FOLDER=$(mktemp -d)
cp flag.txt "$FOLDER"
cd "$FOLDER"
mkdir src
cat <<EOF > Cargo.toml
[package]
name = "funsafe"
@domenukk
domenukk / bin2elf.sh
Last active September 28, 2024 00:46 — forked from ssvb/bin2elf.sh
Convert a memory dump/raw binary image into an ELF file
#!/bin/sh
# Convert a raw binary image into an ELF file suitable for loading into a disassembler
#
# Usage: bin2elf input_binary_file output_elf_file base_address
cat > raw$$.ld <<EOF
SECTIONS
{
EOF