CodeWarrior CWComUtil.

Discussion in 'Nintendo Game Development' started by kennypecheur, Nov 2, 2016.

  1. kennypecheur

    kennypecheur Site Supporter 2016

    Joined:
    May 19, 2014
    Messages:
    1,101
    Likes Received:
    337
    Hello all,

    Does anyone have access to the Code Warrior Communication Utility (CWComUtil) for Gamecube ?

    I have a CodeWarrior build but the communication utility was an addon.

    Thank you :)
     
    Last edited: Nov 2, 2016
  2. cmonkey

    cmonkey Rising Member

    Joined:
    Mar 29, 2012
    Messages:
    62
    Likes Received:
    20
    CWComUtil 4.0.1.1 is a part of the CodeWarrior for Nintendo Gamecube release 2.7 installer. I have that installer and you're welcome to it but be warned that CWComUtil is a licensed product and unless you have a valid license key you'll be presented with a message box upon launch stating "Unable to use CWComUtil. It is licensed and a valid license key is not found. Please contact license@metrowerks.com to obtain a valid license key."

    Of course if you have a valid license key then you're good to go, otherwise some x86 reversing skills and an hour or two in IDA Pro might prove productive.... (not that I'd ever advocate such a thing)
     
    kennypecheur likes this.
  3. kennypecheur

    kennypecheur Site Supporter 2016

    Joined:
    May 19, 2014
    Messages:
    1,101
    Likes Received:
    337
    Hello CMonkey,

    Thank you very much for your answer. I have a valid licence key for the version I have (version 1.1). I would be glad if you could upload your 2.6 build !

    Thanks a lot !
     
  4. cmonkey

    cmonkey Rising Member

    Joined:
    Mar 29, 2012
    Messages:
    62
    Likes Received:
    20
  5. kennypecheur

    kennypecheur Site Supporter 2016

    Joined:
    May 19, 2014
    Messages:
    1,101
    Likes Received:
    337
  6. kennypecheur

    kennypecheur Site Supporter 2016

    Joined:
    May 19, 2014
    Messages:
    1,101
    Likes Received:
    337
    Hello CCmonkey,

    Sadly, I don't have a correct licence for it. And I am currently failing when trying to crack it. As my asm skills aren't very good, it takes me time to understand some expressions.

    Anyway, thanks a lot for the upload. I will keep you updated if I succeed in my cracking project.

    NB: I have also asked to the company which is now managing the CodeWarrior Software if they can add the gamecube version to their legacy page (old softwares available with an evaluation licence). My request is being discussed.
     
  7. cmonkey

    cmonkey Rising Member

    Joined:
    Mar 29, 2012
    Messages:
    62
    Likes Received:
    20
    Assuming you've done a full install to c:\Program Files then do the following :-

    1) copy license.dat from c:\Program Files\Metrowerks\CodeWarrior\PowerPC_EABI_Tools\Command_Line_Tools to c:\Program Files\Metrowerks\CodeWarrior (overwrite the license.dat that already exists in the destination folder)
    2) change the 3 bytes in CWComUtil.exe at offset $a087 from values of 0f 84 bb to new values of e9 bc 00 using your favourite hex editor (this changes a conditional jump to an absolute jump)

    That should get past any license issues. I haven't tested program functionality beyond launching as I don't currently have my DDH setup and ready to use but hopefully everything will work OK after this.

    Let us all know how you get on.
     
    kennypecheur and Borman like this.
  8. kennypecheur

    kennypecheur Site Supporter 2016

    Joined:
    May 19, 2014
    Messages:
    1,101
    Likes Received:
    337
    Thank you very much for this !

    I feel glad to be able to launch the software now (didn't try to use the transfer function now), but I also feel a bit dumb in failing to crack it by myself. When you will have time, can you explain me how you have identified the Jump that you have changed ? That was my first attempt to crack something and I am pretty sure I was close to find the crack. I will still try to understand how you have identified this Jump.

    Thanks a lot anyway. You are a genius !

    Edit : I was indeed close to find this Jump. After dealing with breakpoints to find the license.dat use. But I was blocked at "0040A07B . E8 A25A0000 CALL <JMP.&LMGR326B.#190>" as I wasn't understanding this line.
     
    Last edited: Nov 4, 2016
  9. cmonkey

    cmonkey Rising Member

    Joined:
    Mar 29, 2012
    Messages:
    62
    Likes Received:
    20
    Looks like you were indeed very close to figuring this out yourself.

    Are you using IDA Pro? I find that ollydbg is usually better for runtime analysis and IDA Pro is better at static analysis.

    As you can see from the ollydbg screen shot below, the call that you couldn't quite figure out was to the lp_checkout function in the FLEXLM dll (lmgr326b.dll). This is the routine that verifies whether the license is good or not. It's usually just a case of patching the code after that call to continue with program execution, irrespective of the result of the call to lp_checkout. This doesn't always work, but I've had reasonable success with this approach in the past.

    Capture.PNG

    Armed with this new found knowledge you should be able to patch the license check of the compiler/linker to give you a fully working CodeWarrior for Gamecube installation.

    Good luck!
     
    kennypecheur likes this.
  10. kennypecheur

    kennypecheur Site Supporter 2016

    Joined:
    May 19, 2014
    Messages:
    1,101
    Likes Received:
    337
    Thanks again for your help. And thank for these very helpful informations !

    Doing a patches installation package is indeed an interesting option for people who wants to use CodeWarriors 2.7 without any troubles.

    Thanks again !
     
sonicdude10
Draft saved Draft deleted
Insert every image as a...
  1.  0%

Share This Page