Skip to content

Instantly share code, notes, and snippets.

View samirfor's full-sized avatar

Samir C. Costa samirfor

  • Brazil
  • 10:46 (UTC -03:00)
View GitHub Profile
@victorreyesh
victorreyesh / Aircrack Commands
Created September 12, 2013 03:36
Cracking WPA2 / WEP Wifi / Aircrack 10 seconds guide. For Mac OSX
//Install Macports.
//Install aircrack-ng:
sudo port install aircrack-ng
//Install the latest Xcode, with the Command Line Tools.
//Create the following symlink:
sudo ln -s /System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport /usr/sbin/airport
//Figure out which channel you need to sniff:
sudo airport -s
sudo airport en1 sniff [CHANNEL]
@ismell
ismell / setup-bridge.sh
Last active October 24, 2022 04:37 — forked from anonymous/setup-bridge.sh
Scripts to re-create the docker0 bridge and setup a different ip subnet
#!/bin/bash -e
IFADDR="192.168.3.1/24"
if [[ ! ip link show docker0 ]]; then
ip link add docker0 type bridge
ip addr add "$IFADDR" dev docker0
ip link set docker0 up
iptables -t nat -A POSTROUTING -s "$IFADDR" ! -d "$IFADDR" -j MASQUERADE
fi
@jbinfo
jbinfo / scrapy_csv_exporter.md
Last active March 7, 2022 05:49
How to create a Scrapy CSV Exporter with a custom delimiter and order fields

Create a scrapy exporter on the root of your scrapy project, we suppose the name of your project is my_project, we can name this exporter: my_project_csv_item_exporter.py

from scrapy.conf import settings
from scrapy.contrib.exporter import CsvItemExporter

class MyProjectCsvItemExporter(CsvItemExporter):

    def __init__(self, *args, **kwargs):
 delimiter = settings.get('CSV_DELIMITER', ',')
@dreamcat4
dreamcat4 / zabbix.md
Last active October 31, 2019 10:32
How to Install Zabbix on NAS4Free / FreeNAS / pfSense, with Finch / Qjail-3.5 - http://dreamcat4.github.io/finch/

Zabbix How-To

For notes / info please scroll to bottom of page. Most commands can just be copy-pasted.

Create a new jail

# Finch users should update to get the latest fixes
[ "$(echo "$(finch --shortver) >= 1.25" | bc)" = 1 ] || sudo finch update -y
sudo finch chroot
@thapakazi
thapakazi / proxies
Created August 5, 2014 05:31
15 Free Proxy Servers To Access Blocked Sites http://efytimes.com/e1/fullnews.asp?edid=143084
http://proxyturbo.com/
https://www.hidemyass.com/
http://usawebproxy.com/
http://newipnow.com/
http://proxymad.com/
http://www.ultrabestproxy.com/
http://proxify.com/
http://getprivate.eu/
http://virtual-browser.com/
http://www.proxfree.com/
@sureshnath
sureshnath / regex.email.txt
Created April 10, 2015 09:48
email regex
[A-Za-z0-9._%-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}\b
https://regex101.com/
/[A-Za-z0-9._%-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}\b/
[A-Za-z0-9._%-]+ match a single character present in the list below
Quantifier: + Between one and unlimited times, as many times as possible, giving back as needed [greedy]
A-Z a single character in the range between A and Z (case sensitive)
a-z a single character in the range between a and z (case sensitive)
0-9 a single character in the range between 0 and 9
@6farer
6farer / SSL cert generation.sh
Created March 9, 2016 15:40
Generate SSL Certificates
#! /bin/bash
NAME=$1
if [ -z $NAME ]; then
echo "First parameter should be a name for the output files, e.g. devint.company.local"
exit -1
fi
openssl genrsa -out $NAME.key 2048
openssl req -new -key $NAME.key -out $NAME.csr
@bmaupin
bmaupin / install-oracle-java7-centos.md
Last active March 12, 2019 14:24
Install Oracle Java 7 on CentOS
#!/usr/bin/mongo --quiet
//Load data
print("Loading data..\n");
load('data.js'); //The file from Firebase
//Connect to MongoDB
var db = connect("localhost:27017/MyDatabase");
//Add collections
@tzmartin
tzmartin / m3u8-to-mp4.md
Last active September 15, 2025 01:45
m3u8 stream to mp4 using ffmpeg

1. Copy m3u8 link

Alt text

2. Run command

echo "Enter m3u8 link:";read link;echo "Enter output filename:";read filename;ffmpeg -i "$link" -bsf:a aac_adtstoasc -vcodec copy -c copy -crf 50 $filename.mp4