• Home
  • Downloads
  • EBOOT Fixes
  • Forums
  • New Posts
  • Register
    • Welcome, Register Now! 
    • Premium VIP Membership
    • PS3 Sticky
      • PS3 CFW & MFW
      • PS3 Debug Firmware
      • PS3 Decrypted PSN Links for CFW
      • PS3 Downloads
      • PS3 EBOOT.BIN Original File Links
      • PS3 Firmware
      • PS3 Game Releases List
      • PS3 Guides & Tutorials
      • PS3 Hacking Guides and Tutorials
      • PS3 Hacks & JailBreak
      • PS3 Help & Support
      • PS3 JailBreak Game Compatibility List
      • PS3 JB2 / True Blue (TB) Game Links
      • PS3 multiMAN Updates
      • PS3 Resources
      • PS3 Reviews
      • PS3 Save Files Repository
      • PS3 Themes
      • PS3 Trophies List
      • PS3 Videos
      • PS Vita Trophies List
    • Quick Links
      • Affiliates
      • Contact Us
      • FAQ
      • Post News
      • Site Rules
      • Tag Cloud
 

JaicraB on Cobra USB JIG Protection RTOC Trick for PS3

Category: PS3 Hacks & JailBreak  By: PS3 News - (jaicrab.blogspot.com)
Tags: jaicrab jaicrab ps3 cobra usb ps3 cobra usb ps3 jig protection cobra usb rtoc trick

98w ago - Today Spanish PlayStation 3 developer JaicraB has explained the Cobra USB JIG protection RTOC trick implemented for the PS3 against cloning the device.

To quote, roughly translated: Flynn sent me this text explaining this protective carrying the Cobra, I hope it will open the eyes of those interested in reversing the dumps.

EXPLAIN RTOC COBRA TRICK

The JIG Cobra has several protective measures to ensure that your code could not be used correctly even if your code could be dumped.

This trick RTOC in the registry is the first used for this purpose in addition to hinder analysis.
Registration is initially RTOC stored in the battery to keep the RTOC of lv2 and power it back later:

# =============== S U B R U T I O N E

cobra_syscall_sm_shutdown_hook: # CODE XREF: j syscall_379

. Arg_20 September, 0x20
. Arg_28 September, 0x28
. Arg_30 September, 0x30
. Arg_38 September, 0x38
. Arg_40 September, 0x40

mflr% r0
std% r0, arg_20 (% sp)
std% RTOC, arg_28 (% sp)

At this point we have to explain that the OFFSET DELTA. DELTA OFFSET is a method used in the x86 in its original moments in the creation of computer viruses, to calculate the memory address in which we are in the sea of ​​bytes in RAM.

In the original time a computer virus when I did not know where he was pulled into an executable,
depending on the executable it could be an initial site or another, for it was invented DELTA OFFSET.

DELTA OFFSET can be used in any system, the procedure is:

  • Using the record that indicates the current execution address (or the next depending on the system)
  • Reducing the size of the previous code we use the value obtained from the registry.

Knowing this, and taking for example the x86 processor where the EIP register can not be read directly invented the trick make a call to a "subfunction" which is simply the following line to the call:

call x
x:
pop eax

X86 call instruction saves the top of the stack the address of the next instruction to itself. Thus using pop draw from the top of the stack this value, and stored in eax for example, and having the memory address where we only subtract the above would be missing and we have the exact calculation.

The PowerPC can use this trick using the BL instruction is equivalent (LINK BRANCH), which jumps to a "subfunction" but before you save LR in the record the following address to BL.

_delta_offset bl

_delta_offset:

At this point we see the trick used for the creation of the RTOC of charges at this time. If you look both r0 and RTOC are passed to 0:

li% r0, 0
RTOC li%, 0

Subsequently, given the value 0x11DE0 to RTOC:

RTOC oris%,% RTOC, 1
RTOC ori%,% RTOC, 0x1DE0

A r0 is given the value 0x920:

oris% r0,% r0, 0
ori% r0,% r0, 0x920

R0 is subtracted from the value of RTOC:

SUBF% r0,% r0,% RTOC

Unlike the PowerPC x86 LR register can be read directly with mflr instruction, we put in RTOC the value obtained by the delta offset:

RTOC mflr%

To calculate the delta offset subtract final instructions executed before the delta offset, which were 4, or 16 bytes:

RTOC addi%,% RTOC,-0x10

Finally we add the value of r0 at the end of the delta offset RTOC, storing the result in the RTOC and this already takes RTOC suitable for this hook:

add% RTOC,% RTOC,% r0

It takes having the RTOC stored in the stack 3 arguments that the hook received:

std% r3, arg_30 (% sp)
std% r4, arg_38 (% sp)
std% r5, arg_40 (% sp)

You call the function of the charges where the first argument will check for command 0x8202 (a special command to the usual):

cobra_syscall_sm_shutdown bl

After making the necessary steps as charged, the battery recovers the original RTOC, like the arguments the hook received, it executes the original instruction that was overwritten in the syscall entry 379 (in this case) to have our hook, and call the original syscall lv2:

ld% RTOC, arg_28 (% sp)
ld% r3, arg_30 (% sp)
ld% r4, arg_38 (% sp)
ld% r5, arg_40 (% sp)
mfcr% r12
original_syscall_sm_shutdown bl

Upon returning to retrieve the original LR from the stack and returns to the prompt

ld% r0, arg_20 (% sp)
mtlr% r0
blr

# End of function cobra_syscall_sm_shutdown_hook




Stay tuned for more PS3 Hacks and PS3 CFW news, follow us on Twitter and be sure to drop by the PS3 Hacks and PS3 Custom Firmware Forums for the latest PlayStation 3 scene updates and homebrew releases!

Comments 547 Comments - Go to Forum Thread »

Errors

The following errors occurred with your submission

Okay

Quick Reply Quick Reply

  • Decrease Size
    Increase Size
  • Wrap [QUOTE] tags around selected text
Posting Quick Reply - Please Wait Posting Quick Reply - Please Wait
PS3 News's Avatar
#527 - PS3 News - 8w ago
Reply
Some more updates from deank, as follows:

Download: http://www.sendspace.com/file/x6qtvr (725.67 KB)

• bdRESET6
• gameDATA6
• lastGAME6
• stDISC4

All support: 3.55 CEX/DEX, 4.21 CEX/DEX, 4.30 CEX/DEX, 4.31CEX, 4.40CEX. These four tools are also available in mM's WEB column.

Download: http://www.sendspace.com/file/8qkcl5 (109.04 KB)

Contains modified source and PS3 executable "ps2classics.self". It can be used by any PS3 application to convert a regular disc PS2 ISO to ISO.BIN.ENC.

Can be used as easy as:


char* launchargv[8];
memset(launchargv, 0, sizeof(launchargv));
launchargv[0] = (char*)malloc( 2); strcpy(launchargv[0], "e");
launchargv[1] = (char*)malloc( 4); strcpy(launchargv[1], "cex");
launchargv[2] = (char*)malloc(i3); strcpy(launchargv[2], klc_path );
launchargv[3] = (char*)malloc(i1); strcpy(launchargv[3], iso_path1);
launchargv[4] = (char*)malloc(i2); strcpy(launchargv[4], iso_path2);
launchargv[5] = (char*)malloc(12); strcpy(launchargv[5], "ISO.BIN.ENC");
launchargv[6] = (char*)malloc(37); strcpy(launchargv[6], "2P0001-PS2U10000_00-0000111122223333");
launchargv[7] = NULL;

_Exitspawn(ps2classics, (char* const*)launchargv, NULL, NULL, 0, 1001, SYS_PROCESS_PRIMARY_STACK_SIZE_1M);

Where iso_path1 is the source iso, iso_path2 is the destination encrypted iso.bin.enc and klc_path is the path to the klicense.

I just tested it (launching a regular ISO in mM, it spawns the ps2classics.self and creates the encrypted ISO + a folder structure) - everything seems ok. It needs a nice progress bar, improved I/O by using async read/write and you're good to go. It doesn't support 4GB+ files, but properly adds missing info for CD ISO files.

Basically with mM you can dump your PS2 game disc, load it in the RETRO column, it will convert it to ps2classic in a minute or two and you can load it with ps2-classics-placeholder. I'll release a test mM later.

Showtime 04.03.128 by Andreas Oman is now available (for mM and as standalone in the WEB column).

Download: http://www.sendspace.com/file/wwrggi (5.68 MB) / http://www.sendspace.com/file/q7hgg0 (5.74 MB)

crizford4816's Avatar
#526 - crizford4816 - 8w ago
Reply
Thanks a lot for this post!

adelin07's Avatar
#525 - adelin07 - 8w ago
Reply
can you also put the ps2 iso on the external hdd?

gb14929's Avatar
#524 - gb14929 - 8w ago
Reply
Thanks for the quick reply. Will have a look and report back

moja's Avatar
#523 - moja - 8w ago
Reply
Which RAP did you use to encrypt the iso? Make sure you use 2P0001-PS2U10000_00-0000111122223333 and try again. Use a hex editor on it and look for this in the first 16 bytes- if you see instead something like JP0102-NPJD00015_00-0000000000000000 then you used the wrong one.

Page 5 of 110 «‹123456789›LAST »

Related PS3 News and PS3 CFW Hacks or JailBreak Articles

• Guide to Install multiMAN PS3 Themes via USB from a PKG File
• Simple PS3Updates v1.6 Build 2 Final PS3 Homebrew App Updated
• Video: Super Pixel Jumper v1.2 PS3 Homebrew Game is Released
• Video: Pointman: The Akkadian Wars PS3 Homebrew Game Arrives
• PSPMinis / PS3Minis / Bite v1.5.1 Update for PS3 is Now Released
• PS3 Fan Control Utility v1.7 for PS3 CFW CEX 3.41 to 4.41 Arrives
Affiliates  NewsNow  Privacy  PS3 CFW & MFW  PS3 Hacks & JailBreak  PS3 Reviews  PS3 Videos  © 2013 PlayStation 3 News

PlayStation 3 Links

• Contact Us E-Mail
• PS3 Affiliates
• PS3 CFW & MFW
• PS3 Debug Firmware
• PS3 Decrypted PSN Links for CFW
• PS3 Downloads
• PS3 EBOOT.BIN Original File Links
• PS3 Firmware
• PS3 Game Releases List
• PS3 Guides & Tutorials
• PS3 Hacking Guides and Tutorials
• PS3 Hacks & JailBreak
• PS3 Help & Support
• PS3 JailBreak Game Compatibility List
• PS3 JB2 / True Blue (TB) Game Links
• PS3 multiMAN Updates
• PS3 News Forums
• PS3 News Site FAQ
• PS3 News Site Advertising FAQ
• PS3 News Site Posting FAQ
• PS3 News Site Privacy FAQ
• PS3 News Site Rules
• PS3 News Site Tag Cloud
• PS3 News Site Terms
• PS3 Resources
• PS3 Reviews
• PS3 Save Files Repository
• PS3 Themes
• PS3 Trophies List
• PS3 Videos
• PS Vita Trophies List

PlayStation 3 News Discussions
The Yes/No question thread - 2h ago

windrider42's Avatar
Quote No Are you Depressed?...
By windrider42 with
 2051 Comments »
Final Fantasy XIV: A Realm Reborn on PS3 8/27, Collector's Edition - 3h ago

Brenza's Avatar
Quote and now square is dead to me! ...
By Brenza with
 1 Comment »
The Yes/No question thread - 6h ago

mm4dsc's Avatar
Quote No. Are you sad?...
By mm4dsc with
 2051 Comments »
Video: The Witness on PlayStation 4 / PS4: Creator Conversations - 9h ago

PS3 News's Avatar
Quote Thekla Incorporated President Jonathan Blow shared some video footage today which include conversations with the creators of upcoming title The...
By PS3 News with
 0 Comments »

Latest PlayStation 3 Trophies
Pool Nation: Mega Shot
Pool Nation: Mega Streak
Pool Nation: Super Zen
Pool Nation: Zen

Latest PlayStation Vita Trophies
Men's Room Mayhem: Toilet Trouble
Men's Room Mayhem: Mayhem Master
Men's Room Mayhem: Hygiene Award
Men's Room Mayhem: Sand in the Face

Latest PlayStation 3 Releases
Tom Clancys H A W X EUR PS3-Googlecus - 05-23-2013
Terraria JPN PS3-HR - 05-23-2013
Kamen Rider Battlide War JPN PS3-Caravan - 05-21-2013
Fast And Furious Showdown PS3-DUPLEX - 05-21-2013

Latest PlayStation 3 Themes
Wolverine Origins PS3 Theme - 05-19-2013
Heavy Rain (Official) Dynamic PS3 Theme - 05-09-2013
Wipeout HD Fury Dynamic PS3 Theme - 05-06-2013
Batman Arkham City Dynamic PS3 Theme - 05-04-2013
  • Contact Us
  • -
  • PS3 News