Looking to covert .reg to .inf ?? Beta test my tool and see

Forum for anything else which doesn't fit in the above forums. Site feedback, random talk, whatever, are welcome.
Post Reply
MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Looking to covert .reg to .inf ?? Beta test my tool and see

Post by MrWoo » Sat Aug 19, 2006 7:02 pm

DECEMBER 30, 2007 - Updated to a new version. This one has a GUI, and can convert:
1. reg UTF 8 or 16 to inf
2. reg UTF 8 or 16 to .au3 syntax (for scripting)
3. inf to reg (UTF 16)
4. inf to .au3 syntax

Drag a file on the proper icon, and it outputs the same name to chosen file type in the same directory.

Drag a directory, and it recursively scans that directory for all files of chosen type, and puts them into one file of chosen type, in same directory as the directory dragged.

I have been over it many times already, and I think it works 100%. It does this too:
1. keeps comments
2. in reg file, comment the Hive key (ie. ;[HKEY_) and all values with that key are automatically commented (maybe not for ;[-H though)
3. in .au3 output, suport for all reg types not exist yet, but it does handle the hex(1) values properly :)
4. properly handles a few values that I noted in n7epsilons forum that his 'may' not handle correctly

Now, there a some things it will not do, such as create Hive key with no value to put with it. There is a limitation in AutoIT of 4096 characters in a .au3 script, so over that amound is commented. You will see it, lol. As of now I have not felt the need to work on a concatenation method like a .reg file does by appending a \ to break long hex values up.

All in all, it works pretty well so far. I am looking for some to beta test it and see what you may find out.

Get it like the older one...
You will be looking for SG-IRA.rar. Inside is SG-IRA.exe.

I also have working a way to put a reg or inf file in, and use autoit to read the values as they currently exist and log them into a format which can be easily mass edited to write the original values back. Or for that matter, during OS setup, have it read reg files, read the registry data for those values, log them, and then execute the reg files. I don't know if I will go further with that or not, depends how well peeps like this portion.

Cheers,
MrWoo



OLD>>>
I have revised the tool I built. I need some beta testers for it though. If you are interested, it can be gotten via ftp at
(ftp://woo@hoopersgardencenter.com)

username: (woo@hoopersgardencenter.com)
pw: (wooinf)

Get both the Woo.cab and Woo_Reg.inf files. Save them to the same directory and install the inf.

I was using Reg2Inf, but found a lot of editing was required afterwards. So, I made this one. It handles hex(b): QWord registry keys now. It correctly concatenates hex:, hex(2): and hex(7) values. It also converts any long (that is, concatenated with a '\' spanning multiple rows) hex(2): value to a string. I have included the concatenation of hex(9): Full Descriptors, but give a warning message as a line comment.

The inf file used to install it copies the exe to Root, makes a context menu called 'Woo - Reg' under the HKR\regfile\shell key. Then right click on any .reg file, and choose the Woo - Reg menu item. Follow the rest.

This works only for W2K or XP machins AFAIK. There is minimal error checking at the moment. Also I use the format 0x00000000 for the data types. I included a small breakdown of the data types and hex(): values in the output file.

Try it out and let me know if it performs correctly.

It is 100% coded in AutoIt, v3.2.01, using SciTe editor.

I will leave it on the FTP site for only a week or less.

Later,
MrWoo
Last edited by MrWoo on Mon Dec 31, 2007 3:38 am, edited 1 time in total.

User avatar
n7Epsilon
Moderator
Posts: 624
Joined: Thu Feb 17, 2005 1:37 am
Location: Cairo, Egypt

Post by n7Epsilon » Sun Aug 20, 2006 1:00 am

Thank you for explaining that hex(b) is Qword, I have implemented this into Reg2Inf (after a little bit of researching). It seems that Windows treats it like REG_BINARY...

Would you mind if you post a sample of hex(9) ?

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Sun Aug 20, 2006 1:20 am

Code: Select all

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Safer\CodeIdentifiers\0\Hashes\{349d35ab-37b5-462f-9b89-edd5fbde1328}]
"ItemData"=hex:5e,ab,30,4f,95,7a,49,89,6a,00,6c,1c,31,15,40,15
"LastModified"=hex(b):85,c4,34,dc,19,a2,c2,01
"ItemSize"=hex(b):0b,03,00,00,00,00,00,00

Code: Select all

HKLM,"Software\Policies\Microsoft\Windows\Safer\CodeIdentifiers\0\Hashes\{349d35ab-37b5-462f-9b89-edd5fbde1328}","LastModified",0x000B0001,85,c4,34,dc,19,a2,c2,01
HKLM,"Software\Policies\Microsoft\Windows\Safer\CodeIdentifiers\0\Hashes\{349d35ab-37b5-462f-9b89-edd5fbde1328}","ItemSize",0x000B0001,0b,03,00,00,00,00,00,00
There is also another data type in the registry named QWORD though it is not at all common. This is similar to DWORD except it can hold 64 bits (double the size of a DWORD value)
I think, I found really the problems source. Microsoft use a new kind of variable QWord. If you look in the hivestf.inf, you can see variable from kind 0x000B0001, the new QWord. You can see the same variable on your XP with SP2.
We have folow problem, pebuilder3026 don't know the QWord.
I copied the hivesft.inf to hivesft.old and changed in the hivesft.inf all 0x000B0001 to 0x00010003, QWord to DWord in the source I386, compile works fine. And now I can boot from CD!
Hex(9) is a Descriptor. I am unsure of the data type (0x00000000) value to use with it to format for inf. Here is a sample key.

Code: Select all

"Configuration Data"=hex(9):ff,ff,ff,ff,ff,ff,ff,ff,00,00,00,00,02,00,00,00,05,\
  00,00,00,18,00,00,00,00,00,00,00,00,00,00,00,80,00,ff,03,00,00,3f,00,fe,00,\
  02,00,81,00,ff,03,00,00,3f,00,fe,00,02,00,05,00,00,00,20,00,00,00,00,00,00,\
  00,00,00,00,00,00,00,0c,00,00,de,00,00,00,00,0d,00,00,10,00,00,00,00,0e,00,\
  00,00,01,00,00,00,0f,00,00,00,01,00
Reg2Inf seems to stop at "\" on the first line. It is commented though. I just step through the lines, formatted for inf, and use binary datatype. It will go into the registry, but not as hex(9), only as hex.

Later,
MrWoo

Will be out of town for a week. Will check back in and see if anyone has tried it or not. Also coming up will be tool to build INF based off of the directory contents to distribute. Then another tool to merge the directory INF with the INF made from reg keys. And also tool to copy all files in said directory to one prepped directory. As well as cab tool. Nothing new there. Trying to make inf builds as quick as possible. Actually I have those done already, just need to run some more tests.

User avatar
n7Epsilon
Moderator
Posts: 624
Joined: Thu Feb 17, 2005 1:37 am
Location: Cairo, Egypt

Post by n7Epsilon » Sun Aug 20, 2006 1:27 am

Hi,
Reg2Inf doesn't support hex(9) (yet.. I didn't know that such a value existed...)
I have designed it to ignore commented lines, so that may be the problem... Just uncomment the line since it determines whether to stop at "\" or concatenate everything based on the hex(n) prefix in the 1st line.

(wow! that's the same (and only) source I found when looking for qword on google!)

Thanks again for posting the samples, I will look into it as soon as possible.

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Sun Aug 20, 2006 1:46 am

Try googling:

REG_QWORD
Registry REG_QWORD
INF REG_QWORD
REG_QWORD datatype
REG_QWORD hexadecimal

I may be using an older version of Reg2Inf. I have a vbs & batch one I think. I have found that it does not continue the hex(9) value if it is concated with '\'. It posts a comment ;****** warning etc ******* and leaves me with only a single line after the comment. It always sets warning variable if it comes to binary.

I looked at the script for awhile. Then I decided to try my own. I convert the hex(2) and hex(7) into a string if it is concated with '\' to save space. I have it working good, so I display no warning except for hex(9). Seems to work fine.

There is also a hex(a) which I have not researched much yet.

Later,
MrWoo

EDIT: Maybe I am not using the Reg2INf that you wrote. My version, which I have had for at least a year, if not 2 years, does check for hex(9). Here is a sample of the line:

Code: Select all

If Fis(CurrL, "=hex(9):") > 1 Then InfStream.WriteLine _

User avatar
n7Epsilon
Moderator
Posts: 624
Joined: Thu Feb 17, 2005 1:37 am
Location: Cairo, Egypt

Post by n7Epsilon » Sun Aug 20, 2006 1:54 am

Then, that's not my Reg2Inf at all, mine is written in C# (not a vbs) and does not write comments inside the output...
(Maybe you should try mine, (it doesn't support (hex(a)) ot (hex(9)) but it works correctly with everything else)...

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Sun Aug 20, 2006 1:57 am

Hmm. I will try it. That is strange.

Just for learning sake, could you give mine a go and see if I have done it correctly?

MrWoo

User avatar
n7Epsilon
Moderator
Posts: 624
Joined: Thu Feb 17, 2005 1:37 am
Location: Cairo, Egypt

Post by n7Epsilon » Sun Aug 20, 2006 2:44 am

I've tried yours, it works great, but there are some problems...

- It doesn't concatenate type hex: (Reg_binary)
- hex(2) isn't converted to string in some cases (It needs to be in string in INF to work)
- It can't handle non-english characters (due to always output in ASCII, it think can be fixed if you output in Unicode)
- Reg_Multi_Sz, multiple lines were not separated.

Here's the sample REG I used (the same I used when making mine):
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\n7EpsilonTEST]
@=";I;a;m;ABug!@#$%^&*()\"Welcome\"\"ConfuseMeBaby\""
"AnotherTest"=""
"TestOfAString"="TestIngASTRI__NG"
"TestBinary"=hex:01,02,04,40,35,94,09,5f,fd,fe,03,49,03,90,23,ee,03,49,05,90,\
45,34,05,20,31,24,39,49,40,39,40,34,40,39,54
"TestDword"=dword:23fffd30
"TestExpandString"=hex(2):25,00,41,00,50,00,50,00,44,00,41,00,54,00,41,00,25,\
00,25,00,53,00,59,00,53,00,54,00,45,00,4d,00,44,00,52,00,49,00,56,00,45,00,\
25,00,00,00
"TestFixes"="C:\\Windows\\System32\\NTOSKRNL.EXE \\\\ Just Kidding \\\\ \\\" \\\" \\\" Just a test for the \"s \\\"\" \\\" %% C:\\\\"
"TestFixesInMULTI_SZ"=hex(7):43,00,3a,00,5c,00,57,00,69,00,6e,00,64,00,6f,00,\
77,00,73,00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,4e,\
00,54,00,4f,00,53,00,4b,00,52,00,4e,00,4c,00,2e,00,45,00,58,00,45,00,20,00,\
5c,00,20,00,4a,00,75,00,73,00,74,00,20,00,4b,00,69,00,64,00,64,00,69,00,6e,\
00,67,00,20,00,5c,00,20,00,5c,00,22,00,00,00,57,00,65,00,6c,00,63,00,6f,00,\
6d,00,65,00,00,00,5c,00,22,00,5c,00,22,00,5c,00,22,00,00,00,5c,00,22,00,00,\
00,30,00,00,00,3e,00,3e,00,3c,00,00,00,ae,00,4a,06,ae,00,4a,06,00,00,5c,00,\
22,00,5c,00,22,00,00,00,ae,00,4a,06,00,00,00,00

[HKEY_LOCAL_MACHINE\SOFTWARE\n7EpsilonTEST\SubKey]
@=""

[HKEY_LOCAL_MACHINE\SOFTWARE\n7EpsilonTEST\SubKey\Subkey2]

[HKEY_LOCAL_MACHINE\SOFTWARE\n7EpsilonTEST\SubKey\Subkey2\Subkey3]
"ZeroWing"=hex(7):57,00,68,00,61,00,74,00,20,00,68,00,61,00,70,00,70,00,65,00,\
6e,00,20,00,3f,00,00,00,53,00,6f,00,6d,00,65,00,62,00,6f,00,64,00,79,00,20,\
00,73,00,65,00,74,00,20,00,75,00,70,00,20,00,75,00,73,00,20,00,74,00,68,00,\
65,00,20,00,62,00,6f,00,6d,00,62,00,20,00,21,00,00,00,57,00,65,00,20,00,67,\
00,65,00,74,00,20,00,73,00,69,00,67,00,6e,00,61,00,6c,00,20,00,21,00,00,00,\
57,00,68,00,61,00,74,00,20,00,21,00,00,00,4d,00,61,00,69,00,6e,00,20,00,53,\
00,63,00,72,00,65,00,65,00,6e,00,20,00,54,00,75,00,72,00,6e,00,20,00,4f,00,\
6e,00,2e,00,00,00,49,00,74,00,27,00,73,00,20,00,59,00,6f,00,75,00,20,00,21,\
00,00,00,48,00,6f,00,77,00,20,00,41,00,72,00,65,00,20,00,59,00,6f,00,75,00,\
20,00,47,00,65,00,6e,00,74,00,6c,00,65,00,6d,00,65,00,6e,00,20,00,21,00,00,\
00,41,00,4c,00,4c,00,20,00,59,00,4f,00,55,00,52,00,20,00,42,00,41,00,53,00,\
45,00,20,00,41,00,52,00,45,00,20,00,42,00,45,00,4c,00,4f,00,4e,00,47,00,20,\
00,54,00,4f,00,20,00,55,00,53,00,20,00,21,00,21,00,00,00,59,00,6f,00,75,00,\
20,00,61,00,72,00,65,00,20,00,6f,00,6e,00,20,00,74,00,68,00,65,00,20,00,77,\
00,61,00,79,00,20,00,74,00,6f,00,20,00,64,00,65,00,73,00,74,00,72,00,75,00,\
63,00,74,00,69,00,6f,00,6e,00,2e,00,00,00,57,00,68,00,61,00,74,00,20,00,79,\
00,6f,00,75,00,20,00,73,00,61,00,79,00,20,00,3f,00,00,00,59,00,6f,00,75,00,\
20,00,68,00,61,00,76,00,65,00,20,00,6e,00,6f,00,20,00,63,00,68,00,61,00,6e,\
00,63,00,65,00,20,00,74,00,6f,00,20,00,73,00,75,00,72,00,76,00,69,00,76,00,\
65,00,20,00,6d,00,61,00,6b,00,65,00,20,00,79,00,6f,00,75,00,72,00,20,00,74,\
00,69,00,6d,00,65,00,2e,00,00,00,00,00
"Filename.cmd"=hex(2):4b,00,6f,00,6e,00,69,00,63,00,68,00,69,00,77,00,61,00,00,\
00
"TestBIN"=hex:41,4c,4c,20,59,4f,55,52,42,41,53,45,20,41,52,45,20,42,45,4c,4f,\
4e,47,20,54,4f,20,55,53,20,21,21,21

[HKEY_LOCAL_MACHINE\SOFTWARE\n7EpsilonTEST\SubKey2]
@="Confusion ىىىىىىىىىىىىىىىىىىىىى"

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Sun Aug 20, 2006 3:24 am

Cool test keys. Hmm. Let's see.

hex(2) and hex(7), in my tests, IF only on one line and NOT needing \, did not need to be converted to string to work. For me, if the value extended to multiple lines with the \, then I converted it. I will play with that one some more.

I thought it was concating hex. Meaning using \ at end of row. I tried various methods of converting or stripping the binary, but found no better way than leaving it as is, including all of the \'s. I will play with that one some more this week as well.

Non english characters, by that do you mean extended characters, or as in another language. I have not tried to output in Unicode. Matter of fact, I am not sure I can. I will find out. I do know however that with AutoIt script, the .reg file cannot be opened and read. It must be converted to ASCII first. I use a command line to do that, then delete the file it makes after sript end.

Reg multi lines not seperated. I will also look into that one. In my tests, which included a few examples of about every data type I had in my registry, They all merged back in proper except for hex(9). I will do some more testing with your test script and see what it outputs.

Thanks for the info.

Later,
MrWoo

EDIT: Removed long reg text
Last edited by MrWoo on Mon Dec 31, 2007 3:22 am, edited 1 time in total.

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Sat Sep 09, 2006 6:28 pm

n7Epsilon --- or anyone who cares to piddle,

Whew. After hours and hours of learning, I have a script that reads and writes in UTF-16. All of the issues that you have pointed out have been fixed. And whilst it did require a lot of learning and writing my own functions to handle it, it was definately worthwile knowledge wise.

Ah, but it does not end there. I have spent a week on the following problem. Neither your INF tool nor mine can correctly convert this value. Here it is.

Code: Select all

"some name"=".exe
.com
.sys
"

"some name2"="A virus has been found. It is [15012]

It lives at [15013]


Would you like to treat the virus [15012] at [15013]?"
These are REG_SZ values, but Mutliple-Line strings. That is, they are most definately not REG_MULTI_SZ. I have successfully put in LF, but it does not work correctly. I have put in Unicode CR & LF (000A & 000D), which does work to a degree. The values in the registry appear correct. But if you examine the binary of the values, it carries the Unicode value, not the correct (0A00 & 0D00).

The first value is a list of file types to be detected or chosen from. The second is what is displayed when a virus is found. The CRLF's are used to give room for the variables [15012] to display the location and name of the virus.

Interesting way to utilize the registry. I have not found a way to manually make that value from regedit. Ctrl & J or Ctrl & M are supposed to insert the control character, which works in Notepad. But not in regedit.

Now the good stuff.

I found 2 places that mention this value " hex(1); " . Which I have never seen before. What is it? It lets me do this:

Code: Select all

"Some value"=hex(1): hexadecimal values for the LF delimited string value"
... which from a .reg file, correctly puts the value into the registry. Viola! Happy about that and all. BUT, heh heh, what is the data type for an INF file? Good question indeed.

I tried the append flag being 8 on the end of the 0x. I tried every combo I could think of. But I cannot get this kind of value to work from an INF. I spent a long time looking at my registry, and have yet to find another value like it. But, now that I know it exists, have to find a way to input it.

One possibility I am looking at is an obsure directive called Ini2Reg. Unsure yet it that will do this, but will play with it.

Any ideas on this?

Oh, by the way, I am now using INF to put in FULL_REG_DESCRIPTORS, ( that is, hex(9): ) like this:

Code: Select all

HKLM,"subkey",0x00090001, hex values go here
Also, if you might not have known, there are flags for whether to put a value, (from an INF) into the registry as 16,32 or 64 bit portion. I think more relating to QWORD values than anything.

That is it I guess. Like to see what you can make of that hex(1): thing, as I am baffled.

Later,
MrWoo

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Sat Sep 09, 2006 6:50 pm

Here is what xp exports into Unicode for the second value
22 00 44 00 69 00 73 00 70 00 6C 00 61 00 79 00 4D 00 65 00 73 00 73 00 61 00 67 00 65 00 22 00 3D 00 22 00 46 00 2D 00 50 00 72 00 6F 00 74 00 20 00 41 00 6E 00 74 00 69 00 76 00 69 00 72 00 75 00 73 00 20 00 2D 00 20 00 4F 00 6E 00 44 00 65 00 6D 00 61 00 6E 00 64 00 20 00 53 00 63 00 61 00 6E 00 6E 00 65 00 72 00 20 00 68 00 61 00 73 00 20 00 66 00 6F 00 75 00 6E 00 64 00 20 00 61 00 20 00 76 00 69 00 72 00 75 00 73 00 2E 00 0D 00 0A 00 0D 00 0A 00 0D 00 0A 00 56 00 69 00 72 00 75 00 73 00 20 00 3A 00 20 00 5B 00 31 00 35 00 30 00 31 00 35 00 5D 00 0D 00 0A 00 0D 00 0A 00 4C 00 6F 00 63 00 61 00 74 00 69 00 6F 00 6E 00 20 00 3A 00 20 00 20 00 5B 00 31 00 35 00 30 00 31 00 33 00 5D 00 5B 00 31 00 35 00 30 00 31 00 32 00 5D 00 22 00
The actual binary of the value in the registry shows the hex for each letter, seperated by 0A 00 where the linefeeds should go, with the last value ending with 0A 00 00 00

The first example, the extention list, is hex for each letter being seperated again by 0A 00 at the breaks. XP does not know how to properly export it, as it inserts 0D00 0A00. And it also inserts in spots, 0D00 0D00 0A00.

Included to describe a little better what should be present, as it exports improperly.

Late,
MrWoo

User avatar
n7Epsilon
Moderator
Posts: 624
Joined: Thu Feb 17, 2005 1:37 am
Location: Cairo, Egypt

Post by n7Epsilon » Sat Sep 09, 2006 7:58 pm

I have seen that too and noted it on the forum, since I see XP itself exports it incorrectly and it is not used in normal REG files, I didn't try to fix it. It is probably a REGEDIT bug and if REGEDIT doesn't export it correctly, there's no point in converting it to INF.

I've never seen the hex(1) type before too, have no idea about it.
EDIT: Seem to have found some info here:
http://www.mdgx.com/reg.htm
Would it work if we used REG_SZ code but input the data like binary ? I'll test and see...

Lots of information, looks like I have to implement hex(4) (dword), hex(3) (binary) in the hex format.

All that's left i think are hex(1), hex(8) and hex(a)...

I will implement hex(9) in the next version of Reg2Inf, thank you for the information.

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Mon Sep 11, 2006 11:35 am

mdgx.com, that is one of the 2 places I could find any info as well.

It would work by by inputing the REG_SZ as binary, but I cannot find the correct flag for it. 0x00000000 does not work. We need the correct flag and it will work. Normally the first 4 are designators of the type, the last 4 as CLOBBER TYPE. But I cannot find it.

Also for hex(8) or hex(a), I have not found the correct flag yet for those.

It is interesting to note that when regedit exports a hex(1) value, it does give some markers to work with, so you could parse it out of the .reg file. I have done that. I just cannot find the correct syntax for entering it with INF format.

late,
MrWoo

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Mon Sep 11, 2006 2:28 pm

I have the hex 8 as flag 0x00080001 working.

I have the hex A as flag 0x000A0001 working.

Still looking for a flag for hex(1) that is not 0x00000000 that allows binary input to string value.

later,
MrWoo

incidentily, have you noticed a 255 character max length allowed per line in an INF file? DDK said that was the limit.

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Mon Sep 11, 2006 3:07 pm


User avatar
n7Epsilon
Moderator
Posts: 624
Joined: Thu Feb 17, 2005 1:37 am
Location: Cairo, Egypt

Post by n7Epsilon » Mon Sep 11, 2006 3:12 pm

Very interesting article... It may be that this bug is also present in XP...

I really have to thank you MrWoo for all the research you have been doing.
Recently, I've been too busy to research all the rest of the REG types. But now, almost all are now supported (thanks a lot ;) ).

User avatar
dumpydooby
Posts: 530
Joined: Sun Jan 15, 2006 6:09 am

Post by dumpydooby » Mon Sep 11, 2006 4:43 pm

Image

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Mon Sep 11, 2006 6:08 pm

It would seem to be a dead end for the hex(1) type values. While there is a flag of 0D 0D in the Unicode binary, which you can find and parse with, I can find no way of using it in an INF file. The lower 4 values must be 0x0000, or it will not be REG_SZ. I have played with the upper 4 quite a bit today, and have failed.

I went on to a .reg file, to recreate the entry. Using escape characters \r and \n, which should insert carriage returns or line feeds has no effect. The only way I can get that value to go into the registry at all is by using the hex(1): hexadecimal values method.

Pity, only one value left that is of any consequence. I suppose I could look at hex 15, or the REG_LINK values.

I think maybe I will concentrate on the Ini2Reg directive. Possibly passing the value to an Ini and including it into the .cab. Or if all else fails, write a .reg file for the value and include it into the .cab.

Later,
MrWoo

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Mon Sep 11, 2006 8:04 pm

Ini2Reg directive will not work. INI is limited, it appears, to 64kb, and a max of 254 characters per value. Besides that, I could not find a way to pass it parameters such as the value type other than string. Thus no hex(1). Mozilla has some examples of using INI for reg files, but I think it is proprietary formatting, not MS.

Back to the drawing board.

later,
MrWoo

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Tue Sep 12, 2006 2:11 am

Unless I come across a better way, I think of doing this. If a hex(1) type value is found, convert it to hex and write it to a .reg file. Set a flag. If that flag is true at end of app, ask for permission to include a runonce entry at end of add.reg section. Add appropriate directive parameters to include the .reg file into copy or other actions. Use runonce to immediately apply .reg. Or could even ask for preference of run immediately or actual runonce on next reboot.

That is the only way I can see at the moment of handling that type of string value. I think I will look at the remaining 2 values and see what can be made of them.

I have this working with the runonce method now. Not my preferred method, but it does include it.

later,
MrWoo

MrWoo
Posts: 39
Joined: Mon Aug 07, 2006 12:59 pm

Post by MrWoo » Mon Dec 31, 2007 3:39 am

bump.

See top for newer version..

MrWoo

Post Reply