Skip to content

Instantly share code, notes, and snippets.

@themagicalmammal
themagicalmammal / Optimizations_Artix.md
Last active March 6, 2026 11:15
Set of optimizations, I use on my Artix Setup

Artix Linux — Complete System Optimization Guide

Warning: This guide contains system-level modifications. Some steps are irreversible or can render your system unbootable. Read every section fully before executing any command. Know what you are doing, or do not proceed.

All examples are written for runit. Adapt service commands for OpenRC or s6 as needed.


Index

@bcoles
bcoles / linux-pam-backdoor-detect.sh
Created September 13, 2020 13:40
Detect PAM backdoors created by linux-pam-backdoor
#!/bin/bash
# Detect PAM backdoors created by linux-pam-backdoor:
# https://github.com/zephrax/linux-pam-backdoor
#
# Note: this will likely only work with PAM version 1.3.0.
# ---
# $ ./backdoor.sh -v 1.3.0 -p some_s3cr3t_p455word
# Automatic PAM Backdoor
# PAM Version: 1.3.0
# Password: some_s3cr3t_p455word
@goll
goll / README.md
Last active December 17, 2025 05:52
Docker nftables configuration for Debian 10
@mcattarinussi
mcattarinussi / gpg-ssh-setup.md
Last active March 21, 2026 13:17
A setup guide to use a personal gpg key for ssh authentication

GPG - SSH setup

Generating the master key

Here we create the master key. We want only Certify capability: we use the master key only to create the subkeys, Sign - Encrypt - Authenticate capabilities will be assigned to the subkeys.

Run the following command to start the master key generation process. Select the set your own capabilities creation process (type 8)

  ▶ gpg --full-generate-key --expert

gpg (GnuPG) 2.2.9; Copyright (C) 2018 Free Software Foundation, Inc.

#!/usr/bin/env bash
apt-get install -y libpcre3 libpcre3-dev libssl-dev unzip make \
libgoogle-perftools-dev google-perftools jq gcc zlib1g-dev
mkdir /tmp/ngxbuild
cd /tmp/ngxbuild
ng_cookies=$(curl -s http://hg.nginx.org/nginx/tags|grep cookie|cut -f 2 -d '"'|tr -d '\n')
latestNginx=$(curl --cookie ${ng_cookies} -s http://hg.nginx.org/nginx/tags|grep "^ *release-" | head -1 | cut -c 9-)
echo "found: ${latestNginx}"
latestNaxsi=$(curl -s https://api.github.com/repos/nbs-system/naxsi/releases |
@skulltech
skulltech / dl.py
Created February 6, 2018 23:50
Handy Python function for downloading file with progress bar
import sys
import requests
def download(url, filename):
with open(filename, 'wb') as f:
response = requests.get(url, stream=True)
total = response.headers.get('content-length')
if total is None:
@ansulev
ansulev / install-arch-linux-on-btrfs-subvolume-inside-luks
Last active July 23, 2025 19:37
Install Arch Linux with full encrypted btrfs subvolume inside luks
# Install Arch Linux with full encrypted btrfs subvolume inside luks
# Hardware: BIOS system, Intel GPU, Nvidia Optimus, Toshiba SSD, Wifi
# Please adjust for your needs.
# filename: install-arch-linux-on-btrfs-subvolume-inside-luks.txt
# The official guide: https://wiki.archlinux.org/index.php/Installation_Guide
# Download the archiso image from https://www.archlinux.org/download/
# Copy to a usb-drive
dd bs=4M if=archlinux.iso of=/dev/sdx status=progress oflag=sync # on linux