Skip to content

Instantly share code, notes, and snippets.

@ctsrc
ctsrc / 00_install_fbsd_14_0_hetzner.md
Last active May 1, 2024 04:21
Install FreeBSD 14.0 on Hetzner

Install FreeBSD 14.0 on Hetzner server

Hetzner no longer offers direct install of FreeBSD, but we can do it ourselves. Here is how :)

Boot the hetzner server in Hetnzer Debain based rescue mode. ssh into it. then:

wget https://mfsbsd.vx.sk/files/iso/14/amd64/mfsbsd-14.0-RELEASE-amd64.iso

qemu-system-x86_64 \
@ryancdotorg
ryancdotorg / private.conf
Created March 2, 2022 15:17
anti-bot nginx snippet
location ~ ^/private/.*[.]html$ {
try_files /$d_pelican$uri /$d_pelican$uri/index.html /_web$uri @tryredir;
# can check $request_filename
set $h_robots "noindex, nofollow, noarchive, nosnippet, none";
expires 5m;
max_ranges 0;
header_filter_by_lua_block {
local pcre = require "pcre"
if ngx.var.http_accept_language == nil then
return ngx.exit(403)
@thisismitch
thisismitch / le-renew-webroot
Last active April 26, 2024 04:13
Let's Encrypt Auto-Renewal using the Webroot Plugin (Nginx)
#!/bin/bash
web_service='nginx'
config_file="/usr/local/etc/le-renew-webroot.ini"
le_path='/opt/letsencrypt'
exp_limit=30;
if [ ! -f $config_file ]; then
echo "[ERROR] config file does not exist: $config_file"
@xero
xero / irc.md
Last active May 3, 2024 23:19
irc cheat sheet

IRC Reference

Not intended as a guide for newbies, more like a "cheat sheet" for the somewhat experienced IRC user, especially one who wields some power over a channel.

The Basics

  • /join #channel
    • Joins the specified channel.
  • /part #channel
  • Leaves the specified channel.
@darekkay
darekkay / putty-eclectide.reg
Last active February 9, 2022 09:10
Eclectide color theme for the Putty SSH client
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\SimonTatham\PuTTY\Sessions\SESSION_NAME]
; Default Foreground
"Colour0"="217,216,216"
; Default Bold Foreground
"Colour1"="217,216,216"
; Default Background
"Colour2"="28,28,28"
@jo
jo / js-crypto-libraries.md
Last active March 31, 2024 20:33
List of JavaScript Crypto libraries.

JavaScript Crypto Libraries

List some crypto libraries for JavaScript out there. Might be a bit out dated. Scroll to the bottom.

WebCryptoAPI

http://www.w3.org/TR/WebCryptoAPI/

This specification describes a JavaScript API for performing basic cryptographic operations in web applications, such as hashing, signature generation and verification, and encryption and decryption. Additionally, it describes an API for applications to generate and/or manage the keying material necessary to perform these operations. Uses for this API range from user or service authentication, document or code signing, and the confidentiality and integrity of communications.

@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active May 9, 2024 06:43
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@mattrude
mattrude / changepassword.php
Created October 31, 2010 23:49
LDAP PHP Change Password Page
<?php
/**
* LDAP PHP Change Password Webpage
* @author: Matt Rude <http://mattrude.com>
* @website: http://technology.mattrude.com/2010/11/ldap-php-change-password-webpage/
*
*
* GNU GENERAL PUBLIC LICENSE
* Version 2, June 1991