This Gist contains my IPTables rules for securing the Asterisk VoIP server. The "string" module is used to identify legitimate users and block attackers.
Learn how to set up your personal VoIP server
↓ ↓ ↓ Scroll down for the IPTables rules ↓ ↓ ↓
# The blog post that started it all: https://neocities.org/blog/the-fcc-is-now-rate-limited | |
# | |
# Current known FCC address ranges: | |
# https://news.ycombinator.com/item?id=7716915 | |
# | |
# Confirm/locate FCC IP ranges with this: http://whois.arin.net/rest/net/NET-165-135-0-0-1/pft | |
# | |
# In your nginx.conf: | |
location / { |
#!/bin/bash | |
# THIS SCRIPT SETS UP SOME BASIC IP TABLES RULES FOR YOUR SYSTEM. | |
# YOU SHOULD BUY A BOOK AND GOOGLE TO UNDERSTAND WHAT IS GOING ON HERE. | |
# YOUR SYSTEM'S SECURITY SHOULD NOT BE LEFT UP TO A SCRIPT APPLICATION | |
# OR ME. IT IS YOUR RESPONSIBILITY TO ENSURE YOUR OWN SECURITY. | |
# THIS IS PRESENTED WITHOUT ANY WARRANTY. ANY USE OF THIS IS AT YOUR OWN RISK | |
# | |
# Written by James Finstrom ([email protected]) | |
# |
<?php | |
function it($m,$p){echo ($p?'✔︎':'✘')." It $m\n"; if(!$p){$GLOBALS['f']=1;}}function done(){if(@$GLOBALS['f'])die(1);} |
#!/usr/bin/php -q | |
<?php | |
/*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** | |
* | |
* Latest Version: https://gist.github.com/lgaetz/8633920 | |
* | |
* Description: | |
* | |
* Script lgaetz-didloopback.php is used on a FreePBX server, with custom dialplan that calls |
This Gist contains my IPTables rules for securing the Asterisk VoIP server. The "string" module is used to identify legitimate users and block attackers.
Learn how to set up your personal VoIP server
↓ ↓ ↓ Scroll down for the IPTables rules ↓ ↓ ↓
#!/bin/bash | |
set -e #exit as soon as any command fail | |
default_ssh_passwd="c2VjcmV0Cg==" | |
default_mysql_passwd="c2VjcmV0Cg==" | |
exec 9>/tmp/$(basename $0).lock #verify only one instance is running | |
if ! flock -n 9 ; then #http://mywiki.wooledge.org/BashFAQ/045 | |
echo "$(basename $0): another instance is running"; | |
exit 1 |
# This is a template .gitignore file for git-managed WordPress projects. | |
# | |
# Fact: you don't want WordPress core files, or your server-specific | |
# configuration files etc., in your project's repository. You just don't. | |
# | |
# Solution: stick this file up your repository root (which it assumes is | |
# also the WordPress root directory) and add exceptions for any plugins, | |
# themes, and other directories that should be under version control. | |
# | |
# See the comments below for more info on how to add exceptions for your |