Showing posts with label hacking. Show all posts
Showing posts with label hacking. Show all posts

Friday, February 8, 2013

Hacking Android - Part 2

If you have got your phone bricked where your Galaxy Y is getting stuck to the Samsung logo and phone is restarting again and again after displaying Samsung logo after few seconds and your recovery console is also not coming then i would say that you have HARD BRICKED your phone and now its the time you start reading the below steps to UN-BRICK it.

The technique i will be explaining for Unbricking the phone applies to Samsung phones and this method will flash Samsung stock ROM via tool named ODIN. Since ODIN is a windows os based tool, this method will only work in Windows OS.

Pre-requisite before you proceed with the below steps:
  1. Install Samsung Kies from Samsung website or from the cd obtained with your device.
  2. Install Samsung android drivers for your Windows OS
  3. In the device Go to Settings --> Applications --> Developer options and enable USB Debugging by clicking on the checkbox and turning it green
  4. Install ODIN by downloading from link
So, to un-brick your phone follow the below steps:
  1. Download the stock ROM from XDA Forum after checking the kernel version from
    Settings --> About phone --> Kernel version
  2. Extract the downloaded file into a folder on your Windows PC.
  3. If you are running Kies, Stop it and kill all its processes.
  4. If you are an Android developer or have Android SDK installed on your Windows PC, then stop all ADB (Android debug bridge) processes.
  5. Shutdown your device
  6. Now, by pressing Volume Down+Home Key, press Power key. This will boot the device in Download mode.
  7. When in download mode follow the instructions to continue and this will show the download screen (You can notice ODIN written on top left of phone screen in Galaxy Y).
  8. Connect your phone to the PC and start ODIN. 
  9. The ID:Com section in ODIN will turn yellow. If it doesn't then the device drivers are not installed properly.
  10. If you notice the yellow color in above step then click on PDA and browse to the folder created in Step 2 above.
  11. In the PDA section, select the file whose name has "PDA" in it. Click on Phone and select the file whose name has either PHONE or MODEM in it. Click on CSC and select the file whose name has CSC in it.
  12. Do leave PIT and BOOT empty
  13. Now, click on the Start button and this will start the flashing process of the Stock ROM.
  14. When the Flashing process is complete, you can notice PASS written in ODIN on a green background in your PC.
This will make your device just like new. If you are still stuck on the Samsung logo after following above steps then most probably you have selected the wrong ROM. So, download the correct ROM and run the steps mentioned again.

I hope this helps un-bricking your device.

Stay Good and Stay Lovely !! 

Hacking Android - Part 1


Its been a long time i wrote anything on my blog and now seems to be the time to put my guts out with the knowledge i have been gathering lately and i hope to revise it and others enjoy and use it.

To begin with i would like to say that this post is the result of my curiosity and research hobby which i have in my blood and if anything goes wrong because of anyone using it, then its not my fault. Though i will try that even a novice can do the steps i am gonna mention and stay away from trouble...but hey...we are humans and we are made to commit mistakes...so stay focused when trying to attempt such things and take responsibility for the mistakes (please don't take it personally as its just a weird thought which came in my mind which is always true).

So, here are the topics i am gonna discuss and hope this is good for the Part 1:

  • What is Root access in Android and why do we need it?
  • What are the steps to Root Android device ?
  • What is Bricking/Un-bricking of device ?
  • How to perform Backup of Android device to avoid Soft Bricking and overcoming Soft bricking by restoring the backup ?
  • Lets change the ROM to have what you love

Note that the steps mentioned in the below topics are for Samsung Galaxy Y and may differ for different devices but more or less will remain the same.

What is Root access in Android and why do we need it?

As Wikipedia puts it:

Android rooting is the process of allowing users of smartphones, tablets and other devices running the Android  mobile operating system to attain privileged control (known as "root access") within Android's subsystem.
As Android was derived from the Linux kernel, rooting an Android device is similar in practice to accessing administrative permissions on Linux or any other Unix-like operating system such as FreeBSD or OS X.

In a nutshell, by getting root access to an Android device you have access to the contents or files of Android operating system and you can affect its behavior and outlook the way you want and can even change the device's operating system to the customized version you want which are loosely called ROMs as android device use Flash memory instead of Read Only Memory (ROM) for storing operating system contents.

What are the steps to Root Android device ?

There are many steps to root android device some manually some using recovery/bootloader console but the best way i found is using update.zip which is described below:
  1. In the device Go to Settings --> Applications --> Developer options and enable USB Debugging by clicking on the checkbox and turning it green  
  2. Attach your device to your PC/Mac/Linux box (if you are using windows then do remember to install device drivers provided by your device manufacturer which is using Samsung Kies software in our case) and ensure that USB debugging icon is displayed in the device which tells that device is in debugging mode.
  3. Download update.zip 
  4. Copy the downloaded zip file to sdcard
  5. Disconnect your device and shut it down.
  6. Now, by pressing Volume Up key and Home key, press Power key. This will boot your device in a recovery mode
  7. When in recovery mode, press Volume Up and Volume Down keys to navigate in the menu and use Home key to select the option. Now select second option in the menu and navigate to the zip file copied in step 4 above. Select the zip file.
  8. After selecting the zip file it will take 10-15 seconds or more depending upon the condition of device hardware and the recovery menu will get displayed after the completion of process.
  9. Select first option to reboot the device as now the rooting process is complete. The zip file also contains Superuser.apk app to check if the device is rooted or not. So, move to the next step to check the same
  10. After your device boots normally go to the applications menu and check if Superuser application's presence. Open the application and it will ask for Superuser permission. Allow the permission and this proves that your device is rooted. Now you can install Titanium Backup from Android Store to perform backup and other root operations from which i am going to describe below.
What is Bricking/Un-bricking of device ?

As Wikipedia put it:

When used in reference to consumer electronics, a "brick" describes an electronic device such as a smart phone, game console, router, or tablet computer that owing to a serious misconfiguration, corrupted firmware or a hardware problem, can no longer function. The term derives from the vaguely cuboid shape of many electronic devices (and their detachable power supplies) and the suggestion that the device can only function as a large, heavy object.

In a nutshell, Bricking means that your device is of no use and you can use is as a paper weight and nothing can be done with it. On the contrary, Un-bricking refers to returning the device to its previous state (usable state).

There are two types of bricking Soft Bricking and Hard Bricking. If your device is Soft bricked then it means you have corrupted the system files of android os which is rendering the device useless. In Hard bricking the partitions of device gets corrupted rendering it useless. Soft bricking can be overcome by taking backup of device and then restoring it using a suitable tool. Hard bricking can be overcome by replacing the complete ROM of the device which then restores the partitions along with files.

I will cover details of how to overcome Hard bricking of the device in Part 2 so let us now concentrate on this Part 1 first.

How to perform Backup of Android device to avoid Soft Bricking and overcoming Soft bricking by restoring the backup?

This is not a sure shot way to prevent your device and can only prevent in case your recovery/bootloader device partition is not overwritten (Soft bricked). The method i will be explaining is using ClockWorkMod(CWM) and is based on recovery partition. Normally, people replaces their recovery partition with CWM but in the below steps we will not do that instead their is a file which runs CWM without replacing your recovery partition with it.

So, enough saying and here are the steps:
  1. Download ClockWorkMod zip file from link CWM.zip.
  2. Copy the downloaded zip file to sdcard
  3. Disconnect your device and shut it down.
  4. Now, by pressing Volume Up key and Home key, press Power key. This will boot your device in a recovery mode
  5. When in recovery mode, press Volume Up and Volume Down keys to navigate in the menu and use Home key to select the option. Now select second option in the menu and navigate to the zip file copied in step 4 above. Select the zip file.
  6. This will now show the CWM options and now select the appropriate option to backup your phone.
  7. Select the option for complete backup and this will backup your whole device to sdcard including partitions, data, etc. 
If you some how have corrupted the system files of your android device, you can select restore option and this will show you the option showing date on which backup was taken. Now you can select that option and device will return to its original state.

Lets change the ROM to have what you love

If you have followed the above steps to Backup/Restore your device then proceed ahead and do the greatest thing to your device - Giving it a new look and feel by installing new Android OS
  1. Backup your device
  2. Go to  The Unlocker - Galaxy Y ROMs site and download the ROM zip file 
  3. Copy the downloaded zip file to sdcard
  4. Disconnect your device and shut it down.
  5. Now, by pressing Volume Up key and Home key, press Power key. This will boot your device in a recovery mode
  6. When in recovery mode, press Volume Up and Volume Down keys to navigate in the menu and use Home key to select the option. Now select second option in the menu and navigate to the zip file copied in step 4 above. Select the zip file.
  7. After the selection, installation of ROM will start and when it completes reboot your device and when it starts you will have a device in your hand with everything new.
In case your device becomes slow go to the same site and get another ROM which better runs on your device. Some ROMs require CWM-Merruk which you can download from link  CWM-Merruk_Recovery_v1.0.8.5

If you have any queries or the links don't work for you then do let me know and i will update them.

So, this is all for this post, be happy, stay lovely and lets make this world a better place to live for each other :)

Thursday, July 5, 2012

Android can be hijacked

From the yesteryears i remember that Windows can be hijacked and is virus prone and now a days even Apple removed a line that "Mac is not virus prone" as was attacked by a trojan. The latest in the trend is Android Application Stack which is now proved to be hijacked....checkout this link:
Researchers create "clickjack rootkit" for Android that hijacks apps

How to install node using Brew

This article talks about some simple steps to follow to install node using Brew . Though there are many other ways to do it but the method ...