Skip to content

Instantly share code, notes, and snippets.

View C0ntr07's full-sized avatar
💭
Lurking in the dark areas of the internet

Chris Hewitt C0ntr07

💭
Lurking in the dark areas of the internet
  • Behind you
View GitHub Profile
@C0ntr07
C0ntr07 / 01 pi-hole-vpn-combo_setup.md
Created April 23, 2024 13:08 — forked from Haprog/01 pi-hole-vpn-combo_setup.md
Installing Pi-Hole, Unbound and a WireGuard VPN server on a Raspberry Pi (via Docker)

Updated: 2022-07

Raspberry Pi-Hole VPN Setup

I wrote the first edition of this as a guide for myself at the end of 2017 - it was a mashup of Pi-Hole + PiVPN scripts and an IPsec script installed within a separate Raspian Docker image... and it actually worked!

But things have come a long way, and WireGuard happened - I've since streamlined and simplified my setup into a single Docker Compose script.

The steps below assume the following:

@C0ntr07
C0ntr07 / cidr2ip
Created February 27, 2023 21:58 — forked from deardooley/cidr2ip
cidr to ip range or list. This script prints the ip ranges for a cidr by default. Full ip lists can be obtained with the -a or --all flags.
#!/usr/bin/env bash
# Print usage
function usage {
echo -n "$(basename $0) CIDR...
$(basename $0) [OPTION] CIDR...
This script prints the ip range or full list of ip addresses for one or more CIDR.
Options:
From: http://redteams.net/bookshelf/
Techie
Unauthorised Access: Physical Penetration Testing For IT Security Teams by Wil Allsopp.
Social Engineering: The Art of Human Hacking by Christopher Hadnagy
Practical Lock Picking: A Physical Penetration Tester's Training Guide by Deviant Ollam
The Art of Deception: Controlling the Human Element of Security by Kevin Mitnick
Hacking: The Art of Exploitation by Jon Erickson and Hacking Exposed by Stuart McClure and others.
Nmap Network Scanning: The Official Nmap Project Guide to Network Discovery and Security Scanning by Fyodor
The Shellcoder's Handbook: Discovering and Exploiting Security Holes by several authors
@C0ntr07
C0ntr07 / WireGuard_Setup.txt
Created January 22, 2021 20:02 — forked from chrisswanda/WireGuard_Setup.txt
Stupid simple setting up WireGuard - Server and multiple peers
Install WireGuard via whatever package manager you use. For me, I use apt.
$ sudo add-apt-repository ppa:wireguard/wireguard
$ sudo apt-get update
$ sudo apt-get install wireguard
MacOS
$ brew install wireguard-tools
Generate key your key pairs. The key pairs are just that, key pairs. They can be
@C0ntr07
C0ntr07 / rpi-hdmi.sh
Created January 13, 2021 21:50 — forked from AGWA/rpi-hdmi.sh
Enable and disable the HDMI port on the Raspberry Pi: `rpi-hdmi on` to turn on, `rpi-hdmi off` to turn off. X is properly reinitialized when re-enabling.
#!/bin/sh
# Enable and disable HDMI output on the Raspberry Pi
is_off ()
{
tvservice -s | grep "TV is off" >/dev/null
}
case $1 in
#!/usr/bin/python
"""
advanced-flood.py
@author: Randall Degges
@email: rdegges@gmail.com
@date: 11-20-09
This program floods the specified phone number and spoofs caller ID making it
@C0ntr07
C0ntr07 / RPi-install-wifi.sh
Created November 9, 2020 17:21 — forked from kmonsoor/RPi-install-wifi.sh
install wifi adapter drivers on Raspberry Pi; origin: http://www.fars-robotics.net/install-wifi
#!/bin/bash
#set -e
# origin-source: http://www.fars-robotics.net/install-wifi
# install-wifi - v9.4 - by MrEngman.
# After downloading this script:
# $ sudo mv ./install-wifi /usr/bin/install-wifi
# $ sudo chmod +x /usr/bin/install-wifi
# $ sudo install-wifi -h
#
@C0ntr07
C0ntr07 / raspi-init.sh
Created October 30, 2020 15:26 — forked from adoyle/raspi-init.sh
Non-interactive command-line equivalents to raspi-config
# Non-interactive command-line equivalents to raspi-config
# These are not guaranteed to work under all circumstances.
# I use them in a fabric script to do unattended setup of a
# Raspberry Pi immediately after having booted up a NOOBS
# and installed Raspbian.
#
# 1. Install NOOBS
# 2. When the config screen comes up, hit TAB TAB RETURN to exit from it
# 3. Type 'sudo service ssh start' at the command line (no quotes).
# 4. (Optional) copy a public key to the pi account on the pi.
@C0ntr07
C0ntr07 / nexmon.sh
Created October 1, 2020 17:42 — forked from someguycrafting/nexmon.sh
Raspberry PI 3 / Zero Wi-Fi monitor mode setup
#!/bin/bash
# Thanks to all the nice folks @seemoo-lab for making this possible.
# See: https://github.com/seemoo-lab/nexmon
# This script should be run as root (i.e: sudo ./nexmon.sh) from the /home/pi/ directory!
function info {
tput bold;
tput setaf 3;
echo $1;
@C0ntr07
C0ntr07 / redis_cheatsheet.bash
Created September 15, 2020 01:10 — forked from LeCoupa/redis_cheatsheet.bash
Redis Cheatsheet - Basic Commands You Must Know --> UPDATED VERSION --> https://github.com/LeCoupa/awesome-cheatsheets
# Redis Cheatsheet
# All the commands you need to know
redis-server /path/redis.conf # start redis with the related configuration file
redis-cli # opens a redis prompt
# Strings.