Skip to content

Instantly share code, notes, and snippets.

View marvin-marvin's full-sized avatar
⌨️
https://gist.github.com/marvin-marvin

Marvin marvin-marvin

⌨️
https://gist.github.com/marvin-marvin
  • Braunschweig, Germany
View GitHub Profile
APT::Periodic::Update-Package-Lists "1";
APT::Periodic::Unattended-Upgrade "1";
//APT::Periodic::Download-Upgradeable-Packages "1";
//APT::Periodic::AutocleanInterval "7";
[Time]
NTP=time.cloudflare.com
FallbackNTP=time.google.com
#RootDistanceMaxSec=5
#PollIntervalMinSec=32
#PollIntervalMaxSec=2048
[Resolve]
DNS=127.0.0.1
FallbackDNS=9.9.9.9
#DNSSEC=yes
#DNSOverTLS=yes
#Domains=
#LLMNR=no
#MulticastDNS=no
#DNSOverTLS=no
#Cache=no-negative
set -s escape-time 0
setw -g aggressive-resize on
# Highlight active window
#set-window-option -g window-status-current-bg red
# disabled because issues
#set -g default-terminal “screen-256color”
### TESTING ###
@marvin-marvin
marvin-marvin / 99HttpProxy
Last active October 19, 2020 13:33
proxy system wide
#Acquire::http::proxy "http://192.168.1.201:3128";
#Acquire::https::proxy "https://192.168.1.201:3128";
#Acquire::ftp::proxy "ftp://192.168.1.201:3128";
@marvin-marvin
marvin-marvin / photon_kubes_setup.sh
Last active January 25, 2021 12:23
photon kubes setup
#Setup Photon OS
# SSH
# replace #PermitRootLogin prohibit-password with PermitRootLogin yes ; systemctl restart sshd
vi .ssh/authorized_keys (insert pub key)
# set hostname
hostnamectl set-hostname NAME
nano /etc/hosts
<reboot>
@marvin-marvin
marvin-marvin / pcap_kill.sh
Created July 15, 2020 14:58
sniffing via ssh
#!/bin/bash
# pinbox pcap export
SHELL=/bin/sh
PATH=/bin:/sbin:/usr/bin:/usr/sbin
while true
do
/usr/bin/ssh -i /root/.ssh/id_rsa -o "StrictHostKeyChecking no" [email protected] "/usr/bin/daemonlogger -R /data/pcap_tmp/SynologyRouter.pcap -o sniff0"
/usr/bin/pkill -f "/usr/bin/ssh -i /root/.ssh/id_rsa -o StrictHostKeyChecking no [email protected] rm /data/pcap_tmp/SynologyRouter.pcap ; cat >> /data/pcap_tmp/SynologyRouter.pcap"
sleep 90
@marvin-marvin
marvin-marvin / sniff_2_pinbox.sh
Last active July 19, 2020 17:56
sniff 2 pinbox
#!/bin/bash
# sniff 2 sensor
SHELL=/bin/sh
PATH=/bin:/sbin:/usr/bin:/usr/sbin
while true
do
/usr/sbin/tcpdump -i lbr0 -s0 -nn -w - | /usr/bin/ssh -i /root/.ssh/id_rsa -o "StrictHostKeyChecking no" [email protected] "/usr/bin/daemonlogger -R - -o eno1 -t 60 -c 4200000"
done
@marvin-marvin
marvin-marvin / sniff_2_sensor.sh
Last active August 20, 2020 06:47
sniff 2 sensor
#!/bin/bash
# sniff 2 sensor
SHELL=/bin/sh
PATH=/bin:/sbin:/usr/bin:/usr/sbin
while true
do
/usr/sbin/tcpdump -i lbr0 -s0 -nn -w - | /usr/bin/ssh -i /root/.ssh/id_rsa -o "StrictHostKeyChecking no" [email protected] "/usr/bin/daemonlogger -R - -o ens224 -t 60 -c 4200000"
done
// Proxy PAC
function FindProxyForURL(url, host) {
// Convert the host parameter to lowercase to facilitate case insensitive matching
host = host.toLowerCase();
url = url.toLowerCase();
// Don't proxy local hostnames
if (isPlainHostName(host))