Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

set shiftwidth=8
set softtabstop=8
set tabstop=8
autocmd Filetype c setlocal foldmethod=syntax ts=4 sw=4 sts=4 expandtab
autocmd Filetype cpp setlocal foldmethod=syntax ts=4 sw=4 sts=4 expandtab
au FileType python setl sw=4 sts=4 et
autocmd FileType make set noexpandtab
package uscrime;
//Filename:TestUsCrime
//Author: Cody M Rinehart
//Date: 25032017
/*Purpose: The purpose of this program is to create the menu and read the user's
input to determine what data will be printed out to the user*/
import java.util.Scanner;
import java.io.IOException;
#!/usr/bin/env python3
from os import system
import curses
x = 0
def main(x):
while x != ord('4'):
screen = curses.initscr()
@jabedude
jabedude / winlogfinder
Created April 20, 2016 14:09
run from meterpereter. finds logs from last 2 minutes
run uploadexec -e "/root/wintools/psloglist.exe" -o "/accepteula -m 2" -r -v
run uploadexec -e "/root/wintools/psloglist.exe" -o "/accepteula -m 2 SECURITY" -r -v
run uploadexec -e "/root/wintools/psloglist.exe" -o "/accepteula -m 2 APPLICATION" -r -v
# $Id$
# $Revision$
# -*- coding: binary -*-
require 'fileutils'
@client = client
host,port = @client.session_host, @client.session_port
key = nil
path = nil
open_key = false
name = nil
@jabedude
jabedude / nix_survey.sh
Last active April 15, 2016 14:36
not completely real nix survey
#!bin/bash
date
ls -la /
ls -la /etc
ls -la /sbin
ls -la /usr
ls -la /usr/bin
ls -la /usr/sbin
ls -la /etc/rc2.d
@jabedude
jabedude / portredirect.sh
Created April 7, 2016 20:02
nix port redirection
#!/bin/bash
mkfifo mypipe
nc -l 8885 0<mypipe | nc -p 42 10.80.32.1 111 1>mypipe
@jabedude
jabedude / flush.sh
Created April 6, 2016 19:02
flushes iptables rules
#!/bin/sh
echo "Stopping firewall and allowing everyone..."
iptables -P INPUT ACCEPT
iptables -P FORWARD ACCEPT
iptables -P OUTPUT ACCEPT
iptables -F
iptables -X
iptables -t nat -F
iptables -t nat -X
iptables -t mangle -F
#include <stdio.h>
#include <fcntl.h>
#include <sys/types.h>
#include <dirent.h>
#include <sys/stat.h>
#include <time.h>
int main(int argc, char* argv[])
{
if (argc < 2)
@jabedude
jabedude / contact.sh
Created March 25, 2016 14:20
solaris host up/down
#!/bin/bash
[ $# -lt 1 ] && echo too few args && exit 1
while test "$1"; do
if [[ `ping "$1" 2` == "$1 is alive" ]]
then
echo $1 is alive
else
echo $1 is down
fi
shift