public
Last active

The case of the incredible disappearing file ...

  • Download Gist
gistfile1.txt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
GingerBreak got me a shell with uid 0. Now what?
 
/proc/mounts says
/dev/block/mmcblk0p25 /system ext4 ro,relatime,barrier=1,data=ordered 0 0
 
# mount -o remount,rw /dev/block/mmcblk0p25 /system
# cat /system/bin/sh > /system/rootsh
# chmod 4711 /system/rootsh
# ls -l /system/rootsh
-rws--x--x root shell 82840 2011-05-12 15:08 rootsh
# sync;sync
# sync;sync
# ls -l /system/rootsh
-rws--x--x root shell 82840 2011-05-12 15:08 rootsh
# mount -o remount,rw /dev/block/mmcblk0p25 /system
# ls -l /system/rootsh
-rws--x--x root shell 82840 2011-05-12 15:08 rootsh
# mount -o remount,ro /dev/block/mmcblk0p25 /system
# ls -l /system/rootsh
/system/rootsh: No such file or directory
 
It's gone!?

If anyone should stumble across this and wonder what the problem was: the hardware device is write-protected but not in a way that linux can detect

http://ww.telent.net/2011/5/15/desire_s_don_t

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.