Skip to content

Instantly share code, notes, and snippets.

@loganvolkers
loganvolkers / Byte Formatting for Google Sheets.md
Last active April 16, 2024 10:42
Byte formatting for Google Sheets
@mcastelino
mcastelino / Kube-dns.md
Last active June 20, 2022 08:48
kubernetes kube-dns components, debugging

Summary

  • dnsmasq front ends the requests and sends them on to kube-dns

    dnsmasq
      --cache-size=1000
      --no-resolv
      --server=127.0.0.1#10053
    

--log-facility=-

@andrewlkho
andrewlkho / debian-strongswan.md
Last active January 3, 2024 03:39
Setting up a secure VPN with strongSwan on debian

With heightening concern regarding the state of internet privacy (fuelled in part by the passing of the Investigatory Powers Act in the UK), I have set up a VPN server on the virtual server I have hosted with Mythic Beasts. This uses strongSwan and certificate-based IKEv2 authentication.

Assumptions:

  • Debian Jessie server already set up and accessible via debian.example.com, a public IPv4 of 203.0.113.1 and a public IPv6 of 2001:db8::1
  • Client username of me
  • Clients are running the latest versions of macOS and iOS (Sierra and 10 respectively at the time of writing)
  • No need to support any other operating systems (although the setup is easily translated)

For automated deployment of a similar setup, albeit Ubuntu-based and using ansible for deployment, I recommend you take a look at Algo VPN. I used that project as a basis for my configuration.

@bishboria
bishboria / springer-free-maths-books.md
Last active April 25, 2024 06:27
Springer made a bunch of books available for free, these were the direct links
@tuxfight3r
tuxfight3r / tcp_flags.txt
Last active April 17, 2024 14:48
tcpdump - reading tcp flags
##TCP FLAGS##
Unskilled Attackers Pester Real Security Folks
==============================================
TCPDUMP FLAGS
Unskilled = URG = (Not Displayed in Flag Field, Displayed elsewhere)
Attackers = ACK = (Not Displayed in Flag Field, Displayed elsewhere)
Pester = PSH = [P] (Push Data)
Real = RST = [R] (Reset Connection)
Security = SYN = [S] (Start Connection)
@jzb
jzb / Atomic Host Definition.md
Last active June 23, 2023 15:17
Atomic Host Definition [Discussion Draft]

Atomic Host Definition [Discussion Draft]

This document is meant to serve as a baseline definition for Project Atomic hosts, to be implemented from CentOS, Fedora, and Red Hat Enterprise Linux (RHEL).

The purpose of the document is not to restrict the packages or services offered with an Atomic host, but to ensure a baseline of functionality and working standard that each product team can implement before adding additional functionality.

The initial working draft is being taken from work going into RHEL Atomic, but it is expected that the CentOS Atomic SIG and Fedora Cloud Workgroup will provide input and direction to Project Atomic going forward. This is simply the first cut at a shared understanding that gives each team a basis for cooperation.

Atomic Host Definition

@hsribei
hsribei / can-nat-traversal-be-tor-s-killer-feature.md
Last active July 12, 2018 19:15
Can NAT traversal be Tor's killer feature?

Can NAT traversal be Tor's killer feature?

tl;dr: how about a virtual global flat LAN that maps static IPs to onion addresses?

[We all know the story][1]. Random feature gets unintentionally picked up as the main reason for buying/using a certain product, despite the creator's intention being different or more general. (PC: spreadsheets; Internet: porn; smartphones: messaging.)

@pkuczynski
pkuczynski / parse_yaml.sh
Last active April 9, 2024 18:36
Read YAML file from Bash script
#!/bin/sh
parse_yaml() {
local prefix=$2
local s='[[:space:]]*' w='[a-zA-Z0-9_]*' fs=$(echo @|tr @ '\034')
sed -ne "s|^\($s\)\($w\)$s:$s\"\(.*\)\"$s\$|\1$fs\2$fs\3|p" \
-e "s|^\($s\)\($w\)$s:$s\(.*\)$s\$|\1$fs\2$fs\3|p" $1 |
awk -F$fs '{
indent = length($1)/2;
vname[indent] = $2;
for (i in vname) {if (i > indent) {delete vname[i]}}
@theladyjaye
theladyjaye / cmd.sh
Created October 18, 2013 21:06
clear salt minion cache
salt '*' cmd.run 'rm -rm /var/cache/salt/minion/files/base/*'
salt '*' saltutil.sync_all