Skip to content

Instantly share code, notes, and snippets.

@MrWeez
MrWeez / cloudflare-tlsa-auto-updater.sh
Last active April 28, 2024 09:29
This script allows you to automatically update the TLSA record via Cloudflare API. This is useful when using Let's Encrypt certificates to avoid manually updating records after reissuing the certificate.
#!/bin/bash
# Variables
API_KEY="CHANGE_ME" # Cloudflare API key
API_TOKEN="CHANGE_ME" # Cloudflare API token
API_EMAIL="CHANGE_ME" # Cloudflare account email
ZONE_ID="CHANGE_ME" # ID of the domain
DNS_RECORD_NAMES=("_25._tcp.domain.com" "_110._tcp.domain.com" "_143._tcp.domain.com" "_465._tcp.domain.com" "_587._tcp.domain.com" "_993._tcp.domain.com" "_995._tcp.domain.com") # List of TLSA records
DOMAIN="domain.com" # Your domain
SSL_CERTIFICATE="/path/to/cert.pem" # Path to cert file
@SleeplessByte
SleeplessByte / helper_array_to_listing.php
Last active April 28, 2024 09:26
Creates a human readable list of an array, implodes all items, but combines last two first.
<?php
/**
* Creates a human readable list of an array
*
* @param string[] $ranges array to list items of
* @param string $glue normal glue between items
* @param string $last glue between last two items
*
* @remarks works with 0, 1, 2 or 3+ items
* @returns string 'item1, item2, item3 or item4'
@skfarhat
skfarhat / VSCode Internal Commands
Created May 19, 2020 21:22
List of VSCode commands
--------------------------------------------
Version: 1.45.1
Commit: 5763d909d5f12fe19f215cbfdd29a91c0fa9208a
Date: 2020-05-14T08:33:47.663Z
Electron: 7.2.4
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Darwin x64 18.5.0
-------------------------------------------
@taskylizard
taskylizard / fmhy.md
Last active April 28, 2024 09:23
/r/freemediaheckyeah, in one single file (view raw)
Home/Core TX9XD-98N7V-6WMQ6-BX7FG-H8Q99
Home/Core (Country Specific) PVMJN-6DFY6-9CCP6-7BKTT-D3WVR
Home/Core (Single Language) 7HNRX-D7KGG-3K4RQ-4WPJ4-YTDFH
Home/Core N 3KHY7-WNT83-DGQKR-F7HPR-844BM
Professional W269N-WFGWX-YVC9B-4J6C9-T83GX
Professional N MH37W-N47XK-V7XM9-C7227-GCQG9
Professional Enterprise
Professional Workstation
Enterprise NPPR9-FWDCX-D2C8J-H872K-2YT43
Enterprise N DPH2V-TTNVB-4X9Q3-TJR4H-KHJW4
@ebubekirtrkr
ebubekirtrkr / discord_flag_emoji_list.js
Created April 1, 2021 18:06
Discord Flag Emoji List
[
":checkered_flag:",
":crossed_flags:",
":flag_ac:",
":flag_ad:",
":flag_ae:",
":flag_af:",
":flag_ag:",
":flag_ai:",
":flag_al:",
@ammarshah
ammarshah / all_email_provider_domains.txt
Last active April 28, 2024 09:12
A list of all email provider domains (free, paid, blacklist etc). Some of these are probably not around anymore. I've combined a dozen lists from around the web. Current "major providers" should all be in here as of the date this is created.
0-mail.com
007addict.com
020.co.uk
027168.com
0815.ru
0815.su
0clickemail.com
0sg.net
0wnd.net
0wnd.org
@aodin
aodin / parse_nginx_access_log.py
Last active April 28, 2024 09:10
Parse an Nginx access.log file into a Pandas DataFrame
"""
Parse an Nginx access.log file into a Pandas DataFrame. Also works with gzipped files.
"""
import argparse
import pathlib
import pandas as pd
parser = argparse.ArgumentParser()
@prrao87
prrao87 / install_postman_mint_no_snap.md
Last active April 28, 2024 09:10
Install Postman on Linux Mint (without using snap)

Goal

Postman is a usefull app to build and test APIs, most commonly installed on ubuntu-like systems via snap. On recent distributions of Linux Mint (20 and above), snap installs are no longer possible. The instructions below show how to install Postman via the terminal.

Download Postman

$ wget https://dl.pstmn.io/download/latest/linux64 -O postman.tar.gz

Extract archive

$ sudo tar -xzf postman.tar.gz -C /opt

Make symlink

@maboloshi
maboloshi / Set_Proxy.md
Last active April 28, 2024 09:05
[软件 Proxy 设置] #proxy #git #ssh #chrome #Sublime-Text-4

软件 Proxy 设置

Proxy 一般有2种协议,一种是 HTTP/HTTPS 协议,一种是 SOCKS 协议。优先使用 SOCKS 协议的 SOCKS5 版本。[2种协议的区别 待补充外部引用]

一般各平台的代理客户端除了提供一个本地的 socks5 Proxy ,还会提供一个本地的 http Proxy 。 在客户端相应设置中查看 socks5 协议监听的端口,HTTP Proxy 设置中查看 http 协议监听的端口。

注意:不少客户端提供混合模式,即socks5http端口号是同一个,所以不用费尽心思在软件设定中找单独的 http 端口设置功能了。

Chrome 浏览器 Proxy 设置