Jump to content

[SOLVED] USBstick take letter D and not U


Recommended Posts

I am still not convinced that the hash is actually CRC32, plus the string must be converted to unicode.

Look at the HASH_UNICODE_STRING macro posted above, it differs from any other macros I saw for creating CRC32 hash.

Link to comment
Share on other sites

  • 1 month later...

About Unicode:

Since the original text is "plain" it should be simply that "normal" text, with 00's as separators, see here:


Input in "Mixed Input"

Check output as "Hexadecimal code points"

But there are endless types of encding that can be called "UNICODE"....

There are several CRC32 conventions:


Now which CRC-32 is used?

And is it to be applied on a file containing the hex values? Or to what?

And WHICH "Unicode" are we talking about?



on a .txt file containing "plain" "USBSTOR\DISK&VEN_LEXAR&PROD_JD_LIGHTNING_II&REV_1100\AA04015900000158&0":

	  0001 0203 0405 0607 0809 0A0B 0C0D 0E0F - 0123456789ABCDEF
0x00: 5553 4253 544F 525C 4449 534B 2656 454E - USBSTOR\DISK&VEN
0x10: 5F4C 4558 4152 2650 524F 445F 4A44 5F4C - _LEXAR&PROD_JD_L
0x20: 4947 4854 4E49 4E47 5F49 4926 5245 565F - IGHTNING_II&REV_
0x30: 3131 3030 5C41 4130 3430 3135 3930 3030 - 1100\AA040159000
0x40: 3030 3135 3826 30 - 00158&0

, I get: (rehash -none -crc32 originalascii.txt )

CRC-32	   : BAA13B1F

if I use this:



As follows:

uniconv ASCII originalascii.txt Unicode11:big-endian test.txt

getting a file in UNICODE as described before:

	  0001 0203 0405 0607 0809 0A0B 0C0D 0E0F - 0123456789ABCDEF
0x00: 0055 0053 0042 0053 0054 004F 0052 005C - .U.S.B.S.T.O.R.\
0x10: 0044 0049 0053 004B 0026 0056 0045 004E - .D.I.S.K.&.V.E.N
0x20: 005F 004C 0045 0058 0041 0052 0026 0050 - ._.L.E.X.A.R.&.P
0x30: 0052 004F 0044 005F 004A 0044 005F 004C - .R.O.D._.J.D._.L
0x40: 0049 0047 0048 0054 004E 0049 004E 0047 - .I.G.H.T.N.I.N.G
0x50: 005F 0049 0049 0026 0052 0045 0056 005F - ._.I.I.&.R.E.V._
0x60: 0031 0031 0030 0030 005C 0041 0041 0030 - .\.A.A.0
0x70: 0034 0030 0031 0035 0039 0030 0030 0030 - .
0x80: 0030 0030 0031 0035 0038 0026 0030 - .

I get:

CRC-32	   : 28FD18C3

If I do it via batch:

FOR %%A IN (
Arabic ASCII big-endian Big5 BMP ChineseAutoDetect
CNS-11643 CNS-11643-1986 cp1251 cp1252 cp437 cp850 cp932
ISO-2022-JP ISO-2022-KR ISOLatinCyrillic JapaneseAutoDetect
Java JIS_X0201 JIS_X_0208 KoreanAutoDetect Latin1 Latin2
Latin3 Latin4 Latin5 Latin6 little-endian Shift-JIS Thai
UCS2 Unicode11:big-endian Unicode11:BOM:big-endian
Unicode11:BOM:Java Unicode11:BOM:little-endian
Unicode11:BOM:UCS2 Unicode11:BOM:UTF7 Unicode11:BOM:UTF8
Unicode11:Java Unicode11:little-endian Unicode11:UCS2
Unicode11:UTF7 Unicode11:UTF8 Unicode20:BOM:Java
Unicode20:BOM:UTF7 Unicode20:BOM:UTF8 Unicode20:little-endian
Unicode20:UCS2 UTF7 UTF8
) DO (
ECHO %%A>>result.txt
uniconv ASCII originalascii.txt %%A test.txt
rehash -none -crc32 test.txt>>result.txt

with ALL available formats in UNICONV, I cannot find ANYTHING similar to "16f722a4" :w00t:

NOT even changing:

rehash -none -crc32 test.txt>>result.txt


rehash test.txt>>result.txt

(i.e. using ALL hashing algorithms in rehash) :blink:



Edited by jaclaz
Link to comment
Share on other sites

Try reading the code in post #90, that's the function, which produces the hash. I couldn't get a chance yet to attempt to understand it and create similar code in AutoIt for example.

From what I understood in this matter, that function is far from any famous CRC32 calculation algorithm, even different than RtlComputeCrc32 function, which ReactOS uses and is present in NTDLL.DLL too.

Attached is a program, made by someone else, while we tested hash calculation. 2k button uses Win 2K ParentID prefix hash calculation. It may become handy for someone.


Link to comment
Share on other sites

Try reading the code in post #90, that's the function, which produces the hash.

Yep. :)

What I was trying indirectly to confirm is that the above hash calculation is NOT a CRC32 one:

If there is anyone interested- here is the code in C, which calculates CRC32 hash:


Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...