T-Mobile US MDA - Java? - 8125, K-JAM, P4300, MDA Vario General

Anyone know what files/have the files necessary to put the Java Virtual Machine back on the T-Mobile (US) MDA Load?
Its on the SDA but not the MDA - and this sucks!

Genesis3 said:
Anyone know what files/have the files necessary to put the Java Virtual Machine back on the T-Mobile (US) MDA Load?
Its on the SDA but not the MDA - and this sucks!
Click to expand...
Click to collapse
Just a simple .lnk file to \Windows\Jmm.exe. AFAIK, the intent Midlet manager comes with all HTC Wizards pre-installed; it's only the link file that is missing.
You can also download this link file from http://www.winmobiletech.com/sekalaiset/MIDlet Manager.lnk

Nope - the FILE is missing! And copying it over from a SDA (which has it) doesn't help - it won't run (may be different link options or somesuch)
It appears that T-Mobile whacked it out of their ROMs! Anyone got a copy of that I can try dropping in there?

Genesis3 said:
Nope - the FILE is missing! And copying it over from a SDA (which has it) doesn't help - it won't run (may be different link options or somesuch)
It appears that T-Mobile whacked it out of their ROMs! Anyone got a copy of that I can try dropping in there?
Click to expand...
Click to collapse
http://www.winmobiletech.com/sekalaiset/jmm.zip - give this a try. Unpack it to \Windows. Let me know if it works/doesn't work.

WORKS, kinda.
It comes up but won't load the GLM software. Not quite sure why.... looking at that now.
Update - says it failed to run image \windows\target.img
Looks like there's one file missing in that archive.

Genesis3 said:
WORKS, kinda.
It comes up but won't load the GLM software. Not quite sure why.... looking at that now.
Update - says it failed to run image \windows\target.img
Looks like there's one file missing in that archive.
Click to expand...
Click to collapse
Give it a try: http://www.winmobiletech.com/sekalaiset/target.img.zip
Put the ZIP file itself (don't decompress it) into \Windows.

Well it comes up now - GLM fails to load claiming the JAR file is invalid, but the Java Virtual Machine starts without error.

Genesis3 said:
Well it comes up now - GLM fails to load claiming the JAR file is invalid, but the Java Virtual Machine starts without error.
Click to expand...
Click to collapse
What JAR file is that? Midlet manager is only able to run non-device-specific midlets - that is, NOT Nokia/Sony-Ericsson etc. specific ones. With other stuff, it'll report about invalid JAR files.

Menneisyys said:
Genesis3 said:
Well it comes up now - GLM fails to load claiming the JAR file is invalid, but the Java Virtual Machine starts without error.
Click to expand...
Click to collapse
What JAR file is that? Midlet manager is only able to run non-device-specific midlets - that is, NOT Nokia/Sony-Ericsson etc. specific ones. With other stuff, it'll report about invalid JAR files.
Click to expand...
Click to collapse
Its the Google Local Generic MIDP 2.0 version off www.google.com/glm.
Runs on the SDA, but refuses to load on the MDA. The VM IS running now though.... thanks.

Genesis3 said:
Menneisyys said:
Genesis3 said:
Well it comes up now - GLM fails to load claiming the JAR file is invalid, but the Java Virtual Machine starts without error.
Click to expand...
Click to collapse
What JAR file is that? Midlet manager is only able to run non-device-specific midlets - that is, NOT Nokia/Sony-Ericsson etc. specific ones. With other stuff, it'll report about invalid JAR files.
Click to expand...
Click to collapse
Its the Google Local Generic MIDP 2.0 version off www.google.com/glm.
Runs on the SDA, but refuses to load on the MDA. The VM IS running now though.... thanks.
Click to expand...
Click to collapse
OIC... the generic MIDP2 version works great on my Qtek 1.6.7.1 ROM.

Leave it to T-Mobile to cripple the damn thing....

I've also been playing around with getting java on the T-Mob US MDA. I didn't have the benefit of an SDA, but on the ftp site I found various extended roms for the Wizard. Specifically on the 'O2 Mini Asia Exteded Rom...' I found a .cab that installs the jvm/midlet manager.
The program itself runs just fine, and installs and downloads the .jar specified in any jad file I execute. The problem comes when I try to run a program from within the Midlet Manager. What I get is:
Error
Failed to run the MIDlet
This happens with google, Opera and another program I want to run. Is this the same error you are getting?
The O2 Mini is a Wizard - correct? Could there be something else in the ROM that needs to be installed?
Anyone have any ideas?

No, I'm getting an error trying to LOAD the GLM site from www.google.com/glm.
It appears to load, goes through all the motions, and then complains about an invalid JAR file.
I don't have any JARs handy I can load off a local SD card to see if it will work with those. I'll look around for some....

So you are getting an error already when trying to download the app from Google? I don't know how familiar you are with J2ME apps, but they typically consists of 2 components. A .jad file which is a simple text file that describes some properties of the app and a link to the actual app.
The point I am at I can successfully go to the Google/glm site and select the Generic Advanced app, agree to terms and then I click to download. Once I do that PocketIE asks if I want to save or run the .jad file. I then select to run it, and it kicks off the midlet manager. Then the midlet manager will download the .jar file and it is available in the manager with icon and everything. Once I click on the Google or Opera icon to launch the J2ME app I get the error I described.
If I understood correctly it seems you haven't gotten this far yet?

Correct. I cannot load the application - it is transferred but the JMM application refuses to install it.
I suspect a registry difference here - and if we find it, we may have a working solution.

Well, I would have thought that the .cab I got from the other extended rom would create all the appropriate registry keys to run the program. At least jmm works and downloads the jar.
I have no idea why it won't run them though. I also used LokiWiz to unlock the device, and after that I had to reinstall the jmm cab because the device complained that jmm.exe was not signed/authorized.
I see that some keys have been created in HKLM\Software\Tao\. I have attached them here.

It may be a file association for the .JAR type....

After looking around a little in the registry, I can see that there are a lot of keys created. I think it will be difficult for you to manually copy everything from the SDA. There are entries for the right extensions, but there is one more interesting one that I'd like to see what is in the SDA (or any Wizard with Java capabilities) \HKCR\CEJavaVM. On my device it is empty.

ecf said:
After looking around a little in the registry, I can see that there are a lot of keys created. I think it will be difficult for you to manually copy everything from the SDA. There are entries for the right extensions, but there is one more interesting one that I'd like to see what is in the SDA (or any Wizard with Java capabilities) \HKCR\CEJavaVM. On my device it is empty.
Click to expand...
Click to collapse
That key is not there at all on the SDA nor on my MDA.
There are several file associations ("Jarfile" and "Jadfile") all of which look ok......

Works on a Cingular 8125
Do it works on a Cingular 8125, however, how do you get to Midlets after you install them?
EDIT: I just need a .lnk file to the JMM.
Danny

Related

Java Midlet Question

I really want to use a name picker (randomly picks a name from a pre-defined list)
Google reveals this java version is exactly what I need for a desktop
Is there any way I can use it on the pocket pc (does not work in midlet manager)
http://www.davebsoft.com/jaws/apps/namepicker.jnlp
You normally need a jar version of the program to work with midlet manager - best you do a search for a jar version.
The author kindly sent me his JAR file for this app. I have placed it onto my device but cannot open it
Is it incompatable or am I making a silly mistake
Thanks
Hays
Is that the zip he sent you or did you send you a jar file? Even when i rename it namepicker.jar it wont install, i am sure there is something wrong with the file.
Is that the zip he sent you or did he send you a jar file? Even when i rename it namepicker.jar it wont install, i am sure there is something wrong with the file.
he sent this text in his email
The jar file is here, but it probably isn't set up the way you need it:
http://davebsoft.com/jaws/apps/lib/namepicker.jar
I downloaded it but can't get it working
yep - still says invalid - contact the author again he must have a valid jar that works
will do
thanks for your help
the author replied
"invalid" in what context? It's valid in the context in which you've been
running it on your PC or whatever. Maybe it lacks a manifest file or
something. There are free tool to extract and rebuild jar files.
The message it gives is that it has an 'invalid java application desciptor' i.e. the jad part of the jar is wrong.
just a guess, but its probably made for jave for desktops, not j2me.
OMG. The Java that is written is for PC (or eqv) Java not for Java for phone (eg. midlet). That's why it doesn't run. Midlet is a very small subset of the real Java, the code is different, and there isn't much function in midlet version of java, and it is a pain to program in midlet-java (whatever you call it). Hence the JAR is not working. Try running it on your PC, it will work.
No, you can't extract it and run it on your midlet-enabled phone. No, even if you have the source, you can't do that either, unless you translate the code manually. I don't think there is a converter for that matter, especially it involved GUI.
That explains it
Anyone up for the challenge of writing a good pocket pc version ??
Hays
Try this one...
This is an OSS JVM that's meant to be J2SE compliant so it might just run. Try your luck.

cert questions

1) exe/dll's have to be all signed correct? I assume other files don't (bmp, xml, htm, etc)
2) are files in rom signed or are they assumed to be valid since they are in rom?
2a) if rom files are signed is this preserved on extract via viewimgfs?
3) Can you determine if a file is signed and which cert it was signed with?
4) I see cab's such as the recent Palm Messaging cab that don't appear to install a cert, yet the program runs fine once installed. How is this possible?
hannip said:
1) exe/dll's have to be all signed correct? I assume other files don't (bmp, xml, htm, etc)
Click to expand...
Click to collapse
.EXE, .DLL, .CPL and .CAB files must be signed.
hannip said:
2) are files in rom signed or are they assumed to be valid since they are in rom?
Click to expand...
Click to collapse
All cabs in Extended rom must be signed.
hannip said:
2a) if rom files are signed is this preserved on extract via viewimgfs?
Click to expand...
Click to collapse
Don't know... :O
hannip said:
3) Can you determine if a file is signed and which cert it was signed with?
Click to expand...
Click to collapse
Yes. If you look in the "Digital signatures" tab in the files properties you will see both who signed it and who it was signed for.
hannip said:
4) I see cab's such as the recent Palm Messaging cab that don't appear to install a cert, yet the program runs fine once installed. How is this possible?
Click to expand...
Click to collapse
On a Pocket PC running WM 5.0 a notification will appear that says that the cab comes from a untrusted source. If the user accepts this, the application will run as if it were signed.
Øystein
t0flus said:
On a Pocket PC running WM 5.0 a notification will appear that says that the cab comes from a untrusted source. If the user accepts this, the application will run as if it were signed.
Øystein
Click to expand...
Click to collapse
Thanks for the quick reply!
I'm real curious on the last point. So you are saying as long as a program is installed via a cab and the user accepted the warning that program will run without warning once installed. Correct? So is there some db that contains each file installed and whether they can be run without warning even though it's unsigned?
I must be missing something. I've created a cab file of the HTC StreamingMedia player and it runs fine as long as I have the policies set not warn. But when I change the policies back to normal I can't install the cab even though I've accepted the warning. The installation seems to be going ok, but then I get the following error.
"Installation was unsuccessful. The program or setting cannot be installed because it is not digitally signed with a trusted certificate."
Nice of it to tell me which file or setting it is bombing on. ugh
Ideas?
So the answer to 2a is yes and no. Files are extracted signed, but module-files are not.
hannip said:
So the answer to 2a is yes and no. Files are extracted signed, but module-files are not.
Click to expand...
Click to collapse
Probably they are signed with a cert you don't have on your phone??
If you have the cert, then try extracting them using TestWM5.exe or grab_it! and see if it makes any difference.
pof said:
Probably they are signed with a cert you don't have on your phone??
If you have the cert, then try extracting them using TestWM5.exe or grab_it! and see if it makes any difference.
Click to expand...
Click to collapse
All of the files in my cab are appropriately signed and the certificate is installed on my device. The cab just wont install. I even signed the cab and it still complains, but at least there is no warning at the start.
The files themselves are good. I have tested them on my device by installing them manually and importing the reg file. It's just a cab install issue of some sort.
Is there a way to turn on cab tracing?
One thing:
What device exactly is it?
I know on Smartphones (like the Tornado) even signed cabs are not allowed to install certificates unless the cab is signed by 'privileged' certificate.
The error you described is often caused by cab no being able to change registry setting or install certificates.
It's a PPC device (treo 700wx). The cab does not install a cert. The cert is already on the device. I've been able to install certs via cab before on this device however. The cab does make several reg changes. I'm thinking it's gotta be one of those settings.
Is there no trace or logging available for cab installs? This one is huge and would take some time to narrow down which setting it is having a problem with.
Unfortunately I don't know of any loggers for cab installation.
You should look for reg settings in HKEY_LOCAL_MACHINE and anything having to do with security, certifications, system settings (I know its a wide range, sorry). Those are usually restricted and can only be changed by privileged cabs.
I suppose the only solution is to comment them all and then return them one by one to see which is problematic.
you might want to check out:
http://msdn.microsoft.com/library/d...gpoliciesoncabfileinstallationprocessozup.asp
even though there is wce51 in the url, it's under softphone2003. Security on a single tier sp2003 is very simular to pocket pc 2005. I suspect most (or all) of it will applies.
I had tried to install a file in the top directory and it failed, but worked for another directory. Perhaps I made a mistake, but it made me wonder if somethings aren't allowed. (putting files in \, changing certain registry settings, etc)
hannip said:
It's a PPC device (treo 700wx). The cab does not install a cert. The cert is already on the device. I've been able to install certs via cab before on this device however. The cab does make several reg changes. I'm thinking it's gotta be one of those settings.
Click to expand...
Click to collapse
What kind of cert have you installed? Are you sure it is a application certificate and not a ROOT cert?
If you upload the cab file I can take a look at it...
Øystein

VipMSCRexe is a utility to run MortScript without Assigning .mscr to MortScript.exe

VipMSCRexe is a utility to run MortScript without Assigning .mscr extension to MortScriptexe.
How to Use it
Rename exe to your scriptname.exe e.g if your script name is sashimi.mscr then rename this VipMSCRexe.exe to sashimi.exe
This utility will first find MortScript.exe in Current directory and Sub directory under it
if not found then look in \Program Files and sub directory
if still not found then look in \Storage Card\Program Files
if still not found then look in root directory.
Once MortScript.exe found then find <exename>.mscr in same above fashion.
Once script found then execute command like MortScript.exe scriptname.mscr parameter1 parameter2 etc.
Advantages of this Utility
you can have only one installation of MortScript and may be all your script in one another folder.
Now if you want to call any of script copy this exe and rename to your scriptname.exe
Basically if you have script name sashimi.mscr then copy this exe and rename to sashimi.exe and put it in any folder
Root or storage card any where and run exe will execute your script you do not give any path or tell where it located etc.
To me MortScript.exe only support one parameter where as this Utility support multiple parameter
Version 1.0
Initial version
Version 2.0
Make changes so that Arguments are passed properly
Performance Improvement using config file
Version 3.0
Performance and Special Chars Handling in Mortscript's Path
Version 5.0
Performance improvement Using registry values
Version 6.0
Fixed Langeuge issue
Fixed Error Handling Routine
Very interesting. I have several uses for this right away so I'll download it and test. Many thanks for sharing!
Just want to note that although this is a fine tool (I'm using it for SASHIMI), if you DON'T need to pass parameters to your program you would be better off to use a renamed Autorun.exe file from the MortScript download.
The only reason I say this is becuase of the delay that VipMSCRexe has when locating/opening the script.
But, if you need to pass parameters to your script, this is the tool!
Don't work in my PC "System.ArgumentException: URI formats are not supported"
In smartphone with WM6.1 is the same error
hurtavy said:
Don't work in my PC "System.ArgumentException: URI formats are not supported"
In smartphone with WM6.1 is the same error
Click to expand...
Click to collapse
Don't work in my PC "System.ArgumentException: URI formats are not supported"
Only Supported for Pocket PC's not for desktops
In smartphone with WM6.1 is the same error
SmartPhone and WM6.1 I am not sure you have smartphone or Wm6.1
Can you please let me know which phone you have?
I have Motorola MPx200 with WM6.1 Standart Russian.
Error message is in russian language. Translate:
System.ArgumentException: It is not possible to show the error message, since it is impossible to find its containing additional assembling of resources in System.IOath:InternalCombine()...
Do you have .netCf 3.0 installed?
hurtavy said:
I have Motorola MPx200 with WM6.1 Standart Russian.
Error message is in russian language. Translate:
System.ArgumentException: It is not possible to show the error message, since it is impossible to find its containing additional assembling of resources in System.IOath:InternalCombine()...
Click to expand...
Click to collapse
Do you have .netCf 3.0 installed?
v3patel said:
Do you have .netCf 3.0 installed?
Click to expand...
Click to collapse
No. Only .NETcf 2.0
I do not have smartphone to test but can you try changing your languegue to english and then try. I just want to see is it languege problem or somthing else.
Posted Version 6.0
Posted Version 6.0
v3patel said:
Posted Version 6.0
Click to expand...
Click to collapse
You Can make it run in Win-CE ?
Great App.
But I have a same problem, it delayed 3-4 second before running a script.
Hope that you can fix it!
Thank u.
blue1311218 said:
Great App.
But I have a same problem, it delayed 3-4 second before running a script.
Hope that you can fix it!
Thank u.
Click to expand...
Click to collapse
Me too, I know that you may have heavy code inside to do like path checking & etc., may be another version with just execute the .mscr in same folder as MortScript.exe & <VipMSCRexe>.exe ?
Many thanks for this great app.,
Thanks, that the thing I need~~~
Hope you can me help
Hello,
i have program in the startup of my WinCE 5 Falk GPS. After the Hard Reset, has a Error. And the text:
Script \Temp\0084Script.mscr not found, waiting for existence (Storage Card not Initializied?)... After 3 sec. my falk stops.
Sry for bad english, im german.....

[REF][TUT] Improve program launch times - UPX Squeezer BATCH

this is an old trick that was/is used for older devices to fit WinMo 6 on them
but a side effect is faster application load times
i figured i'd try it on the Blackstone and difference is noticeable
HTCAlbum loads in about 1 Second, before it took about 4
so i'm sharing this with anyone who is interested
The batch file is kept as simple as possible for everyone's ease of use
but this is pretty advanced tweaking, so all common warnings apply
and/or
if you are not comfortable with getting files from/to your PocketPC
and/or
can't figure out how to extract this zip and read the "read me.txt"
and/or
don't know what “any key” is DO NOT TRY THIS!
(read the forum and the wiki a bit more, and you'll gain the knowledge)
Version History:
v 1.0 - initial release
v 1.1 - no icon compression switch added to the batch, for more general compatibility
v alt - here geistteufel has released a new branch of the batch file,
this version uses a different method for packing files and may achieve better compression.
At the same time problems have been reported in the past with this method so all usual warnings apply.
a short list of EXEs that i have UPXed and work well for me
AdobeReaderLE.exe
ASyncKiller.exe
BCR.exe
Camera.exe
FMRadio.exe
GoogleMaps.exe
HTCAlbum.exe
iContact.exe
KeePassPPC.exe
kinoma.exe
Labyrinth.exe
LongPressEndKeyApp.exe
MP3Trimmer.exe
MusicID.exe
Opera9.exe
OperaL.exe
QuickGPS.exe
RSSHub.exe
s2p.exe
s2u2 Settings.exe
s2v.exe
StreamingPlayer.exe
TomTom Navigator.exe
USBtoPC.exe
WMRegOptimizer.exe
YotaCenter.exe
YotaCenterUpdater.exe
YouTube.exe
and here is a list of things NOT to compress
manila.exe
cprog.exe
thumbCal.exe
calculator.exe
wt5jetpr.exe
any DLL
Please share your findings so that others can benefit from it
(SEARCH this thread for your application name or EXE filename)
note: you'll have to repeat this proses after upgrading your applications
big thanks to;
edhaas - for the original simple to use batch file More info in this THREAD
UPX Team - a lot of technical info on the Website
kwbr - for a great ROM
and especially XDA-DEVELOPERS as a whole
Wow!
Thank you for sharing this. This also works great for S2U2. I noticed a difference in loading times. Also applied to this to iGO.exe and a few other .exe's
Thanks again for posting this.
Looks like hdtweak.exe and fdotfreds taskmanger have this done already.
Thanks for your explanations, everything worked fine till I had to copy files to Windows directory: access denied. What must I do to be able to copy files to WD?
Thanks and kind regards,
very very good! I try with commManager, yota contact, opera 9, resco explorer 2008 .....there is a time reduction in all! best performance in yota contacts from 5 seconds to 1 second
If this works so well I wonder why Microsoft doesn't implement it?
upx also works for large dll files!
andrewk21 said:
Thanks for your explanations, everything worked fine till I had to copy files to Windows directory: access denied. What must I do to be able to copy files to WD?
Thanks and kind regards,
Click to expand...
Click to collapse
for that you'll need something along the lines of total commander
i wish we could do this with manilia.exe but i tried and failed, it doesnt load, so had to restor it
I'm also having problem removing protection from some of the files :/
I tried to change properties via Resco Explorer, but without succes. As soon as I remove "Read only" attribute and click "Done", the attribute restores itself and I can't overwrite the new files.
I managed to update Yota; GoogleMaps, Nimbuzz and Opera - all load with visible speed improvement.
Tried Total Commander but can't get it to see my phone
It isnt working on the diamond saber. Icontacts and Yota center went well
WAUWW!!! my TomTom is now really fast!!
Thanks for sharing this app.
andrewk21 said:
Thanks for your explanations, everything worked fine till I had to copy files to Windows directory: access denied. What must I do to be able to copy files to WD?
Thanks and kind regards,
Click to expand...
Click to collapse
some files maybe in memory (used by your phone)
a trick to try is
connect with ActiveSync to the phone
browse into windows folder
rename the file you will be replacing (ex. HTCAlbum.exe to HTCAlbum.old.exe)
copy the UPXed version
restart device and test
if everything works delete the ".old." file
usrname said:
upx also works for large dll files!
Click to expand...
Click to collapse
it does indeed,
but in my experience with less noticeable results and much less reliability
so i didn't mention this
please list any DLLs that you have UPXed with us so that we can all benefit
elite-fusion said:
i wish we could do this with manilia.exe but i tried and failed, it doesnt load, so had to restor it
Click to expand...
Click to collapse
i had the same experience, but
best performance boost for Manila/TouchFLO is CFC compression of images (more info here)
Sir.B, can you please share info on how to remove attributes from System files? Tried through Resco File Explorer, but no effect - still can't overwrite old files, always having errors :/
Wow. This is great!
TomTom V7.450 From 6 down to 3 sec to splash screen!
I wonder if it would be possible to do this to all the exe and dll before cooking.
PocketPlayer also works. But most startup time is the drive scanning.
Google Maps also works, but it started up fast anyway. (also the 2 largest dll worked)
gpsVP works, but was already subsecond.
CommManager.exe worked, was a little faster
AdobeReaderLE worked but despite being a huge program, loaded fast to begin with.
PowerPoint worked but also despite being a huge program, loaded fast to begin with.
CorePlayer reports 'Already compressed'
G-Alarm reports '.net not (yet) supported), except for 2 dll's, they worked.
cybermaus said:
Wow. This is great!
I wonder if it would be possible to do this to all the exe and dll before cooking.
Click to expand...
Click to collapse
yea true, that would be GREAT!!!!! the roms would be superfast!!!!
thanks much for this tutorial. i upxed most of the exes u had listed and MAN, it really changed launch times in the apps. htcalbum is awesome and even s2p is launching faster
Rozenthal said:
Sir.B, can you please share info on how to remove attributes from System files? Tried through Resco File Explorer, but no effect - still can't overwrite old files, always having errors :/
Click to expand...
Click to collapse
i recommendation you read the WIKI and FORUMS,
this is a general question that has been addressed better than i can many times
cybermaus said:
...I wonder if it would be possible to do this to all the exe and dll before cooking.
Click to expand...
Click to collapse
elite-fusion said:
yea true, that would be GREAT!!!!! the roms would be superfast!!!!
Click to expand...
Click to collapse
to replace all EXE & DLL files would be quite an undertaking
because it's such a trial and error process (manila.exe and mode9.dll don't like to be UPX-ed, maybe many more)
and benifits are only noticeble for the largest of files
never hurts to talk with your chefs
Sir.B said:
some files maybe in memory (used by your phone)
a trick to try is
connect with ActiveSync to the phone
browse into windows folder
rename the file you will be replacing (ex. HTCAlbum.exe to HTCAlbum.old.exe)
copy the UPXed version
restart device and test
if everything works delete the ".old." file
Click to expand...
Click to collapse
No matter what software I tried, I just can't get to replace the protected system files.
I tried Resco, I removed the attributes but they're back as soon as I click "Done".
I also tried your described method, but clicking on "rename" in Windows Explorer via ActiveSync - nothing happens. The files seem to be permanently locked
Sir.B said:
i recommendation you read the WIKI and FORUMS,
this is a general question that has been addressed better than i can many times
Click to expand...
Click to collapse
Actually, I have been searching all over forums, but none of the methods described worked for me. Most recommend using Resco or Total Commander, both of which don't work for me. All of the files that have "ROM" attribute simply refuse to be modified in any way.
Thats right. You cannot modify ROM files. You cannot even copy ROM files. You'd have to dump the ROM to PC, which is not trivial. Best to only use this on post-installed programs that are not in ROM.
Interesting: Coreplayer gives me an "already packed by UPX"
Seems they learned this trick before.....

[DEV-UTIL][19.03.2009]DriverWiz - Make signed CABs from driver DLLs that work

Intro
Lately I've seen a lot of posts by people who are trying to replace WM internal or driver DLLs, either for hacking/testing or to release. Aside from the possibility they are just doing something that won't work in the first place, I've seen failure a lot of times because files aren't properly signed, or if they are, the certificate in question not being in the right certificate stores for it to have any effect. On some ROMs it will still work due to patched NK.EXE, on others it won't, its just not very reliable.
So, I present you with the correct way of doing this by means of a small tool that will do this for you: DriverWiz. It will take care of most of the stuff, and leave you room for additions. You will however still need some basic knowledge of the command line, if you don't have that, you have no business doing anything like this anyways.
Background
I use this technique myself all the time. When just hacking away, replacing system DLLs to trace calls, etc. It's also the same method used for the HTC-CA drivers and the ICS installer. This method works on most stock ROMs as well, though not on all of them (in rare cases some security policies are set that will prevent CAB installation)
Usage
It's fairly simple to use. Just extract the attached zip file somewhere, open the command promt, and change directory to where the zip was extracted. That's the installation part.
Now when you actually want to build a CAB file from a DLL, you use the DriverWiz.bat file.
DriverWiz v1.0 by Chainfire
Usage:
DriverWiz.bat "Description" "CAB-name" "DLL-name-1" ["DLL-name-2" ...]
Examples:
DriverWiz.bat "New DDI" "ddi.cab" "ddi.dll"
DriverWiz.bat "Two DDIs" "ddi.cab" "ddi.dll" "ddiaux.dll"
Click to expand...
Click to collapse
DriverWiz will take care of signing the DLLs, inserting the certificate, etc, and you will end up with a proper CAB file for this kind of thing. Just copy it to your device and run it to install.
#1. You need to put the DLL files in the same folder as DriverWiz. Do NOT include paths in your DLL names
#2. Include the quotes in the command like in the examples!
#3. The first time you install a CAB made by DriverWiz, your phone may still give you a certificate warning. This is normal, don't worry about it.
Caveats
While this method has never failed me yet, it is possible that some files cannot be replaced this way. Just a disclaimer
Modifying
DriverWiz bases the inf file it will create to build a CAB from on DriverWiz.tpl. If you need to add registry entries to your CAB file, modify DriverWiz.tpl before you run the batch file. You can make other modifications too, add files, etc. Just take care that you don't break it
You can use your own certificates as well, instead of the supplied "Dummy" certificate that comes with DriverWiz. The files you will want to modify/replace are DriverWiz.pfx (used for signing) and DriverWiz.xml (used for injecting the certificate). I'll see about finding a reference for how to do that online and posting the URL here (someday). Creating a new certificate from scratch can be a frustrating effort - make sure you got openssl handy
Changelog
19.03.2009 - 1.1 - Added some file exists checks and attribute changes
Download
Temporary PlaceHolder for more Info.
Whoo this is hot from the plate, looks very promising!
Driver testing withoud cooking! joohie
Well if you replace the wrong files you're still going to need to hard-reset to boot. I advise KITL before you do
Works flawless. You tha man.
Didn't work for me trying to cab up No2Chems Fast Charge battery divers.
ruskiyab said:
Didn't work for me trying to cab up No2Chems Fast Charge battery divers.
Click to expand...
Click to collapse
What exactly happened? Attach the files and such
It made the cab and all, but when I went to install it, the unsigned error message popped up just like when I tried it with WinCE cab manager.
That is perfectly normal behavior. The first time you install a CAB with this certificate it will not know the certificate. However, once you install it, the certificate will be injected in the right place, and the files signed with the certificate (the driver files in the CAB) will be allowed to be run.
It won't happen the second time you try it
So if I try to install it again, it'll work fine? is there aa soft reset required in between? I can replace these drivers manually by renaming the old ones and copying them over, the whole reason I want a cab in the first place is to facilitate the UC process when I flash a different rom
ruskiyab said:
So if I try to install it again, it'll work fine? is there aa soft reset required in between? I can replace these drivers manually by renaming the old ones and copying them over, the whole reason I want a cab in the first place is to facilitate the UC process when I flash a different rom
Click to expand...
Click to collapse
Actually it should just work the first time. Just click OK when the certificate error appears.
Nice nice nice work!
error message
I got error messages when creating a cab from a rilphone.dll. Does it mean anything, or are these errors okay? I guess I'm specifically wondering about the SignTool error. If its okay, then my cab should be good.
EDIT: I think I found the problem. I didn't have UAC disabled in Windows 7. I tried it again, after disabling it, and it works fine now. Thanks for the easy to use tool!
syntax for registry entries?
I was experimenting with creating a cab for the Rogers folks who need a specific rilphone for their Caller ID to work. There are some registry entries associated with this feature, so I was wondering what the correct syntax is for putting the registry entries into the .tpl file. I've tried a few different ways, and I've either a gotten a 'Registry section is empty' message, or a 'Registry has an unsupported registry root key' error. I'm sure its something really simple I'm missing, so any help you can offer is appreciated.
It just seems that since we now have this easy method to sign these dlls, so that they can be used in any ROM, that the Rogers people shouldn't have to jump through so many hoops to get it to work.
EDIT: Nevermind. I'm an idiot that didn't do a little bit of research. All is well now.
Excellent stuff, Microsoft may rant about this way of distributing signtool and cabwiz though.
Chainfire said:
You can use your own certificates as well, instead of the supplied "Dummy" certificate that comes with DriverWiz. The files you will want to modify/replace are DriverWiz.pfx (used for signing) and DriverWiz.xml (used for injecting the certificate). I'll see about finding a reference for how to do that online and posting the URL here (someday). Creating a new certificate from scratch can be a frustrating effort - make sure you got openssl handy
Click to expand...
Click to collapse
Here's an intro to cert stores for WM:
http://msdn.microsoft.com/en-us/library/aa458010.aspx
pfx generation is a 2-liner with openssl:
# Generate a CA certificate
openssl req -new -nodes -x509 -days 9999 -newkey rsa:1024 -md5 -keyout cert.key -out cert.cer -subj "/CN=DriverWiz"
# Convert to pkcs12/PFX format
openssl pkcs12 -export -in cert.cer -out cert.pfx -inkey cert.key
got error messages under vista sp2, any ideas?
I also get an error saying that the latest version of CAPICOM.dll is missing. The ones I can find for download from the internet are version 2.0.0, and the tool requires 2.1.0.1 or later.
Does anyone have the needed version of the dll?
EDIT: Found it, 2.1.0.2 version of the dll is in the attachment.
Time Saver !
Many thanks; DriverWiz /w the CAPICOM.DLL saved me about an hour of troubleshooting.
Cheers,
Thanks for the capicom.dll Even after disabling UAC in W7Rc1 it wouldn't go, so great to have it posted to.
Chainfire, which format should the Reg's be added?
I tried the default .reg formating just under:
[Registry]
[HKEY_CURRENT_USER\ControlPanel\Profiles]
@=""
"ActiveProfile"="Normal"
?
Scrap that i found the .inf format
[AddRegistry]
HKCU,"New Key","",0x00010001,1
Many thanks for this, i'll try to Point Driver replacing Sinners from now on to here.
Well INF files are a regular female dog.
If you rather use WinCE CAB Manager, the trick is easily done as well. I do not have it handy right here (I'm not at dev box), but it goes like this.
Put the DLL's and EXE's that need to go in the CAB into the same folder as DriverWiz
Execute the following command from the command prompt in the DriverWiz folder: signtool sign /f DriverWiz.pfx *.exe *.dll
Open your WCM/CAB with CM
Somewhere is an option for "Pre XML" (main screen IIRC).. click to add/edit, and load the DriverWiz.xml file
Save
signtool sign /f DriverWiz.pfx *.cab
Et voila. I should really make an update to DriverWiz to include CAPICOM and write a proper guide on how to do all this manually (including making your own certificates and such). It's easy if you know how
If you could insert another empty post for me at the top, that'd be great.

Categories

Resources