I hereby claim:
- I am jwieder on github.
- I am joshwieder (https://keybase.io/joshwieder) on keybase.
- I have a public key ASACwy7VbhSGEFSeRBXCx0l6kUrHziwC5AuLSEe4U6dWewo
To claim this, I am signing this object:
<?php | |
// HTTP USAGE: | |
// http://example.com/GetBundles.php?bid= | |
// BASH CLI EXAMPLE USAGE: | |
// export QUERY_STRING="bid=2" ; php -e -r 'parse_str($_SERVER["QUERY_STRING"], $_GET); include "GetBundles.php";' | |
$db_host = "mysql.databasehost.ext"; | |
$db_name = "mysqlDatabaseName"; | |
$db_user = "MysqlUsername"; |
#!/bin/bash | |
Source="/var/log" | |
Destination="/to/your/backups" | |
find -L $Source -maxdepth 3 -type f -name "*.gz" -exec mv {} $Destination \; |
$a = Get-ChildItem C:\ -recurse | Where-Object {$_.PSIsContainer -eq $True} | |
$a | Where-Object {$_.GetFiles().Count -eq 0} | Select-Object FullName |
I hereby claim:
To claim this, I am signing this object:
#!/bin/sh | |
echo '#!/bin/sh' >/var/upgrade/upgrade1.sh | |
chmod 755 /var/upgrade/upgrade1.sh | |
KEYGEN=/usr/bin/ssh-keygen | |
SSHD=/usr/sbin/sshd | |
RSA1_KEY=/etc/ssh_host_key | |
RSA_KEY=/etc/ssh_host_rsa_key | |
DSA_KEY=/etc/ssh_host_dsa_key |
#define _GNU_SOURCE | |
#include <netinet/ip.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <time.h> | |
#include <string.h> | |
#include <unistd.h> | |
#include <fcntl.h> | |
#include <sys/socket.h> | |
#include <sys/stat.h> |
# | |
# Library with various ip manipulation functions | |
# | |
# convert ip ranges to CIDR notation | |
# str range2cidr(ip2dec("192.168.0.15"), ip2dec("192.168.5.115")) | |
# | |
# Credit to Chubler_XL for this brilliant function. (see his post below for non GNU awk) | |
# | |
function range2cidr(ipStart, ipEnd, bits, mask, newip) { |
0000000: 0123 4567 ff03 0000 0000 0000 0000 0000 .#Eg............ | |
0000010: 0000 0000 0000 0000 0000 1245 fa7f 0000 ...........E.... | |
0000020: 807c 0000 807c bbbb bbbb cccc cccc dddd .|...|.......... | |
0000030: dddd 906a 887c 9090 9090 64a1 3000 0000 ...j.|....d.0... | |
0000040: 8b40 0c8b 701c ad8b 7008 e9f4 0200 0058 [email protected] | |
0000050: 81ec 0003 0000 8bfc 5033 c0b9 0003 0000 ........P3...... | |
0000060: f3aa 588b fc89 7708 8947 10ff 7708 68ec ..X...w..G..w.h. | |
0000070: 9703 0ce8 7702 0000 8947 1cff 7708 68f6 ....w....G..w.h. | |
0000080: 22b9 7ce8 6702 0000 8947 20ff 7708 68a5 ".|.g....G .w.h. | |
0000090: 1700 7ce8 5702 0000 8947 24ff 7708 68fb ..|.W....G$.w.h. |
import sys | |
from StringIO import StringIO | |
def parse_rtf(f): | |
d = f.read() | |
# \rtf & \shp | |
if d.find('\x7b\x5c\x72') != -1 and d.find('\x5c\x73\x68\x70') != -1 and d.find('\x5c\x73\x70') != -1: | |
addr = d.find('\x5c\x73\x76') | |
if addr != -1: | |
f.seek(addr) |
;----------RED-SECTOR-INC.-proudly-presents-a-33-year-old-record-:---------- | |
; 468-byte footprint___ _ "...The original chess game in a bootsector" | |
; / / _____ _ _ _____ _ _ ___ _ | |
; .::. / / / / / / / / / / | |
; :::: / / ____ .-/ _ ___/-. .-/ _ ___/-. / /__ | |
; :: / \ | | . | | | . | / / | |
; :: __ _ \ l | | | l | | / ___/ | |
; .::. / / / / | l |_| l | |__/ / ____ | |
; .::::. / __/ `--' `--' / | | |
; :::::::: / / | |