Take the 2-minute tour ×
Android Enthusiasts Stack Exchange is a question and answer site for enthusiasts and power users of the Android operating system. It's 100% free, no registration required.

Is it possible to edit values in memory used by an app? I would assume this requires root.

share|improve this question
    
what do you need to do this for? I would assume that trying to do this would be very difficult due to android's sandboxing structure. –  user15294 May 22 '12 at 20:21
    
Which type of values you are talking about? –  Sachin Shekhar May 23 '12 at 4:48
    
@SachinShekhar like counters? for example a button press counter or something. –  Eshwar Jun 24 '12 at 21:07
add comment

2 Answers

That may be possible without root if the app you want to manipulate allows debugging via Android Debug Bridge (ADB). If an app can be connected to an debugger is specified in it's AndroidManifest.xml in the android:debuggable entry.

If the app is enabled for debugging you can enable the USB debugging mode on your device and connect to it via adb. Then you can connect an standard Java debugger to the app and inspect/modify variables.

share|improve this answer
    
Should try it with a dummy app to see! –  Eshwar Jun 24 '12 at 21:06
add comment

In Android the system memory is just another file, so with the appropriate rights it's just as simple as vi -b /dev/mem (device node may vary for your system). The result of changing a running system's memory could be one of a nop, a touch of an electric fence, a system crash or a simple nuke resulting in an unusable device.

share|improve this answer
    
how can you get an unusable device? I'd imagine the running apps would be in a different device from the actual ROM stuff? –  Eshwar Jun 24 '12 at 21:06
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.