Skip to content

Instantly share code, notes, and snippets.

@c3ph3us
c3ph3us / DNS tunneling with iodine.md
Created September 4, 2024 01:48 — forked from nukeador/DNS tunneling with iodine.md
How to install and use iodine for DNS tunneling.

This guide provides detailed steps for setting up DNS records, configuring a DNS tunneling server and client, and setting up a browser for secure proxy connections.

Why iodine?

  • Bypassing Network Restrictions: iodine excels in environments with strict network restrictions. It utilizes DNS queries, which are typically allowed through firewalls, to tunnel data where traditional methods like VPNs might be blocked.
  • Efficient for Limited Bandwidth: Ideal for situations with bandwidth limitations, iodine requires less bandwidth compared to standard VPNs, making it a practical choice for networks with restricted data flow.
  • Customizability and Open Source: As an open-source tool, iodine offers extensive customization options. Users with specific technical needs or those interested in a hands-on approach to network tunneling can tailor iodine to their requirements.

Prerequisites

@c3ph3us
c3ph3us / install_debian_with_debootstrap_howto.md
Created September 2, 2024 17:04 — forked from varqox/install_debian_with_debootstrap_howto.md
Instructions how to install Debian using debootstrap
@c3ph3us
c3ph3us / remote-capture-packet-simple.rst
Created September 1, 2024 07:05 — forked from quyenlv/remote-capture-packet-simple.rst
Remote capturing packet with tcpdump and wireshark.

Topology

+------------------+                    +----------------------+
|   Local host     |  tcpdump over ssh  |    Remote Host       |
|                  |--------------------|                      |\ eth0
| +--------------+ |--------------------|                      |/
| |   Wireshark  | |                    |  tcpdump -i eth0...  |
@c3ph3us
c3ph3us / instructions.txt
Created August 13, 2024 05:27 — forked from jjwhitney/instructions.txt
Recover a ZFS pool hidden on a detached device
Originally written by Jeff Bonwick (http://www.mail-archive.com/zfs-discuss@opensolaris.org/msg15748.html), and updated by James Lee to work with modern ZFS libs (https://www.mail-archive.com/zfs-discuss@opensolaris.org/msg47316.html), I was able to compile this life-saving utility in Ubuntu 14.04 and have verified that it works. (I'm using ZFSonLinux.)
Download the ZFSonLinux tarball and replace the cmd/zhack/zhack.c file with "labelfix.c". Note that zhack is just a simple utility that we're replacing so that we don't have to setup the build environment. (It's hard, so we'll reuse the good work of the ZFSonLinux people.)
Run "./configure; make" and if all goes well then the zfs tools will be built, except for zhack, which we replaced. Run that with the device path to recover your data.
If you want to be super-careful and not tamper with your disk, you can clone it and run the utility on your clone. Or, create an overlay as described in this page: https://raid.wiki.kernel.org/index.php/Recovering_a_failed_
@c3ph3us
c3ph3us / zfs_revert.py
Created August 13, 2024 04:10 — forked from mkhon/zfs_revert.py
This is the original zfs_revert-0.1.py script by Martin Vool <mardicas@gmail.com> for reverting ZFS transactions by destroying uberblocks, adapted for FreeBSD od (multiple spaces in output).
#!/usr/bin/python
# -*- coding: utf-8 -*-
#Script for reverting ZFS changes by destroying uberblocks
#Author: Martin Vool
#E-mail: mardicas@gmail.com
#Version: 0.1
#Date: 16 November 2009
@c3ph3us
c3ph3us / virt-manager.md
Created July 23, 2024 09:54 — forked from Jiab77/virt-manager.md
This gist will give you all installation steps needed to install properly virt-manager with all dependencies.

Virt-Manager Installation (for ubuntu based distrib)

This gist will give you all installation steps needed to install properly virt-manager with all dependencies.

Dependencies

Here is the list of all dependencies required to install properly virt-manager on your ubuntu based distrib.

  • libvirt-bin
  • qemu
@c3ph3us
c3ph3us / AndroidManifest.xml
Created September 24, 2023 14:38 — forked from sreelallalu/AndroidManifest.xml
Android USB detection
<uses-feature android:name="android.hardware.usb.host" />
<uses-permission android:name="android.permission.USB_PERMISSION" />
<activity android:name=".activities.MainActivity"
android:launchMode="singleTop">
<intent-filter>
<action android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED" />
</intent-filter>
@c3ph3us
c3ph3us / get_authorized_keys.sh
Created August 17, 2023 15:49 — forked from RichardBronosky/get_authorized_keys.sh
Get ssh keys for Raspberry Pi from GitHub
sudo bash <<EOF
local_user=pi
github_user=RichardBronosky
umask 077
mkdir -p ~$local_user/.ssh
curl -sSL https://github.com/${github_user}.keys >> ~$local_user/.ssh/authorized_keys
chown -R $(id -u $local_user):$(id -g $local_user) ~$local_user/.ssh
EOF
@c3ph3us
c3ph3us / source.bash
Created August 17, 2023 15:49 — forked from RichardBronosky/source.bash
A collection of tools for working with JS and JSON
:<<'DOCS'
* This script adds to your bash shell, a collection of tools for working with JS and JSON
* To install it, cd to where ever you checkout git repos and copy-paste the following line:
dst=jtools; git clone https://gist.github.com/81a3991aa63580283bf2f3db18ecf2fb.git $dst && echo -e "\n[[ -f $(dirs +0)/$dst/source.bash ]] && source $(dirs +0)/$dst/source.bash" >> ~/.bash_profile
DOCS
# converts serialized python to JSON
p2j() { python3 -c "import json, sys; print(json.dumps(eval(sys.stdin.read())))"; }
@c3ph3us
c3ph3us / similarities.sh
Created August 17, 2023 15:47 — forked from RichardBronosky/similarities.sh
Identify how similar a file is to each file in a group of others.
#!/bin/bash
fileA="$1"
shift
for fileB in "$@"; do
(
# diff once grep twice with the help of tee and stderr
diff $fileA $fileB | \
tee >(grep -cE '^< ' >&2) | \
grep -cE '^> ' >&2