This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Q: What is this? | |
# A: This is a script designed to make a Debian install (with networking and iptables) serve as a router. If the Debian install this is running on can talk with the Internet already, this script will configure iptables to perform NAT for the specified networks, allowing other devices to use this Debian installation as a gateway. This script can also configure port forwarding. See the examples below! | |
# How to use: | |
# 1. Update networks, interfaces, and rules below | |
# 2. Run once after updating on Debian systems | |
# Guarantee reloading on reboot: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use warnings; | |
use strict; | |
use IO::Socket::INET; | |
use IO::Select; | |
my @allowed_ips = ('all', '10.10.10.5'); | |
my $ioset = IO::Select->new; | |
my %socket_map; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.caharkness.demo.kotlin | |
import android.graphics.Canvas | |
import androidx.appcompat.app.AppCompatActivity | |
import android.os.Bundle | |
import android.util.TypedValue | |
import android.view.Gravity | |
import android.view.ViewGroup | |
import android.widget.Button | |
import android.widget.LinearLayout |