Skip to content

Instantly share code, notes, and snippets.

View jquast's full-sized avatar
🐡
I may be slow to respond.

Jeff Quast jquast

🐡
I may be slow to respond.
View GitHub Profile
@jquast
jquast / dxpaint.bas
Created November 9, 2012 00:09
Dingo's Pixel Painter! (QuickBasic)
PRINT "loading dingo's pixel painter - dingo@efnet"
PRINT ".";
DIM ERRCODE(0 TO 76) AS STRING
ERRCODE(1) = "NEXT without FOR"
ERRCODE(2) = "Syntax error"
ERRCODE(3) = "RETURN without GOSUB"
ERRCODE(4) = "Out of DATA"
ERRCODE(5) = "Illegal function call"
ERRCODE(6) = "Overflow"
ERRCODE(7) = "Out of memory"
@jquast
jquast / mystic-udump.c
Created November 9, 2012 00:16
mystic linux user file record parser
/*
I'm not sure what the age of the original file is, CVS commit log says,
c files from usb disk
date 2005.07.20.16.43.00; author dingo; state Exp;
12days.c ansirama.c bitwise.c bitwise2.c dcom.c hexrand.c
hideps.c inetdserv.c ipmask.c macchanger-linux.c
macchanger-openbsd.c mkaddr.c mysed.c network.c redbox.c
ruser.c sea.c strstr.c timediff.c tmp.c tun.c vprintf.c
@jquast
jquast / ansirama.c
Created November 9, 2012 00:42
some silly C ansimation
#include <stdio.h>
#include <math.h>
/* modify speed if it runs too fast */
#define SPEED 20
#define FLAKES 128
#define FLIES 15
#define COLUMNS 80
#define ROWS 25
#define CENTER_X 40
@jquast
jquast / cm11aclock.c
Created November 9, 2012 00:44
CM11a timeclock struct test
#include <stdio.h>
#include <time.h>
struct cm11_setclock {
char cmd; /* 0x9b */
char seconds; /* 0-60 */
char minutes; /* 0-119 */
char hours; /* 0-11 (hours/2) */
char yearday; /* really 9 bits */
char weekday; /* really 7 bits */
@jquast
jquast / usrbak.sh
Created November 11, 2012 09:16
from school ?
#!/usr/local/bin/bash
# Jeff Quast, dingo@1984.ws
# 4/9/05
passwd_file=/etc/master.passwd
passwd_tmp=/etc/ptmp
group_file=/etc/group
new_group_file=$group_file.new
mail_dir=/var/mail
crontab_dir=/var/cron/tabs
arjob_dir=/var/at/jobs
@jquast
jquast / wmiscan.py
Created November 11, 2012 09:51
win32 wmi scanner
# Jeff Quast
# 11/10/05
#
# Program Purpose:
#
# Scan for machines on domain, and build a database
# of machines. Populate database with WMI data retrieved
# from host through parallel scanning. Dump successful
# retrievals to comma-delimited file for 3rd party import.
domain = 'zzz'
@jquast
jquast / win32lotusgui.py
Last active October 12, 2015 16:27
win32 lotus notes gui for views
import wx
import lotus
mypass = 'xxxxxxxxxx'
lotus.session.Initialize(mypass)
# from 2005 ... no guarantees here ..
def repstring(str, replace, wth='_'):
newstr = ''
#!/bin/ksh
# jeff@quast.co.uk
nawk -v scale=$1 -v precision=$2 '
BEGIN {
# f_bytes and b_bytes, forwards and backwards for up and down-scaling
f_bytes="B K M G T P E Z"
b_bytes="Z E P T G M K B"
usage=0 # flipped on error condition, exit with usage
if ((scale == "-h") || (scale == "--help"))
@jquast
jquast / ncurses_pong.php
Created November 14, 2012 02:31
ncurses pong in php, -jbrenner
#! /usr/bin/env php
# $Id: pong.phps,v 1.2 2006/01/28 14:45:22 dingo Exp $
# imported via lynx -dump 2006 jdq, orig by theedge@efnet
<?php
/*
Jeremy Brenner 2005
*/
ncurses_init();
ncurses_timeout(0);
ncurses_cbreak();
@jquast
jquast / ansi-codes.php
Created November 14, 2012 02:42
ansi-codes.php ansi.php
<?php
// -rwxr--r-- 0 jeremy users 1982 Feb 12 2003 ansi-codes.php
// -rwxr--r-- 0 jeremy users 1166 Feb 13 2003 ansi.php
function ansi_decode($ansicodes){
$fontline="<font ";
$ansi=explode(";",$ansicodes[0]);
$attrib=0;
for($code=0;$code<count($ansi);$code++){
switch ($ansi[$code]) {
case 0: