Skip to content

xerpi/GhidraVitaLoader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 

Repository files navigation

GhidraVitaLoader

VitaLoader script for Ghidra

Installation

  1. Download this script
  2. Download the JAR of the yamlbeans library
  3. Open Ghidra and add the JAR path to Ghidra's Edit -> Plugin Path...
  4. Add the script directory to Window -> Script manager -> Script Directories button in the top right

Usage

  1. Load your favorite ELF
  2. (Optionally parse the vitasdk headers, see below)
  3. Go to Window -> Script manager (or green play button)
  4. Navigate to the Vita folder and run VitaLoader.java
  5. Select the vitasdk's db.yml

Parsing vitasdk headers

To take full advantage of this script, I recommend parsing the vitasdk headers before running it:

1. Generating a Ghidra-parsable headers

  1. $ arm-vita-eabi-gcc -P -E $VITASDK/arm-vita-eabi/include/vitasdk.h -D"__attribute__(x)=" -D"__extension__(x)=" -Drestrict= -D__restrict__= > vitasdk_header.h
    • Use vitasdkkern.h for the kernel headers
  2. Now open vitasdk_header.h and remove the typedef unsigned int wchar_t; (line 3)
    • If generating the kernel header, remove all the inline macros (ksceKernelCpu*Context, ksceKernelCpuUnrestrictedMemcpy)
    • If generating the kernel header, change SceKernelProcessInfo's unk[0xE8 / 4 - 6] to unk[0x34]

2. Parsing the header

  1. Open Ghidra and go to File -> Parse C Source... and select vitasdk_header.h

About

VitaLoader script for Ghidra

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages