Skip to content

Instantly share code, notes, and snippets.

versionsix

Block or report user

Report or block versionsix

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View edgemax export config
show configuration commands >/config/user-data/erl-commands.txt
View PHP_SHOW_IP
<?php
if (getenv('HTTP_CLIENT_IP'))
echo "HTTP_CLIENT_IP: " . getenv('HTTP_CLIENT_IP') . "<br />";
if(getenv('HTTP_X_FORWARDED_FOR'))
echo "HTTP_X_FORWARDED_FOR: " . getenv('HTTP_X_FORWARDED_FOR') . "<br />";
if(getenv('HTTP_X_FORWARDED'))
echo "HTTP_X_FORWARDED: " . getenv('HTTP_X_FORWARDED') . "<br />";
if(getenv('HTTP_FORWARDED_FOR'))
echo "HTTP_FORWARDED_FOR: " . getenv('HTTP_FORWARDED_FOR') . "<br />";
if(getenv('HTTP_FORWARDED'))
View install apacha php7 ubuntu.debian
sudo apt-get update
sudo apt-get install -y apache2 php7.0 libapache2-mod-php7.0 php7.0-mysql php7.0-curl php7.0-json
View Schema_Tor_Exit_Nodes.skema
[{"name":"tor_exit_ipv4","color":"Grey","position":{"x":101,"y":100},"increment":false,"timestamp":false,"softdelete":false,"column":[{"name":"id","type":"increments","length":"","defaultvalue":"","enumvalue":"","ai":false,"pk":false,"nu":false,"ui":false,"in":false,"un":false,"fillable":false,"guarded":false,"visible":false,"hidden":false,"colid":"c42","order":0},{"name":"ip_address","type":"string","length":"16","defaultvalue":"","enumvalue":"","ai":false,"pk":false,"nu":false,"ui":false,"in":false,"un":false,"fillable":false,"guarded":false,"visible":false,"hidden":false,"colid":"c50","order":1},{"name":"timestamp_1","type":"datetime","length":"","defaultvalue":"","enumvalue":"","ai":false,"pk":false,"nu":false,"ui":false,"in":false,"un":false,"fillable":false,"guarded":false,"visible":false,"hidden":false,"colid":"c68","order":2},{"name":"timestamp_2","type":"datetime","length":"","defaultvalue":"","enumvalue":"","ai":false,"pk":false,"nu":false,"ui":false,"in":false,"un":false,"fillable":false,"guarded":
View Test_Tor_consensuses
@type network-status-consensus-3 r 1.0
network-status-version 3
vote-status consensus
consensus-method 25
valid-after 2017-03-09 14:00:00
fresh-until 2017-03-09 15:00:00
valid-until 2017-03-09 17:00:00
foo
r seele AAoQ1DAR6kkoo19hBAX5K0QztNw Is6WVULfiBd5brywe2ptl1ZBDJU 2017-03-08 21:11:07 67.164.109.21 9001 0
s Running Stable V2Dir Valid
@versionsix
versionsix / cymru-lookup.php
Created Apr 22, 2017 — forked from leprechau/cymru-lookup.php
testing the cymru netcat access
View cymru-lookup.php
<?php
/* test host list */
$hostlist = array(
'96.4.1.22',
'207.191.191.90',
'8.8.8.8'
);
/* do the lookup */
View Ubuntu 16.04 PHP+Apache+Postgres9.5
#!/bin/bash
# setup LAPP server with
# pg admin postgres | postgrespw
# try with `export PGPASSWORD='postgrespw'; psql -h <serverip> -U postgres`
export DEBIAN_FRONTEND=noninteractive
export DEBIAN_PRIORITY=critical
sudo -E apt-get -qy update
sudo -E apt-get -qy -o "Dpkg::Options::=--force-confdef" -o "Dpkg::Options::=--force-confold" upgrade
sudo -E apt-get -qy autoclean
@versionsix
versionsix / parse.sh
Last active May 31, 2018
Azure BASH parse connection string example
View parse.sh
#!/bin/bash
declare -x MYSQLCONNSTR_MS_Mysql="Database=mydevwiki; Data Source=mw-mysql; User Id=root; Password=mysecretpassword"
declare -A mysqlconn
# Strip spaces, then convert semicolon to spaces to loop in array
# We must strip spaces since this is inconsistent used inside azure
for keyvaluepair in $(echo $MYSQLCONNSTR_MS_Mysql | sed "s/ //g; s/;/ /g")
do
ARR=(${keyvaluepair//=/ })
mysqlconn[${ARR[0]}]=${ARR[1]}
@versionsix
versionsix / out.rsc
Created Jun 3, 2018
Mikrotik ipv6 default firewall
View out.rsc
/ipv6 firewall address-list
add address=::/128 comment="defconf: unspecified address" list=bad_ipv6
add address=::1/128 comment="defconf: lo" list=bad_ipv6
add address=fec0::/10 comment="defconf: site-local" list=bad_ipv6
add address=::ffff:0.0.0.0/96 comment="defconf: ipv4-mapped" list=bad_ipv6
add address=::/96 comment="defconf: ipv4 compat" list=bad_ipv6
add address=100::/64 comment="defconf: discard only " list=bad_ipv6
add address=2001:db8::/32 comment="defconf: documentation" list=bad_ipv6
add address=2001:10::/28 comment="defconf: ORCHID" list=bad_ipv6
add address=3ffe::/16 comment="defconf: 6bone" list=bad_ipv6
You can’t perform that action at this time.