Skip to content

Instantly share code, notes, and snippets.

@judotens
judotens / tanyasimi.py
Last active December 29, 2015 17:09
SimSimi CLI chat
# url sniffed frm mitmproxy
# ref: http://blog.philippheckel.com/2013/07/01/how-to-use-mitmproxy-to-read-and-modify-https-traffic-of-your-phone/
import sys, urllib, urllib2, json, random
def tanya_simi(teks):
acak = str(int(random.uniform(100000,300000)))
data = {'av': 5.2, 'ft': 1.0, 'lc': 'id', 'os': 'i', 'req': teks, 'tz': "Asia/Jakarta", 'uid': acak}
url = "http://app.simsimi.com/app/aicr/request.p?" + urllib.urlencode(data)
@judotens
judotens / cari.c
Last active December 29, 2015 16:29
Find an insensitive string in big text file. faster than cat and grep. supports multiple keywords, separated by space. no regex support.
/* cari string di file, case insensitive
support multiple keyword, tapi bukan regex. diisah by spasi aja
find an insensitive string in big raw text. faster than cat and grep.
supports multiple keywords, separated by space. no regex support.
@judotens
./cari bigfile.txt keyword
@judotens
judotens / generate.py
Last active September 10, 2020 11:21
Twitter Bulk Tokens Generator for PIN-based auth Twitter app
# this tools will help you to generate a twitter tokens for bulk twitter accounts using PIN-based authorization twitter app.
# eg: Twitter for Iphone
# todo: save your bulk twitter accounts to pasukan.txt, line separated each account.
# format: username:password
# - Revealing Twitter for iPhone consumer key & secret - Ref: http://seriot.ch/abusing_twitter_api.php#3
import os
dirname, filename = os.path.split(os.path.abspath(__file__))
@judotens
judotens / kaskus.py
Last active August 23, 2017 14:36
Kaskus search using official API - just for fun
# PS:
# - Extract your own kaskus oauth consumer_key & consumer_secret frm native app. Ref: http://seriot.ch/abusing_twitter_api.php#3
# - No public doc found, but here i attach an api sample sniffed from mitmproxy
import urllib, urllib2
import time
import oauth.oauth as oauth
import string
import random
import sys, json
@judotens
judotens / acak.sh
Last active December 29, 2015 01:49
Randomize the input lines using bash
#!/bin/bash
# randomize the input lines
# cat artikel.txt | ./acak.sh
awk 'BEGIN{srand() }
{ lines[++d]=$0 }
END{
while (1){
if (e==d) {break}
@judotens
judotens / ubigram.sh
Last active December 29, 2015 01:49
Find top unigram & bigram using bash
#!/bin/bash
# cat artikel.txt | ./ubigram.sh
# results sorted by frequences
# freq, keyword
cat "$@" |
tr -cs "a-zA-Z0-9" '\012' | tr '[:upper:]' '[:lower:]' |
{
old="aaa."
#!/usr/bin/env python
# -*- coding: utf-8 -*-
""" """
import json
from urllib2 import urlopen
from lxml.html import document_fromstring
from lxml.cssselect import CSSSelector as cs