Skip to content

Instantly share code, notes, and snippets.

View rlex's full-sized avatar
🏠
Working from home

Lex Rivera rlex

🏠
Working from home
View GitHub Profile
@rlex
rlex / adblock.list
Created April 16, 2019 13:21
Pihole settings
https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
https://mirror1.malwaredomains.com/files/justdomains
http://sysctl.org/cameleon/hosts
https://zeustracker.abuse.ch/blocklist.php?download=domainblocklist
https://s3.amazonaws.com/lists.disconnect.me/simple_tracking.txt
https://s3.amazonaws.com/lists.disconnect.me/simple_ad.txt
https://hosts-file.net/ad_servers.txt
https://hosts-file.net/grm.txt
https://reddestdream.github.io/Projects/MinimalHosts/etc/MinimalHostsBlocker/minimalhosts
https://raw.githubusercontent.com/StevenBlack/hosts/master/data/KADhosts/hosts
@rlex
rlex / danted.conf
Last active December 8, 2020 15:53
dante telegram config
#Tested on Debian 9
#Write log
logoutput: syslog /var/log/sockd.log
#Listen IPv4
internal: 1.2.3.4 port = 1080
#Listen IPv6
#internal: Y::Y port = 1080
#External IPv4
@rlex
rlex / gist:2ec8562c4642032600e3e4c8a5acac4b
Created April 4, 2018 13:42
Mikrotik <-> Linux GRE/IPSec, strongswan
config setup
charondebug="ike 2, knl 2, cfg 2, net 2, esp 2, dmn 2, mgr 2"
conn %default
# keyexchange=ikev2
conn mikrotik-1
# Try connect on daemon start
auto=start
@rlex
rlex / Kodi.xml
Last active October 10, 2019 09:21
<?xml version="1.0" encoding="utf-8"?>
<Client name="Kodi">
<Identification>
<Header name="User-Agent" substring="Kodi" />
</Identification>
<!-- Author: Plex Inc. -->
<TranscodeTargets>
<VideoProfile protocol="hls" container="mpegts" codec="h264" audioCodec="ac3" context="streaming" />
<MusicProfile container="flac" codec="flac" id="StereoMusicTranscodeProfile" />
<PhotoProfile container="jpeg" />
@rlex
rlex / snippets.txt
Last active January 31, 2019 14:01
snippets
#dump mysql for re-import to slave
mysqldump --opt --single-transaction --comments --hex-blob --dump-date --no-autocommit --master-data --all-databases > master-dump.sql
#Create ISO in MAC OS X from folder
hdiutil makehybrid -iso -joliet -o dell-pkgs.iso tgt
#megacli parse
megacli -PDList -aAll | egrep "Enclosure Device ID:|Slot Number:|Inquiry Data:|Error Count:|state"
@rlex
rlex / rules.v4
Last active January 26, 2017 15:44
Basic iptables rules
# Generated by iptables-save v1.6.0 on Wed Dec 21 18:48:19 2016
*filter
:INPUT ACCEPT [0:0]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [244180:191492827]
-A INPUT -p tcp -m tcp --tcp-flags FIN,SYN,RST,PSH,ACK,URG NONE -m comment --comment "block null packets" -j DROP
-A INPUT -p tcp -m tcp ! --tcp-flags FIN,SYN,RST,ACK SYN -m state --state NEW -m comment --comment "block syn-flood" -j DROP
-A INPUT -p tcp -m tcp --tcp-flags FIN,SYN,RST,PSH,ACK,URG FIN,SYN,RST,PSH,ACK,URG -m comment --comment "block XMAS packets" -j DROP
-A INPUT -p icmp -m comment --comment "accept icmp" -j ACCEPT
-A INPUT -i lo -m comment --comment "accept loopback traffic" -j ACCEPT
@rlex
rlex / gist:58a273e1c9b9859a30138fd7699e3a66
Last active September 16, 2017 17:00
flexget lostfilm config, with transmission-bt and auto renaming
templates:
tvshows:
set:
path: /media/tank-media/soaps/{{series_name|replace(' ', '.')}}/Season.{{series_season}}
transmission:
host: localhost
password: "********"
port: 9091
username: admin
regexp:
@rlex
rlex / gist:7841736d679f0afba0d12d8324c24999
Created April 26, 2016 14:34
IPv6 minimal firewall for mikrotik
add chain=input comment="Router: Allow established connections" connection-state=established
add chain=input comment="Router: Allow related connections" connection-state=related
add chain=input comment="Router: Allow IPv6 ICMP" protocol=icmpv6
add action=drop chain=input comment="Drop everything else"
add chain=forward comment="LAN: Allow established connections" connection-state=established
add chain=forward comment="LAN: Allow related connections" connection-state=related
add chain=forward comment="LAN: Allow IPv6 ICMP" protocol=icmpv6
#example rule for opening port
add chain=forward comment="LAN: Allow SSH" dst-port=22 protocol=tcp
add chain=forward comment="Allow any to internet" out-interface=sixbone
@rlex
rlex / gist:7dab4ad5eec37a67c161
Last active April 16, 2019 13:23
airdrop anything in arma3
_target = player;
_location = getpos _target;
_airdrop = "B_supplyCrate_F" createVehicle _location;
_airdrop setPos [_location select 0, _location select 1, 100];
_airdrop setDir (random 360);
[objnull, _ammodrop] call BIS_fnc_curatorobjectedited;
@rlex
rlex / keybase.md
Created September 28, 2015 15:44
keybase ID

Keybase proof

I hereby claim:

  • I am rlex on github.
  • I am rlex (https://keybase.io/rlex) on keybase.
  • I have a public key whose fingerprint is D25A C794 EEF6 A162 EF04 F80D E7ED 7B6B 453A F56C

To claim this, I am signing this object: