Join Us and become a Member for a Verified Badge to access private areas with the latest PS4 PKGs.
Status
Not open for further replies.
Since the days of PS3 Linux PlayStation sceners have been Upgrading PS4 Hard Drives, Installing Linux on PS4 and working on various Linux Homebrew Projects including @zecoxao's (Twitter) latest guide on Mounting a PlayStation 4 (PS4) HDD in Linux on a PC for those interested. šŸ§

This comes following his previous Tutorial to Download PS4 PKGs on the Latest PlayStation 4 Firmware, check it out below from PSDevWiki.com: Mounting HDD in Linux
  • Unlike the PS3, where every part of perconsole security (including the HDD) is dictated by the eid_root_key, the PS4 has two perconsole keys for the HDD, one is handled by SAMU (we cannot obtain this key atm) and the other is handled by the South Bridge / AEOLIA / BELIZE (which we can obtain)
  • Here I describe the steps to mount your hdd on the pc using the cryptmount utility on Linux
Setup
  • EAP HDD Key (check in your kernel dump and in magic.h kern_off_eap_hdd_key offset)
  • Linux Distro (i'm using xubuntu live for this)
  • cmtab file
Step by Step Guide (CUH-1000 and CUH-1100)
  • cmtab file can be as follows (example for xubuntu live)
Code:
# /etc/cryptmount/cmtab - encrypted filesystem information for cryptmount
# try 'man 8 cryptmount' or 'man 5 cmtab' for more details
user {
    dev=/dev/sda27
    dir=/home/xubuntu/Desktop/user
    flags=user,nofsck

    fstype=ufs mountoptions=ro,noatime,noexec,ufstype=ufs2

    cipher=aes-xts-plain64
    keyfile=/home/xubuntu/Desktop/eap.bin
    keyformat=raw
}
  • if your key in the kernel dump looks like this:
Code:
D2 60 86 B3 8B D2 D3 5A EC 76 DB DE 50 30 00 40
15 D6 AE 04 44 3D A8 59 4B 03 3C 1F 0A DD FA 6B
  • then the correct key will be:
Code:
40 00 30 50 DE DB 76 EC 5A D3 D2 8B B3 86 60 D2
6B FA DD 0A 1F 3C 03 4B 59 A8 3D 44 04 AE D6 15
  • after the key file eap.bin is created and the user folder is also created in the Desktop, install cryptmount
Code:
sudo apt install cryptmount
  • and then mount your partition
Code:
sudo cryptmount user
== Step by Step Guide (CUH-1200 and above)
  • In this case the cmtab will have a small change
Code:
# /etc/cryptmount/cmtab - encrypted filesystem information for cryptmount
# try 'man 8 cryptmount' or 'man 5 cmtab' for more details
user {
    dev=/dev/sda27
    dir=/home/xubuntu/Desktop/user
    flags=user,nofsck

    fstype=ufs mountoptions=ro,noatime,noexec,ufstype=ufs2

    cipher=aes-xts-plain64
    ivoffset=111669149696

    keyfile=/home/xubuntu/Desktop/eap.bin
    keyformat=raw
}
  • where iv offset is a number of partition - 1 << 32
  • here it'll be (27-1)<<32=111669149696
Also available is a PS4 HDD Decryption Helper collection of bash scripts by @Berion to automate PS4 HDD decryption, mounting and unmounting.

Download: PS4_HDD_Decryption_Helper_(2022-10-31).7z (4.36 KB)

Spoiler: Depreciated

Below are further details and the changelogs from Berion, to quote: PS4 HDD Decryption Helper - Bunch of bash scripts for automate PS4 HDD decryption, mounting and unmounting.

Big thanks for @rj017 for painful QA phase and for @Thefirebeast for EAP and samples from his console!

Bunch of bash scripts for automate PS4 HDD decryption, mounting and unmounting.
  1. Unpack them in Your home dir, don't change any folder or file names.
  2. Drop EAP Key into /keys dir as "eap_key.bin".
  3. Drop ufs (optionally) kernel module in apps dir.
  4. Run mounter script.
  5. Have fun under /storage (root privileges needed).
  6. Run umounter script.
And from @gmipf on HDD Keys Generating Scripts HERE, to quote:

Wouldn't it be a better idea to create a tutorial for a live distribution with more recent Linux kernel? My Kernel is 5.3.0.

Or a ready to go virtual machine package?

Have attached RW ufs.ko module for Kernel 5.3.0-24-generic. Build it on Ubuntu 19.10 Cinnamon Remix. It's compatible with the live environment iso "cinnamonremix-19.10-all.20191204.iso".

Download: ufs.ko_5.3.0-24-generic.zip (779.5 KB)

PS4 HDD Decryption Helper (2022-10-31)
  • added PS4 HDD Mounter Micro which will mount only user partition (consider "full Mounter" as unsafe because using untested file systems settings for FAT family partitions)
  • moved readme to docs dir
Spoiler: Related Tweets

Cheers to @HydrogenNGU via Twitter for the heads up on this! :beer:
Mounting a PlayStation 4 (PS4) HDD in Linux on PC Guide by Zecoxao.jpg
 

Comments

Sergi8

Member
Contributor
Verified
If only this came up a few things ago I would have used to copy some games from my 4TB external HDD to the 2TB one.
Thanks anyway, great work indeed.
 
Status
Not open for further replies.
Top