Skip to content

Instantly share code, notes, and snippets.

View domenukk's full-sized avatar
🦥

Dominik Maier domenukk

🦥
View GitHub Profile
@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 / 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 / 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 () {