Hacking How to compile a payload to bin format

  • Thread starter Thread starter Muxi
  • Start date Start date
  • Views Views 9,649
  • Replies Replies 33
  • Likes Likes 1
@stooged Thanks for your effort. Now I finally managed it. The key to success was, to keep the size of the sql file low and with preloaded HEN.
Big thanks also to @MostlyUnharmful for the support.
 
Last edited by Muxi,
I get this error:

/mnt/c/Cache-Install-10/tool /mnt/c/Cache-Install-10
gcc -o bin2js bin2js.c
/mnt/c/Cache-Install-10
/mnt/c/Cache-Install-10/Cache_Install /mnt/c/Cache-Install-10
gcc -c -o build/patch.o source/patch.c -I/root/PS4-SDK/libPS4/include -I. -Iinclude -Os -std=gnu11 -ffunction-sections -fdata-sections -fno-builtin -nostartfiles -nostdlib -Wall -masm=intel -march=btver2 -mtune=btver2 -m64 -mabi=sysv -mcmodel=small -fpie
gcc -c -o build/main.o source/main.c -I/root/PS4-SDK/libPS4/include -I. -Iinclude -Os -std=gnu11 -ffunction-sections -fdata-sections -fno-builtin -nostartfiles -nostdlib -Wall -masm=intel -march=btver2 -mtune=btver2 -m64 -mabi=sysv -mcmodel=small -fpie
gcc /root/PS4-SDK/libPS4/crt0.s build/*.o -o temp.t -I/root/PS4-SDK/libPS4/include -I. -Iinclude -Os -std=gnu11 -ffunction-sections -fdata-sections -fno-builtin -nostartfiles -nostdlib -Wall -masm=intel -march=btver2 -mtune=btver2 -m64 -mabi=sysv -mcmodel=small -fpie -L/root/PS4-SDK/libPS4 -L. -Llib -Xlinker -T /root/PS4-SDK/libPS4/linker.x -Wl,--build-id=none -lPS4
/usr/bin/ld: cannot find -lPS4
collect2: error: ld returned 1 exit status
Makefile:22: recipe for target 'Cache_Install.bin' failed
make: *** [Cache_Install.bin] Error 1
Drücken Sie eine beliebige Taste . . .

Thx ;)
 
Yes! (Windows 10 / Ubuntu)
With Linux this error comes:

sandmann@sandmann-VirtualBox:~/Schreibtisch/Cache-Install-10$ ./build.sh
~/Schreibtisch/Cache-Install-10/tool ~/Schreibtisch/Cache-Install-10
make: Für das Ziel „all“ ist nichts zu tun.
~/Schreibtisch/Cache-Install-10
~/Schreibtisch/Cache-Install-10/Cache_Install ~/Schreibtisch/Cache-Install-10
gcc /home/sandmann/PS4-SDK/libPS4/crt0.s build/*.o -o temp.t -I/home/sandmann/PS4-SDK/libPS4/include -I. -Iinclude -Os -std=gnu11 -ffunction-sections -fdata-sections -fno-builtin -nostartfiles -nostdlib -Wall -masm=intel -march=btver2 -mtune=btver2 -m64 -mabi=sysv -mcmodel=small -fpie -L/home/sandmann/PS4-SDK/libPS4 -L. -Llib -Xlinker -T /home/sandmann/PS4-SDK/libPS4/linker.x -Wl,--build-id=none -lPS4
build/main.o: In Funktion »writeCacheDB«:
main.c:(.text.writeCacheDB+0x23): Warnung: undefinierter Verweis auf »base64_decode«
main.c:(.text.writeCacheDB+0x7e): Warnung: undefinierter Verweis auf »systemMessage«
main.c:(.text.writeCacheDB+0x97): Warnung: undefinierter Verweis auf »openBrowser«
main.c:(.text.writeCacheDB+0xa7): Warnung: undefinierter Verweis auf »systemMessage«
build/main.o: In Funktion »_main«:
main.c:(.text._main+0x27): Warnung: undefinierter Verweis auf »initSysUtil«
main.c:(.text._main+0x35): Warnung: undefinierter Verweis auf »dir_exists«
main.c:(.text._main+0xa0): Warnung: undefinierter Verweis auf »file_exists«
main.c:(.text._main+0xb2): Warnung: undefinierter Verweis auf »systemMessage«
main.c:(.text._main+0xe0): Warnung: undefinierter Verweis auf »file_exists«
main.c:(.text._main+0xf9): Warnung: undefinierter Verweis auf »systemMessage«
main.c:(.text._main+0x10e): Warnung: undefinierter Verweis auf »copy_File«
main.c:(.text._main+0x11c): Warnung: undefinierter Verweis auf »systemMessage«
main.c:(.text._main+0x125): Warnung: undefinierter Verweis auf »systemMessage«
/home/sandmann/PS4-SDK/libPS4/libPS4.a(syscall.o): In Funktion »syscall_macro«:
(.text+0x5): relocation truncated to fit: R_X86_64_PC32 against `.sc_rop'
collect2: error: ld returned 1 exit status
Makefile:22: recipe for target 'Cache_Install.bin' failed
make: *** [Cache_Install.bin] Error 1

hmmm
 
Ahh THX ;) it Works!

upload_2018-7-10_13-13-50.png
 
@stooged I had to set up my Windows PC again, and did not want to set up Ubuntu via VM this time. I follow your instructions here now, but do not get over this step:
when you get to the part that says to "pull the SDK" use the sdk from my repo because it has been modified for my payloads.
use this to pull the SDK
git clone https://github.com/stooged/ps4-payload-sdk
I get this error here running the command. Can you tell me why that could be?

gnutls_handshake() failed: The TLS connection was non-properly terminated.
DESKTOP-4G4GMGA_ ~.png
 
Last edited by Muxi,
It could be you are missing the GNU TLS library (something like libgnutls*something*.deb) or the OpenSSL TLS version (something like libgnutls-openssl*something*.deb).

You could also disable the git SSL certificate verification with "git config --global http.sslVerify false" but keep in mind what are you doing (disabling protection against MITM attacks against git).
 
@MostlyUnharmful Thanks for your hints ........... has already passed over a year, since the last correspondence:)

I found the mistake. It was due to Kaspersky IS. However, I still have a problem, because now this error message appears when trying to compile using win-make.bat:
DESKTOP-4G4GMGA_ ~.png

Edit:
Is it possible that an SDK may not be compatible with a current version of Ubuntu? After all, the SDK by @stooged is almost a year old.
 
Last edited by Muxi,
Thanks for the feedback. I have already done this change (hope it was the right one)
2019-07-27 11_11_05-Greenshot.png

However, there is still an error message.
2019-07-27 23_00_08-C__Windows_system32_cmd.exe.png

Edit:
I have overlooked some steps in the setup. Everything works now. Sorry for the trouble.
 
Last edited by Muxi,

Site & Scene News

Popular threads in this forum