Skip to content

Instantly share code, notes, and snippets.

View Danielk84's full-sized avatar
🎯
Focusing

Daniel Karami Danielk84

🎯
Focusing
  • Iran, Isfahan
  • 19:28 (UTC +03:30)
View GitHub Profile
#!/usr/sbin/nft -f
flush ruleset
table inet filter {
chain input {
type filter hook input priority 0; policy drop;
ct state invalid counter drop comment "Early drop of invalid packets"
ct state {established, related} counter accept comment "Accept all connections related to connections made by us"
meta l4proto icmp icmp type echo-request limit rate over 10/second burst 4 packets drop comment "No ping floods"
@Danielk84
Danielk84 / setup.sh
Created January 27, 2026 15:32
simple tor, torsocks, proxychains, nyx config generator
#!/usr/bin/env bash
## Global Settings
_TORRC="/etc/tor/torrc"
_PROXYCHAINS="/etc/proxychains.conf"
_MAX_PASSWORD_SIZE="64"
## Use colors, but only if connected to a terminal, and that terminal supports them.
{
# debug
grace_period 10s
shutdown_delay 30s
# email admin@example.com
# default_sni example.com
# local_certs
# acme_ca https://acme-staging-v02.api.letsencrypt.org/directory
# acme_ca_root /path/to/ca/root.pem
user www;
worker_processes auto;
worker_cpu_affinity auto;
pid /run/nginx.pid;
error_log /var/log/nginx/error.log;
events {
worker_connections 1000;
# multi_accept on;