Skip to content

Instantly share code, notes, and snippets.

View zoonderkins's full-sized avatar
🏠
Working 👍

Quack~ zoonderkins

🏠
Working 👍
View GitHub Profile
@zoonderkins
zoonderkins / rules-both.iptables
Created June 22, 2019 06:17 — forked from jirutka/rules-both.iptables
Basic iptables template for ordinary servers (both IPv4 and IPv6)
###############################################################################
# The MIT License
#
# Copyright 2012-2014 Jakub Jirutka <[email protected]>.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
@zoonderkins
zoonderkins / fix-debian9-kernel-unable-to-update.md
Last active June 18, 2019 05:55
Debian9 kernel unable to update

Fix

ls /etc/kernel/postinst.d/

// check if system has file "zz-update-grub" and rename it 
mv zz-update-grub zz-update-grub.bak

// update-grub
update-grub
@zoonderkins
zoonderkins / delete-debian-tun-link.md
Created April 26, 2019 08:48
delete-debian-tun-link #linux
@zoonderkins
zoonderkins / curl-ipv6-on-linux.md
Created April 14, 2019 19:26
Curl IPv6 on Linux
curl 'https://api6.ipify.org?format=json'
@zoonderkins
zoonderkins / dnsdist-config.md
Created April 14, 2019 09:07
dnsdist config
-- listen for console connection with the given secret key
-- controlSocket("0.0.0.0")
-- setKey(please generate a fresh private key with makeKey())

-- start the web server on port 8083, using password 'set a random password here'
-- webserver("0.0.0.0:8083", "set a random password here")

-- accept DNS queries on UDP/5200 and TCP/5200
@zoonderkins
zoonderkins / mac-mojave-10-14-protection.md
Created April 14, 2019 08:05
Turn off all Mac Mojave 10.14 Proctection

SIP Disable

Need to disable on Recovery mode, CMD + R

csrutil status

csrutil disable

Disable Gatekeeper

@zoonderkins
zoonderkins / Debian9-sid-install-haproxy-1.9.md
Created March 20, 2019 02:26
Haproxy install on Debian9 sid 1.9.5 #linux

Debian/Ubuntu install HAProxy 1.9 by using sid

https://haproxy.debian.net/#?distribution=Debian&release=sid&version=1.9

You need to enable the experimental repository:

echo deb http://httpredir.debian.org/debian experimental main | \

tee /etc/apt/sources.list.d/experimental.list

@zoonderkins
zoonderkins / use-ipset-block-ip-linux.md
Last active March 17, 2019 17:57
IPset to block IP on Linux #linux

Env: Debian9 or Ubuntu

Installation

apt install ipset

Setup Ipv4, IPv6

@zoonderkins
zoonderkins / temp-dns-iptables.md
Last active March 16, 2019 14:27
temp-dns-iptables.md
*filter
:INPUT DROP [0:0]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
:f2b-sshd - [0:0]
:f2b-SSH - [0:0]
:RATE-LIMIT - [0:0]

-A INPUT -i lo -j ACCEPT