Skip to content

Instantly share code, notes, and snippets.

View opensiriusfox's full-sized avatar
📡
CQ'ing for Space

Luke opensiriusfox

📡
CQ'ing for Space
  • Greater Seattle Area
View GitHub Profile
@marcan
marcan / fedora-autorestic.md
Last active November 16, 2024 18:42
Setting up autorestic on Fedora (Asahi) for automated backups with btrfs
  • Install restic and autorestic
  • sudo mkdir -p /var/cache/restic
  • Set up /etc/autorestic.yml roughly as follows:
backends:
    mybackend:
        # Your backend options here, see the documentation
global:
    all:
        cache-dir: /var/cache/restic
@timothyham
timothyham / ipv6guide.md
Last active November 19, 2024 00:20
A Short IPv6 Guide for Home IPv4 Admins

A Short IPv6 Guide for Home IPv4 Admins

This guide is for homelab admins who understand IPv4s well but find setting up IPv6 hard or annoying because things work differently. In some ways, managing an IPv6 network can be simpler than IPv4, one just needs to learn some new concepts and discard some old ones.

Let’s begin.

First of all, there are some concepts that one must unlearn from ipv4:

Concept 1

// cc $(pkg-config --cflags --libs libudev) udev_find_serial_by_vid_pid.c -o udev_find_serial_by_vid_pid
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <libudev.h>
int main(int argc, char **argv)
{
if (argc != 3) {
@opensiriusfox
opensiriusfox / Windows git.bashrc
Last active June 10, 2023 23:18
Git-Bash Notepad++ shortcut
# When notepad++ is available, use it
function npp() {
export IFS=$'\n'
NOTEPADPP_EXE='/c/Program Files/Notepad++/notepad++.exe'
if [[ -e "${NOTEPADPP_EXE}" ]]; then
echo 'notepad++.exe '$*' &'
"${NOTEPADPP_EXE}" $* &
return 0
else
echo "notepad++ not found."
@ryancdotorg
ryancdotorg / wzip.py
Last active October 22, 2024 14:42
Partial/streaming zip downloader
#!/usr/bin/env python3
# SPDX-License-Identifier: 0BSD or CC0-1.0 or MIT-0 or Unlicense
# Copyright (c) 2023, Ryan Castellucci, No Rights Reserved
import io, sys
import datetime
import argparse
import requests
import operator
import struct
@opensiriusfox
opensiriusfox / obfuscate.py
Created May 16, 2021 03:01
A little utility ot obfuscate strings with unicode.
#!/usr/bin/env python3
import click
from random import randint
from random import random
####################################################
##### Example Execution
# $ pip3 install click
# $ chmod +x ./obfuscate.py
#!/usr/bin/awk -f
# This program is a copy of guff, a plot device. https://github.com/silentbicycle/guff
# My copy here is written in awk instead of C, has no compelling benefit.
# Public domain. @thingskatedid
# Run as awk -v x=xyz ... or env variables for stuff?
# Assumptions: the data is evenly spaced along the x-axis
# TODO: moving average
@qdm12
qdm12 / README.md
Last active October 29, 2024 23:50
Wireguard and iptables restrictions for multiple users

Wireguard and iptables restrictions for multiple users

If you don't know what Wireguard is, well, you should. It's fast, easy to setup and highly configurable. We will configure Wireguard for multiple users with various restrictions using iptables.

Assumptions

This should fit most setups (not mine though 😉)

@mrladeia
mrladeia / readme.md
Last active October 29, 2024 14:09
Iptables to Oracle Cloud port 80 and 443 open

IPTABLES to Oracle Cloud port 80 and 443 open

If you need to open up ports 80 and 443, on file /etc/iptables/rules.v4 just add

-A INPUT -p tcp -m state --state NEW -m multiport --dports 80,443 -j ACCEPT

directly below

set(groot,'defaultAxesFontName','Proxima Nova Rg');
set(groot,'defaultPolaraxesFontName','Proxima Nova Rg');
set(groot,'defaultLegendFontName','Proxima Nova Rg');
set(groot,'defaultTextFontName','Proxima Nova Rg');
set(groot,'defaultTextarrowshapeFontName','Proxima Nova Rg');
set(groot,'defaultTextboxshapeFontName','Proxima Nova Rg');
set(groot,'defaultLegendBox','off')
%set(groot,'defaultLegendLocation','best')