Skip to content

Instantly share code, notes, and snippets.

View LeetCodes's full-sized avatar
🎱
Choppin' caine rain, hail, sleet, or snow

LeetCodes

🎱
Choppin' caine rain, hail, sleet, or snow
View GitHub Profile
#!/usr/bin/python
# Connects to servers vulnerable to CVE-2014-0160 and looks for cookies, specifically user sessions.
# Michael Davis (mike.philip.davis@gmail.com)
# Based almost entirely on the quick and dirty demonstration of CVE-2014-0160 by Jared Stafford (jspenguin@jspenguin.org)
# The author disclaims copyright to this source code.
import select
@LeetCodes
LeetCodes / Facebook-brute-force.py
Created April 8, 2017 06:35 — forked from HossamYousef/Facebook-brute-force.py
This simple script to penetrate accounts Facebook brute-force
#!/usr/bin/python
#Install SleekXMPP & xmpppy Modules
#This program is not for children -(18)
#This program is only for educational purposes only.
#Don't Attack people facebook account's it's illegal !
#If you want to HaCk into someone's account, you must have the permission of the user.
#usage:Facebook-brute-force.py [wordlist file]
#Coded By Hossam Youssef <hossam.mox@gmail.com> ^_^
@LeetCodes
LeetCodes / archive-all-facebook-messages.js
Created May 2, 2017 07:24 — forked from tedmiston/archive-all-facebook-messages.js
Archive all of the messages in your Facebook Messages Inbox
function archive_all(testOnly) {
var someMessages, archiveButton;
if (testOnly === "undefined") { testOnly = false; }
someMessages = $("li._k- span.accessible_elem");
console.log("Found", someMessages.length, "messages to archive in your inbox.");
archiveButton = null;
someMessages.each(function () {
function SearchEmail() {
var mySheet = SpreadsheetApp.getActiveSpreadsheet().getActiveSheet();
var EmailName = Browser.inputBox("Search", "Type from:email@address.cz", Browser.Buttons.OK_CANCEL);
var maxthreads = 250;
var searchedThreads= GmailApp.search("from:(<" + EmailName + ">)", 0, maxthreads);
var regExp = new RegExp(".*<" + EmailName + ">$");
var counter = 1;
for(var i in searchedThreads){
var messages = searchedThreads[i].getMessages();
@LeetCodes
LeetCodes / netiquette.r
Created December 25, 2017 22:20 — forked from simecek/netiquette.r
Email Netiquette
count.google.hits <- function(query) {
# call Google Search and extract the number of hits
url <- paste('http://www.google.com/search?q=', query, sep="")
tmp <- readLines(url, warn=FALSE)
writeLines(tmp, "c:\\temp\\pokus.html")
pattern <- ".*<div id=resultStats>[A-Za-z ]*([0-9 ,]*) results<nobr> \\([0-9.]* seconds\\).*"
count.line <- grep(pattern,tmp)[1]
hits <- sub(pattern, "\\1", tmp[[count.line]])
@LeetCodes
LeetCodes / plotting.R
Created December 25, 2017 22:26 — forked from simecek/plotting.R
Make the plot of data mined by Google Apps Script
data <- read.csv("http://docs.google.com/spreadsheet/pub?hl=en_US&hl=en_US&key=0AnhE_6FIbbVWdFNxeS1ESWtvSUk5WE5KcnBwVWVqckE&output=csv", header=FALSE, skip=1, as.is=TRUE)
sent <- data.frame(Time=strptime(data[,1], "%H:%M:%S"))
library(ggplot2)
theme_update(panel.background = theme_rect(fill = "grey90", colour = "black"))
xstart <- strptime("01:00:00", "%H:%M:%S")
xend <- strptime("23:00:00", "%H:%M:%S")
ggplot(sent, aes(Time)) + geom_density(fill="grey50", adjust=0.5) + xlim(xstart, xend)
@LeetCodes
LeetCodes / facebook_friendship1.r
Created December 25, 2017 22:26 — forked from simecek/facebook_friendship1.r
Facebook Friendship Graph
# the code uses 'facebook' function from the previous gist (https://gist.github.com/1634662) or
# see the original http://romainfrancois.blog.free.fr/index.php?post/2012/01/15/Crawling-facebook-with-R
# scrape the list of friends
friends <- facebook( path="me/friends" , access_token=access_token)
# extract Facebook IDs
friends.id <- sapply(friends$data, function(x) x$id)
# extract names
friends.name <- sapply(friends$data, function(x) iconv(x$name,"UTF-8","ASCII//TRANSLIT"))
# short names to initials
@LeetCodes
LeetCodes / facebook_friendship2.r
Created December 25, 2017 22:26 — forked from simecek/facebook_friendship2.r
Facebook Friendship Graph Continued
require(pixmap)
# download small profile picture of each friend
dir.create("photos")
for (i in 1:length(friends.id))
download.file(paste("http://graph.facebook.com", friends.id[i], "picture", sep="/"),
destfile=paste("photos/",friends.id[i],".jpg",sep=""))
system('for i in `ls photos/*.jpg`; do j=${i%.*}; convert $j.jpg $j.pnm; done', wait=TRUE)
# customized node plotting function
@LeetCodes
LeetCodes / facebook_mining.r
Created December 25, 2017 22:26 — forked from simecek/facebook_mining.r
Facebook Mining
# go to 'https://developers.facebook.com/tools/explorer' to get your access token
access_token <- "******************* INPUT YOUR ACCESS TOKEN ******************************"
require(RCurl)
require(rjson)
# Facebook json function copied from original (Romain Francois) post
facebook <- function( path = "me", access_token, options){
if( !missing(options) ){
options <- sprintf( "?%s", paste( names(options), "=", unlist(options), collapse = "&", sep = "" ) )
@LeetCodes
LeetCodes / wormwormworm.txt
Created December 27, 2017 08:39 — forked from phwd/wormwormworm.txt
Digging into a Facebook Worm
Digging into a Facebook Worm
http://i.imgur.com/zc2A8vJ.png
Facebook worms are interesting
The following was a link that was shared to me (You probably shouldn't click it)
https://www.facebook.com/l.php?u=https%3A%2F%2Fcdn.fbsbx.com%2Fhphotos-xpa1%2Fv%2Ft59.2708-21%2F12447002_1746605272238633_1642381431_n.html%2FV1DE0-9682.html%3Foh%3D8a665fb34c8793a92fd02cceb31d4b01%26oe%3D5718116B%26dl%3D1&h=cAQHPcYE7