how to modify serial number of usb device by usb filter driver?

C

curliph

Guest
hi, I want to modify the serial number or PID/VID of my usb mass stroage disk.
I try it by an usb class filter driver to capture the
URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
But,It seems useless!
how should I do? many thanks!
 


D

Doron Holan [MS]

Guest
what side affect do you want your change to have? that the usb core not use
it for a unique ID or that usbstor uses your changed value ?

d

--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.


"curliph" <curliph@discussions.microsoft.com> wrote in message
news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
> hi, I want to modify the serial number or PID/VID of my usb mass stroage
> disk.
> I try it by an usb class filter driver to capture the
> URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
> But,It seems useless!
> how should I do? many thanks!



 
D

Doron Holan [MS]

Guest
what side affect do you want your change to have? that the usb core not use
it for a unique ID or that usbstor uses your changed value ?

d

--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.


"curliph" <curliph@discussions.microsoft.com> wrote in message
news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
> hi, I want to modify the serial number or PID/VID of my usb mass stroage
> disk.
> I try it by an usb class filter driver to capture the
> URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
> But,It seems useless!
> how should I do? many thanks!



 
D

Doron Holan [MS]

Guest
what side affect do you want your change to have? that the usb core not use
it for a unique ID or that usbstor uses your changed value ?

d

--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.


"curliph" <curliph@discussions.microsoft.com> wrote in message
news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
> hi, I want to modify the serial number or PID/VID of my usb mass stroage
> disk.
> I try it by an usb class filter driver to capture the
> URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
> But,It seems useless!
> how should I do? many thanks!



 
M

Maxim S. Shatskih

Guest
Re: how to modify serial number of usb device by usb filter driver

Add the filter which will just ignore the serial number by patching the
DEVICE_CAPABILITIES and resetting UniqueId bit.

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com

"curliph" <curliph@discussions.microsoft.com> wrote in message
news:BDBC08DD-BC5F-4382-819A-0DB6275D9197@microsoft.com...
> Thanks for your answer!
> Infect, I have two usb device with the same pid/vid and serial number.
> them can not co-exist in windows...
> for certain reason,I have to fix the bug by modify somthing inside os..
> I think I should change the string of iSerialNumber before os load
> usbstor.sys.
> so,the changed value should be used by usb core or even lower drivers.
> right?
> but I don't know how to do that!
>
>
> "Doron Holan [MS]" wrote:
>
> > what side affect do you want your change to have? that the usb core not

use
> > it for a unique ID or that usbstor uses your changed value ?
> >
> > d
> >
> > --
> > Please do not send e-mail directly to this alias. this alias is for
> > newsgroup purposes only.
> > This posting is provided "AS IS" with no warranties, and confers no rights.
> >
> >
> > "curliph" <curliph@discussions.microsoft.com> wrote in message
> > news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
> > > hi, I want to modify the serial number or PID/VID of my usb mass stroage
> > > disk.
> > > I try it by an usb class filter driver to capture the
> > > URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
> > > But,It seems useless!
> > > how should I do? many thanks!

> >
> >
> >


 
D

Doron Holan [MS]

Guest
Re: how to modify serial number of usb device by usb filter driver

that is too late. you need to filter the parent hub's query device
relations. you need to filter the entire usb bus since you don't know which
port you will be attached to. this is a very difficult task, you can't
really work around your broken hw this way

--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.


"Maxim S. Shatskih" <maxim@storagecraft.com> wrote in message
news:uVRQ2TAkGHA.1324@TK2MSFTNGP04.phx.gbl...
> Add the filter which will just ignore the serial number by patching the
> DEVICE_CAPABILITIES and resetting UniqueId bit.
>
> --
> Maxim Shatskih, Windows DDK MVP
> StorageCraft Corporation
> maxim@storagecraft.com
> http://www.storagecraft.com
>
> "curliph" <curliph@discussions.microsoft.com> wrote in message
> news:BDBC08DD-BC5F-4382-819A-0DB6275D9197@microsoft.com...
>> Thanks for your answer!
>> Infect, I have two usb device with the same pid/vid and serial number.
>> them can not co-exist in windows...
>> for certain reason,I have to fix the bug by modify somthing inside os..
>> I think I should change the string of iSerialNumber before os load
>> usbstor.sys.
>> so,the changed value should be used by usb core or even lower drivers.
>> right?
>> but I don't know how to do that!
>>
>>
>> "Doron Holan [MS]" wrote:
>>
>> > what side affect do you want your change to have? that the usb core
>> > not

> use
>> > it for a unique ID or that usbstor uses your changed value ?
>> >
>> > d
>> >
>> > --
>> > Please do not send e-mail directly to this alias. this alias is for
>> > newsgroup purposes only.
>> > This posting is provided "AS IS" with no warranties, and confers no
>> > rights.
>> >
>> >
>> > "curliph" <curliph@discussions.microsoft.com> wrote in message
>> > news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
>> > > hi, I want to modify the serial number or PID/VID of my usb mass
>> > > stroage
>> > > disk.
>> > > I try it by an usb class filter driver to capture the
>> > > URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
>> > > But,It seems useless!
>> > > how should I do? many thanks!
>> >
>> >
>> >

>



 
C

curliph

Guest
Re: how to modify serial number of usb device by usb filter driver

You are right...I had just follow the advice by Maxim S. Shatskih.
it still can't work :(

I will try to filter the entire bus...any advice?
or, Is there other way to make the two device work together?


"Doron Holan [MS]" wrote:

> that is too late. you need to filter the parent hub's query device
> relations. you need to filter the entire usb bus since you don't know which
> port you will be attached to. this is a very difficult task, you can't
> really work around your broken hw this way
>
> --
> Please do not send e-mail directly to this alias. this alias is for
> newsgroup purposes only.
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>
> "Maxim S. Shatskih" <maxim@storagecraft.com> wrote in message
> news:uVRQ2TAkGHA.1324@TK2MSFTNGP04.phx.gbl...
> > Add the filter which will just ignore the serial number by patching the
> > DEVICE_CAPABILITIES and resetting UniqueId bit.
> >
> > --
> > Maxim Shatskih, Windows DDK MVP
> > StorageCraft Corporation
> > maxim@storagecraft.com
> > http://www.storagecraft.com
> >
> > "curliph" <curliph@discussions.microsoft.com> wrote in message
> > news:BDBC08DD-BC5F-4382-819A-0DB6275D9197@microsoft.com...
> >> Thanks for your answer!
> >> Infect, I have two usb device with the same pid/vid and serial number.
> >> them can not co-exist in windows...
> >> for certain reason,I have to fix the bug by modify somthing inside os..
> >> I think I should change the string of iSerialNumber before os load
> >> usbstor.sys.
> >> so,the changed value should be used by usb core or even lower drivers.
> >> right?
> >> but I don't know how to do that!
> >>
> >>
> >> "Doron Holan [MS]" wrote:
> >>
> >> > what side affect do you want your change to have? that the usb core
> >> > not

> > use
> >> > it for a unique ID or that usbstor uses your changed value ?
> >> >
> >> > d
> >> >
> >> > --
> >> > Please do not send e-mail directly to this alias. this alias is for
> >> > newsgroup purposes only.
> >> > This posting is provided "AS IS" with no warranties, and confers no
> >> > rights.
> >> >
> >> >
> >> > "curliph" <curliph@discussions.microsoft.com> wrote in message
> >> > news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
> >> > > hi, I want to modify the serial number or PID/VID of my usb mass
> >> > > stroage
> >> > > disk.
> >> > > I try it by an usb class filter driver to capture the
> >> > > URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
> >> > > But,It seems useless!
> >> > > how should I do? many thanks!
> >> >
> >> >
> >> >

> >

>
>
>

 
C

curliph

Guest
Re: how to modify serial number of usb device by usb filter driver

By the way, the two devices (with identical pid/vid and serial number) work
well in Win XP, but not in Win 2k.
what's the difference?

"Doron Holan [MS]" wrote:

> that is too late. you need to filter the parent hub's query device
> relations. you need to filter the entire usb bus since you don't know which
> port you will be attached to. this is a very difficult task, you can't
> really work around your broken hw this way
>
> --
> Please do not send e-mail directly to this alias. this alias is for
> newsgroup purposes only.
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>
> "Maxim S. Shatskih" <maxim@storagecraft.com> wrote in message
> news:uVRQ2TAkGHA.1324@TK2MSFTNGP04.phx.gbl...
> > Add the filter which will just ignore the serial number by patching the
> > DEVICE_CAPABILITIES and resetting UniqueId bit.
> >
> > --
> > Maxim Shatskih, Windows DDK MVP
> > StorageCraft Corporation
> > maxim@storagecraft.com
> > http://www.storagecraft.com
> >
> > "curliph" <curliph@discussions.microsoft.com> wrote in message
> > news:BDBC08DD-BC5F-4382-819A-0DB6275D9197@microsoft.com...
> >> Thanks for your answer!
> >> Infect, I have two usb device with the same pid/vid and serial number.
> >> them can not co-exist in windows...
> >> for certain reason,I have to fix the bug by modify somthing inside os..
> >> I think I should change the string of iSerialNumber before os load
> >> usbstor.sys.
> >> so,the changed value should be used by usb core or even lower drivers.
> >> right?
> >> but I don't know how to do that!
> >>
> >>
> >> "Doron Holan [MS]" wrote:
> >>
> >> > what side affect do you want your change to have? that the usb core
> >> > not

> > use
> >> > it for a unique ID or that usbstor uses your changed value ?
> >> >
> >> > d
> >> >
> >> > --
> >> > Please do not send e-mail directly to this alias. this alias is for
> >> > newsgroup purposes only.
> >> > This posting is provided "AS IS" with no warranties, and confers no
> >> > rights.
> >> >
> >> >
> >> > "curliph" <curliph@discussions.microsoft.com> wrote in message
> >> > news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
> >> > > hi, I want to modify the serial number or PID/VID of my usb mass
> >> > > stroage
> >> > > disk.
> >> > > I try it by an usb class filter driver to capture the
> >> > > URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
> >> > > But,It seems useless!
> >> > > how should I do? many thanks!
> >> >
> >> >
> >> >

> >

>
>
>

 
D

Doron Holan [MS]

Guest
Re: how to modify serial number of usb device by usb filter driver

you are proposing to write a bus filter driver. quite difficult to do and
completely undocumented and unsupported by microsoft.

d

--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.


"curliph" <curliph@discussions.microsoft.com> wrote in message
news:B23C1C69-1643-4E2D-8BB7-5D2970F53A34@microsoft.com...
> You are right...I had just follow the advice by Maxim S. Shatskih.
> it still can't work :(
>
> I will try to filter the entire bus...any advice?
> or, Is there other way to make the two device work together?
>
>
> "Doron Holan [MS]" wrote:
>
>> that is too late. you need to filter the parent hub's query device
>> relations. you need to filter the entire usb bus since you don't know
>> which
>> port you will be attached to. this is a very difficult task, you can't
>> really work around your broken hw this way
>>
>> --
>> Please do not send e-mail directly to this alias. this alias is for
>> newsgroup purposes only.
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>>
>>
>> "Maxim S. Shatskih" <maxim@storagecraft.com> wrote in message
>> news:uVRQ2TAkGHA.1324@TK2MSFTNGP04.phx.gbl...
>> > Add the filter which will just ignore the serial number by patching
>> > the
>> > DEVICE_CAPABILITIES and resetting UniqueId bit.
>> >
>> > --
>> > Maxim Shatskih, Windows DDK MVP
>> > StorageCraft Corporation
>> > maxim@storagecraft.com
>> > http://www.storagecraft.com
>> >
>> > "curliph" <curliph@discussions.microsoft.com> wrote in message
>> > news:BDBC08DD-BC5F-4382-819A-0DB6275D9197@microsoft.com...
>> >> Thanks for your answer!
>> >> Infect, I have two usb device with the same pid/vid and serial number.
>> >> them can not co-exist in windows...
>> >> for certain reason,I have to fix the bug by modify somthing inside
>> >> os..
>> >> I think I should change the string of iSerialNumber before os load
>> >> usbstor.sys.
>> >> so,the changed value should be used by usb core or even lower drivers.
>> >> right?
>> >> but I don't know how to do that!
>> >>
>> >>
>> >> "Doron Holan [MS]" wrote:
>> >>
>> >> > what side affect do you want your change to have? that the usb core
>> >> > not
>> > use
>> >> > it for a unique ID or that usbstor uses your changed value ?
>> >> >
>> >> > d
>> >> >
>> >> > --
>> >> > Please do not send e-mail directly to this alias. this alias is for
>> >> > newsgroup purposes only.
>> >> > This posting is provided "AS IS" with no warranties, and confers no
>> >> > rights.
>> >> >
>> >> >
>> >> > "curliph" <curliph@discussions.microsoft.com> wrote in message
>> >> > news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
>> >> > > hi, I want to modify the serial number or PID/VID of my usb mass
>> >> > > stroage
>> >> > > disk.
>> >> > > I try it by an usb class filter driver to capture the
>> >> > > URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
>> >> > > But,It seems useless!
>> >> > > how should I do? many thanks!
>> >> >
>> >> >
>> >> >
>> >

>>
>>
>>



 
D

Doron Holan [MS]

Guest
Re: how to modify serial number of usb device by usb filter driver

the XP usb core tracks serial numbers and does not use the serial number as
a unique identifier on the bus

d

--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.


"curliph" <curliph@discussions.microsoft.com> wrote in message
news:CF83B68A-2A1C-43B5-B29D-E8FF5A84B676@microsoft.com...
> By the way, the two devices (with identical pid/vid and serial number)
> work
> well in Win XP, but not in Win 2k.
> what's the difference?
>
> "Doron Holan [MS]" wrote:
>
>> that is too late. you need to filter the parent hub's query device
>> relations. you need to filter the entire usb bus since you don't know
>> which
>> port you will be attached to. this is a very difficult task, you can't
>> really work around your broken hw this way
>>
>> --
>> Please do not send e-mail directly to this alias. this alias is for
>> newsgroup purposes only.
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>>
>>
>> "Maxim S. Shatskih" <maxim@storagecraft.com> wrote in message
>> news:uVRQ2TAkGHA.1324@TK2MSFTNGP04.phx.gbl...
>> > Add the filter which will just ignore the serial number by patching
>> > the
>> > DEVICE_CAPABILITIES and resetting UniqueId bit.
>> >
>> > --
>> > Maxim Shatskih, Windows DDK MVP
>> > StorageCraft Corporation
>> > maxim@storagecraft.com
>> > http://www.storagecraft.com
>> >
>> > "curliph" <curliph@discussions.microsoft.com> wrote in message
>> > news:BDBC08DD-BC5F-4382-819A-0DB6275D9197@microsoft.com...
>> >> Thanks for your answer!
>> >> Infect, I have two usb device with the same pid/vid and serial number.
>> >> them can not co-exist in windows...
>> >> for certain reason,I have to fix the bug by modify somthing inside
>> >> os..
>> >> I think I should change the string of iSerialNumber before os load
>> >> usbstor.sys.
>> >> so,the changed value should be used by usb core or even lower drivers.
>> >> right?
>> >> but I don't know how to do that!
>> >>
>> >>
>> >> "Doron Holan [MS]" wrote:
>> >>
>> >> > what side affect do you want your change to have? that the usb core
>> >> > not
>> > use
>> >> > it for a unique ID or that usbstor uses your changed value ?
>> >> >
>> >> > d
>> >> >
>> >> > --
>> >> > Please do not send e-mail directly to this alias. this alias is for
>> >> > newsgroup purposes only.
>> >> > This posting is provided "AS IS" with no warranties, and confers no
>> >> > rights.
>> >> >
>> >> >
>> >> > "curliph" <curliph@discussions.microsoft.com> wrote in message
>> >> > news:1683548F-03C7-4752-A1AB-8F8695509BA5@microsoft.com...
>> >> > > hi, I want to modify the serial number or PID/VID of my usb mass
>> >> > > stroage
>> >> > > disk.
>> >> > > I try it by an usb class filter driver to capture the
>> >> > > URB_FUNCTION_GET_DESCRIPTOR_FROM_DEVICE,then modify the data...
>> >> > > But,It seems useless!
>> >> > > how should I do? many thanks!
>> >> >
>> >> >
>> >> >
>> >

>>
>>
>>



 

Top