What is the best/better way to reenumerate USB ports from a script? I need to emulate the same enumeration that occurs when a USB device is either plugged or unglugged to a USB port.

I'm working on a network to restrict access to the ISSO role USB mass storage, only. Management wants to access USB Mass Storage for ISSOs on all workstations while blocking access to USB mass storage to all others... on all the workstations. They also want to that USB ports remain available for everything except Mass Storage.

There are many ways to do it, but the only 'reliable' method, I found so far is to point the HKLM\System\CurrentControlSet\Services\UBSSTOR\ImagePath key to some fake file to block ports and rename it back to access it again.

To do this, I need to do things more two 2...

1. make sure that the ImagePath key always has the false value at startup, and

2. create a login script that affects the ImagePath value when a member of the ISSO group connects... and reset it when they log off.

Which meet the requirements of the direction if only it worked! The problem is that USB devices must be listed again to re-read the ImagePath registry key after each change. Reconnect the device will do, but it would be unwise to rely on a user to restrict access (fox/Coop).

The following Microsoft KB seems to be the way to go, but we do not have compilers on the network...

http://support.Microsoft.com/kb/259695

I know that this hack to the system is not the most elegant, but I'm just trying to make the management happy.

Nobody knows...

1. any (more elegant) way to meet the specified requirement, or

2. a way to re - enumerate USB devices from a script.

Thank you! ... Todd

Hi Todd,

The issue of Windows XP, you have posted is better suited for the IT Pro TechNet public. Please ask your question in the TechNet forums for assistance.

Hope the helps of information.

Tags: Windows

Similar Questions

Maybe you are looking for