Skip to content

Instantly share code, notes, and snippets.

View fogti's full-sized avatar

Ellen Emilia Anna Zscheile fogti

View GitHub Profile
@fogti
fogti / GoogleCTF2021-memsafety.rs
Created July 19, 2021 12:31
A pathetic solve of the memsafety challenge of Google CTF 2021 (TEAM0001)
use prelude::{Service, Box};
pub struct State;
impl State {
pub fn new() -> Box<dyn Service> {
Box::new(Self)
}
}
impl Service for State {
@fogti
fogti / pxlf-client-Cargo.toml
Created December 27, 2020 22:55
a simple pixelflut client, draws circles...
[package]
name = "pxlf-client"
version = "0.1.0"
authors = ["Erik Zscheile <[email protected]>"]
edition = "2018"
[dependencies]
fastrand = "1.4"
crossbeam-channel = "0.5"
@fogti
fogti / add_distfile.py
Created September 9, 2020 01:57
insert a distfile into a "filename-hash BLAKE2B 8" distfile tree
#!/usr/bin/python3
import filecmp
import hashlib
import os
import shutil
import sys
args = sys.argv[1:]
@fogti
fogti / yzesd-stresstest.sh
Created June 5, 2020 01:41
a simple yz-encsess2 stress test
#!/bin/bash
export RUST_LOG=debug
# source repo @ https://github.com/YZITE/encsess2
# git clone https://github.com/YZITE/encsess2
# cd encsess2
# cargo build --release
YZESD2PATH=... # should point at the path where the release binaries reside
echo "spawn server ..."
@fogti
fogti / ZSXPL.txt
Last active June 16, 2019 16:24
Zscheile Extensible Programming Language
ZSXPL -- Zscheile Extensible Programming Language
Types:
ptr shared_ptr<obj> 0x00
int int64_t 0x01
uint uint64_t 0x02
double double 0x03
stream int32_t(_fd) 0x04
string string 0x10
@fogti
fogti / zsdatab_01.cxx
Last active March 3, 2020 22:23
SQL repr in zsdatab API
#include <zsdatable.hpp>
#include <iostream>
int main() {
zsdatab::metadata mt(':');
mt += { "k", "w", "v" };
zsdatab::table tab(mt);
// insert something into table
///...
@fogti
fogti / inject.sh
Last active March 3, 2020 22:25
inject a shell script into another host and execute it (using dbclient)
DBCLIENT="$(which dbclient)"
[ -z "$INJECT_USERNAME" ] && INJECT_USERNAME="root"
[ -z "$INJECT_PASSWORD" ] && INJECT_PASSWORD="1q2w3e"
doremote() {
DROPBEAR_PASSWORD="$INJECT_PASSWORD" "$DBCLIENT" -y -y -A -l "$INJECT_USERNAME" "$INJECT_HOST" "$@"
}
inject_progr() {