Skip to content

Instantly share code, notes, and snippets.

View notxarb's full-sized avatar

Braxton Huggins notxarb

View GitHub Profile
#include <sys/types.h>
#include <sys/socket.h>
#include <netdb.h>
#include <stdio.h>
#include <string.h>
int main(int argc, char *argv[]) {
const char *hostname = argv[1];
const char *service = argv[2];
@notxarb
notxarb / iptables
Last active December 10, 2015 14:09 — forked from anonymous/gist:4445900
iptables
iptables -P INPUT ACCEPT
iptables -F INPUT
iptables -F FORWARD
iptables -F OUTPUT
iptables -A INPUT -i lo -j ACCEPT
iptables -A INPUT -i eth0 -j ACCEPT
iptables -A INPUT -s 24.116.177.208/29 -i eth1 -p tcp -m tcp --dport 22 -j ACCEPT
iptables -A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A INPUT -p icmp -j ACCEPT
iptables -P INPUT DROP
@notxarb
notxarb / gist:3835922
Created October 4, 2012 19:43
pears are my least favorite fuit
1. Installation base ($prefix) : /usr/bin/php-5.2.17
2. Temporary directory for processing : /tmp/pear/install/5.2.17
3. Temporary directory for downloads : /tmp/pear/install/5.2.17
4. Binaries directory : /usr/bin/php-5.2.17
5. PHP code directory ($php_dir) : /usr/share/pear/php-5.2.17
6. Documentation directory : /usr/docs/php-5.2.17
7. Data directory : /usr/data/php-5.2.17
8. User-modifiable configuration files directory : /etc/php-5.2.17
9. Public Web Files directory : /var/www
10. Tests directory : /usr/tests/php-5.2.17