BIOS Debugging the playstation app. with Visual studio 2013 and Visual GDB.

Storm Shadow

Administrator
Staff member
Developer
Ida Pro Expert
Elite Cracker
Maybe there is some clever people that are used to debugg with the VS debugger.
Here is an small guide debugging the psx app ;)

Download visual studio 2013
then visual gdb http://visualgdb.com/download/
Download Strongname helper https://anonfiles.com/file/0d112810bd62abe748957ae142402211
Download app

1) fire up StrongNameHelper4ANDROID

Drag apk into right posision

Kpmxcwj.png



press decompile

2) If we rebuild it the gdb debugger wont debugg since the apk have no debugg flags we have to set that before rebuilding it.


open the decompiled folder an locate the manifest.xml
edit manifest.xml and put in the debug flag :)

Code:
    <application  android:debuggable="true"  /application>


like this.
Code:
    <application android:theme="@style/AppTheme" android:label="@string/app_name" android:icon="@drawable/drawable_launcher" android:name=".CustomApplication" [COLOR=#ff0000]android:debuggable="true"[/COLOR] android:allowBackup="true" android:largeHeap="true">
        <activity android:name=".activity.DebugMainActivity" android:exported="true" android:screenOrientation="portrait" />

3) we have to put gdbserver in the app also.
ill upload it here.
put it in the decompile app.
com.scee.psxandroid\build\apk\lib\armeabi\gdbserver
com.scee.psxandroid\build\apk\lib\mips\gdbserver
com.scee.psxandroid\build\apk\lib\x86\gdbserver
com.scee.psxandroid\build\apk\lib\armeabi-v7a\gdbserver



3) back to the StrongNameHelper4ANDROID
Press sign
The tool creates an com.scee.psxandroid-crk.apk
Now this is important !!!
Drag the crk-apk into the StrongNameHelper4ANDROID
Then press sign for debug.tool creates com.scee.psxandroid-crkSigned.apk

Not sure why but it only gets signed correctly this way.
ill upload my debugg ready with gdbserver APK here also.

4) Fire up visual studio 2013
Remember to install visual gdb first.
WE now have a new tool :)

kvpNrWO.png



5)press debugg an custom APK file

It will ask you to install some tools the debugger need but when your done it would look like this

qP2ZRxC.png



Set the shared library to the decompile folder \lib

6)
Now we can choose wich part we want to start debugg.

I find CompanionUtilConnectingActivity interesting so we try this, i see there is also Second screen :)


XW0XFCL.png


7) press debug and wait for an minut

It woul be here we would get alot off errors about the manifest.xml and gdbserver but we fixed that. ;)

3jlsZoK.png



8)
Connected :)
Hit the Break (pause)
A0FQYxE.png

Now you can set break points and wait to it hits or step 9

9) Use the phone here
connect to console with the app when it does hit break, then set the break point where it connect to console.

then run them to courser.

ITs pretty extended and you can get a ton off info from the debugger

fhCp1tZ.png


Regards :angrybird2.gif:

app_with_debug_manifest_and_gdbserver.rar
https://anonfiles.com/file/05aac478549663ab46ae0b92d305de75
 
Top