Skip to content

Instantly share code, notes, and snippets.

View maxkratz's full-sized avatar
🐢

Max Kratz maxkratz

🐢
View GitHub Profile
@thesamesam
thesamesam / xz-backdoor.md
Last active May 13, 2025 14:21
xz-utils backdoor situation (CVE-2024-3094)

FAQ on the xz-utils backdoor (CVE-2024-3094)

This is a living document. Everything in this document is made in good faith of being accurate, but like I just said; we don't yet know everything about what's going on.

Update: I've disabled comments as of 2025-01-26 to avoid everyone having notifications for something a year on if someone wants to suggest a correction. Folks are free to email to suggest corrections still, of course.

Background

@justinhartman
justinhartman / 01_nginx-reload-post-hook.sh
Last active December 25, 2024 05:56
Let's Encrypt Certbot post hook command for Nginx which checks the updated configuration files and reloads the server if everything validates.
#!/usr/bin/env bash
#
# Certbot Nginx Reload
#
# Let's Encrypt Certbot post hook command for Nginx which checks the updated
# configuration files and reloads the server if everything validates.
#
# Author : Justin Hartman <[email protected]>
# Version : 1.0.1
# License : MIT <https://opensource.org/licenses/MIT>
@s3rj1k
s3rj1k / HowTo
Last active May 4, 2025 21:37
Ubuntu 20.04.3 AutoInstall
# For recent versions of Ubuntu:
- https://www.pugetsystems.com/labs/hpc/ubuntu-22-04-server-autoinstall-iso/
# Docs:
- https://wiki.ubuntu.com/FoundationsTeam/AutomatedServerInstalls
- https://wiki.ubuntu.com/FoundationsTeam/AutomatedServerInstalls/ConfigReference
- https://cloudinit.readthedocs.io/en/latest/topics/datasources/nocloud.html
- https://discourse.ubuntu.com/t/please-test-autoinstalls-for-20-04/15250/53
# Download ISO Installer:
@kbjarkefur
kbjarkefur / README.md
Last active May 5, 2025 08:42
Include link to git commit SHA used to compile pdf in LaTeX

Automatically include link to current git commit/SHA in compiled LaTeX pdf

This code lets you include an automatically updating link in a LaTeX compiled document that points to the last commit in the branch currently checked out in the repository where the .tex file used to compile the documents is saved. This allows you to track exactly which version of your .tex file was used to generate a given PDF.

Using Git you can then go back to the exact code used when compiling any saved or printed version of your document you find, no matter how long ago it was compiled. The commit SHA (the unique commit ID) will automatically update each time there is a new commit

@karl007
karl007 / riot_delete_room.php
Created February 13, 2020 09:35
[Matrix/Riot] kick all users of a room to delete it
#!/usr/bin/php
<?php
if(!function_exists('curl_init')) {
die('cURL not available!');
}
// check if there are every required arguments
if (count($argv) < 4) {
echo('USAGE: ' . $argv[0] . ' <URL> <TOKEN> <ROOM ALIAS|ID>');
@natanlao
natanlao / arq-ssh.md
Last active February 22, 2024 21:03
Generating SSH keys that will work with Arq

Generating SSH keys with Arq

Tested with Arq 5.

I encountered some issues trying to add my existing SSH key pairs with Arq. I saw errors like:

[path to key]: Key 'OPENSSH' is not supported.

or

@pirate
pirate / docker-compose-backup.sh
Last active January 26, 2025 23:38
Backup a docker-compose project, including all images, named and unnamed volumes, container filesystems, config, logs, and databases.
#!/usr/bin/env bash
### Bash Environment Setup
# http://redsymbol.net/articles/unofficial-bash-strict-mode/
# https://www.gnu.org/software/bash/manual/html_node/The-Set-Builtin.html
# set -o xtrace
set -o errexit
set -o errtrace
set -o nounset
set -o pipefail
@Quick104
Quick104 / readme.md
Last active March 19, 2025 12:55
Expose a server behind CG:NAT via Wireguard
@Brainiarc7
Brainiarc7 / ubuntu-1804lts-ocl-preparedness.md
Last active September 12, 2024 05:37
Preparing Ubuntu 18.04LTS as an OpenCL development platform, with a sample build target provided by Pyrit to demonstrate OpenCL ICD coexistence.

Preparing Ubuntu 18.04LTS as an OpenCL development platform:

With OpenCL, the installable client drivers (ICDs) are normally issued with the accelerator's device drivers, namely:

  1. The NVIDIA CUDA toolkit (and the device driver) for NVIDIA GPUs.
  2. AMD's RoCM for GCN-class AMD hardware.
  3. Intel's beignet and the newer Neo compute runtime.

The purpose of the installable client driver model is to allow multiple OpenCL platforms to coexist on the same platform. That way, multiple OpenCL accelerators, be they discrete GPUs paired with a combination of FPGAs and integrated GPUs can all coexist.

@maxidorius
maxidorius / matrix-howto-synapse_coturn.md
Last active October 22, 2024 09:54
Working config for VoIP in Matrix: synapse + coturn

This configuration is provided AS-IS and as an example/reference for those who do not find a working configuration for themselves. It is not always kept up to date and no support is provided.

Assuming:

  • Your Matrix domain: example.org
  • Your TURN domain (arbitrary): turn.example.org
  • Your Public IP: 1.2.3.4
  • Your Private IP for the box hosing the services: 10.11.12.13
  • A shared secret between synapse and coturn: ThisIsASharedSecret-ChangeMe
  • You want Firefox compatiblity (TURNS only is not supported)