Topic: [Tool] ListHWID.vbs v1.2.0

ListHWID - 1.25KB
MD5: D3DED0E1B9758444F2EA21B42B6576C7

ListMonHWID - 1.09KB
MD5: B58707ADDFB85AF86380609DF5C10E6D

Instructions:  Copy the script file to the root of the tree you want to scan and double click.  The script will crawl all of the subdirectories below the directory in which it resides.  When it's done there will be a file - hwids.csv - located in the same directory as the script itself.  From there you can open up the csv file in Excel or in my case, OOo Calc, and sort the columns however you see fit.

20081021 - v1.2.0
* Now picking up more HWIDs - and unfortunately a couple that it shouldn't  Getting closer.
* Added a separate script specifically for collecting monitor HWIDs

20081020 - v1.1.0
* Increased performance by about 20 gagillion times..  seriously.  All official DriverPacks completed under 90 seconds.
* Eliminated ALL duplicate HWIDs within the same .inf file.
* Added a very simple logging mechanism for benchmarking and statistics
* All file handles are now appropriately closed (D'oh!)

20081016 - v1.0.2
* Doubled performance by using a single regex instead of two.

20081014 - v1.0.1
* Ignore lines that begin with a semicolon.
* Eliminated consecutive duplicates (still need to eliminate non-consecutive duplicates).

Last edited by RogueSpear (2008-10-22 08:55:34)

Re: [Tool] ListHWID.vbs v1.2.0

That is awsome... you are the man... !

Yes there is one that is floating around... it is cleverly disguised as a SysPrep tool though

Sorry about that!

it's here kickarse's FindHWIDS - The INF searching HWID exporter

and, well... um... it     er,    well...  it's good wink

DP BartPE Tutorial   DP_BASE Tutorial   HWID's Tool     Read BEFORE you post    UserBars!
http://driverpacks.net/userbar/admin-1.png
The DriverPacks, the DP_Base program, and Support Forum are FREE!.

Re: [Tool] ListHWID.vbs v1.2.0

Hmm..  I guess I missed that because I didn't look in the proper subforum.  Yea, it looks as though he is attempting to do something similar to me.  But I do not think he is using regular expressions, which I think is the only road to really doing this successfully.  My script surely needs a crapload of tweaking and feature adds.  Basically I wanted to get it out there since it has helped me immensely already and I wanted to see if it would help you guys.  Additionally, I though the main DP maintainers would be able to suggest what it should do, options, etc.

Re: [Tool] ListHWID.vbs v1.2.0

agreed...

have you looked at the spotlight tool ?

DP BartPE Tutorial   DP_BASE Tutorial   HWID's Tool     Read BEFORE you post    UserBars!
http://driverpacks.net/userbar/admin-1.png
The DriverPacks, the DP_Base program, and Support Forum are FREE!.

Re: [Tool] ListHWID.vbs v1.2.0

OverFlow wrote:

have you looked at the spotlight tool ?

You know I downloaded it a while back, but still haven't gotten around to checking it out.  I probably should have done that before anything else, but I always struggle deciphering code written by others.  Especially when it's Microsoft vbs code - it follows all of the "best practices", but it a complete PITA to follow.

Re: [Tool] ListHWID.vbs v1.2.0

I dont like MS code much myself
we are 180 degrees out of sync
I like smaller faster leaner meaner they like bloat for the sake of bloat.

although i saw some very promiseing behavior and even some legitimate quality checks with the release of sp3 -
i maintain hope that that ship may still find its way someday...

in a car there are two ways to make it faster add horsepower or lighten the car - this is no different wink

DP BartPE Tutorial   DP_BASE Tutorial   HWID's Tool     Read BEFORE you post    UserBars!
http://driverpacks.net/userbar/admin-1.png
The DriverPacks, the DP_Base program, and Support Forum are FREE!.

Re: [Tool] ListHWID.vbs v1.2.0

20081016 - v1.0.2
* Doubled performance by using a single regex instead of two.

So what I'm thinking about doing is creating a series of modular scripts that can be used together or independently.  I'm fairly certain that I can read and output all of the hwids for a given system directly from VBscript by way of WMI.  Also I can implement command line switches, usage of .ini files, etc.

My initial though is to make a system that will grab the hwids of your local system or a remote system and create a custom DP for that individual system.  Taking this a step further...   we could ask the users here to run my hwid grabbing script which could output a standardized .ini file or something similar, and then create a database of configuration files that other forum member could search.

Any other thoughts?  ideas?  cries of dissension?

Unlike how I usually tend to do things, I would just assume gather input before investing a crapload of time into coding and making it all the harder to suit the code to the desires of others.

Re: [Tool] ListHWID.vbs v1.2.0

Well... you are headed in the opposite direction we have always gone and i am sure you know that... wink lol

we want all the drivers all the time not some of the drivers some of the time and some of the drivers all the time... wink

having said that (and gotten it out of the way) rofl wink


i can see where it would be nice for a company that had 200 dell model XXXX PC's to have custom DriverPacks

look up your model in an index and download tailor made packs... Very cool Idea...
especially for laptops which always seem to be a PITA

this has Often been a topic of disussion and I am certainthere would be a huge demand for it...
teh initial time investment to get this off the ground would be huge...
on the other hand we have a few hundred thousand end users, a dozen or more may even help wink not so bad then tongue


so from me you got

1) the official kibosh - about violation of our montra

2) An excited cry for more!     Bring it on Dude!

Man i love it when you come over to our house and play!

PS based on your speed comment i guess i planted a seed that grew?

DP BartPE Tutorial   DP_BASE Tutorial   HWID's Tool     Read BEFORE you post    UserBars!
http://driverpacks.net/userbar/admin-1.png
The DriverPacks, the DP_Base program, and Support Forum are FREE!.

Re: [Tool] ListHWID.vbs v1.2.0

OverFlow wrote:

Well... you are headed in the opposite direction we have always gone and i am sure you know that... wink lol

we want all the drivers all the time not some of the drivers some of the time and some of the drivers all the time... wink

i can see where it would be nice for a company that had 200 dell model XXXX PC's to have custom DriverPacks

Yea that's how I like it as well when I make a multi-vendor OEM disc, but for the most part I am dealing with about half a dozen different models.  And even then, all half dozen models are using Intel chipsets and mass storage controllers.

OverFlow wrote:

PS based on your speed comment i guess i planted a seed that grew?

Honestly, about 98% of what I do is self motivated.  The other 2% is actually posting it online for others to use.  I know I'm not unique is this regard, but I could use about another 3 or 4 of me where I work.  So whatever I can do to automate and speed up operations is always welcome.

Well I'll start to put some of the pieces together on this.  I'm going to start with the idea of going modular, one script calling another script, which should give the added benefit of each script capable of being a useful tool on it's own merits.

Re: [Tool] ListHWID.vbs v1.2.0

Hi,RogueSpear
I guess you can test my application to collect HWIDs. I've already implement cutting duplicates in it. Hope your feed backs could help to improve utility.

regards

PS
thanks for script anyway. Think I can make possibility to run it from mу app, of course if you are not against

Re: [Tool] ListHWID.vbs v1.2.0

WsnoW wrote:

Think I can make possibility to run it from mу app, of course if you are not against

If you somehow find my script useful, then by all means, use it as you see fit.  Everything that I write is fully open and intended for everyone to use freely or include with whatever they want to distribute.

That's quite a utility you got going on over there.  I'm giving it a spin right now in fact...

Re: [Tool] ListHWID.vbs v1.2.0

20081020 - v1.1.0
* Increased performance by about 20 gagillion times..  seriously.  All official DriverPacks completed under 90 seconds.
* Eliminated ALL duplicate HWIDs within the same .inf file.
* Added a very simple logging mechanism for benchmarking and statistics
* All file handles are now appropriately closed (D'oh!)


Ok, so like this thing is actually pretty useful now.  About all that's left is perhaps some fine tuning to the regex if you guys find it's missing stuff.

Re: [Tool] ListHWID.vbs v1.2.0

Wow... are all the little letters worn off your keyboard wink big_smile lol...

Your are my personal hero...

thanks a million

looking up gagillion now... LOL

DP BartPE Tutorial   DP_BASE Tutorial   HWID's Tool     Read BEFORE you post    UserBars!
http://driverpacks.net/userbar/admin-1.png
The DriverPacks, the DP_Base program, and Support Forum are FREE!.

Re: [Tool] ListHWID.vbs v1.2.0

Nice VBS script! There's room enough for us all! Thanks for a look into Regex. Am I reading the regexp incorrectly or does it only show HWIDs that have a backslash in it? Also do you make room for comments inline?

It's a good idea to get rid of the dupes. But sometimes when your searching for issues you want to find the duplicates.

My program doesn't use Regex at all to parse the information. It only reads what it needs to. It builds what it needs to parse from the logical way a INF is created.

It also allows getting certain OS type and OS arch type, getting current hardware, filtering to obtain certain classes and hwids, md5 hashes. I'll also be adding a whole bunch more functionality, it's in my first post. I do like the idea of pulling out driver folders from the main packs to create an individualized pack. However, I don't know when that'd be used exactly.

Last edited by stamandster (2008-10-21 05:06:55)

Re: [Tool] ListHWID.vbs v1.2.0

kickarse wrote:

My program doesn't use Regex at all to parse the information. It only reads what it needs to. It builds what it needs to parse from the logical way a INF is created.

That was how I initially tried to tackle the problem and I just couldn't figure out a way to do it.  Could be more of a limitation of vbs than anything else.  I had long wanted to familiarize myself with regular expressions, so I thought that this was not only a good opportunity, but the only way I would be able to do what I wanted.

Re: [Tool] ListHWID.vbs v1.2.0

RogueSpear wrote:
kickarse wrote:

My program doesn't use Regex at all to parse the information. It only reads what it needs to. It builds what it needs to parse from the logical way a INF is created.

That was how I initially tried to tackle the problem and I just couldn't figure out a way to do it.  Could be more of a limitation of vbs than anything else.  I had long wanted to familiarize myself with regular expressions, so I thought that this was not only a good opportunity, but the only way I would be able to do what I wanted.

Yeah I read up on the microsoft website on how they construct inf files. And then just looked at a lot of INF files and looked at how they really do it. For me it was the only to get consistent data without any missing hwids.

IN order to get your vbs to run what do I have to do??

Re: [Tool] ListHWID.vbs v1.2.0

kickarse wrote:

IN order to get your vbs to run what do I have to do??

You should just have to double click on the file itself.  It only requires that you have WSH on your system which you should unless it was removed by nLite.

Re: [Tool] ListHWID.vbs v1.2.0

No i mean do I have to have it in a specific folder? or the DriverPacks in a specific folder?

Re: [Tool] ListHWID.vbs v1.2.0

It will recursively scan all folders beneath itself.

Re: [Tool] ListHWID.vbs v1.2.0

cool! I'll check out it's parsing asap!

Re: [Tool] ListHWID.vbs v1.2.0

Ahh, it's nice and quick.  However you will want to fix the issue with only grabbing only XXX\XXX HWIDs.

Re: [Tool] ListHWID.vbs v1.2.0

kickarse wrote:

Ahh, it's nice and quick.  However you will want to fix the issue with only grabbing only XXX\XXX HWIDs.

Yea, I'm still working my way through regular expressions.  I know it's possible to construct one that will catch everything, it's just that I'm pretty new with them.

Re: [Tool] ListHWID.vbs v1.2.0

One thing you'll notice is that there are so many variations of HWIDS that it's almost impossible to do it that way.

I stopped doing it that way in version v1.9 looking for specific HWIDS. Which used read each line of the inf and found a matching start of a PCI\VEN, USB\, SCSIAdapter\, etc.

Then I switched to in 2.4 to what the line that holds the HWID would look like. So line that would be like an equals sign, and at least one comma, two quotes or two percent signs. Would not be HKR, HKCR, HKLM, excludefromselect, etc.

Re: [Tool] ListHWID.vbs v1.2.0

20081021 - v1.2.0
* Now picking up more HWIDs - and unfortunately a couple that it shouldn't  Getting closer.


I don't know everything about HWIDs, but in my testing with this script I've noticed a couple things that may or may not be worth looking into.  First of all, if you important the resulting .csv file into a spreadsheet program, sort the date by column C primarily and column B secondarily.  The HADAUDIO entries will be near the top and immediately I notice duplicate HWIDs between different vendors and within the same vendor but in different driver sets.  Again, I'm not too expert on this so I don't know if there are acceptable circumstances when duplicates are to be expected.

Re: [Tool] ListHWID.vbs v1.2.0

There are sometimes duplicate hwids in multiple infs from different folders. That's the way driverpacks works, sometimes unfortunately. It's completely normal.