excel - Convert a 300 character string to a uniquely identifiable 8 character string in VBA -


I have designed a user interface for a device, where the user must enter a "name" which is a maximum of 300 characters Is long, and the tool generates a text file ("name" .txt) which is then uploaded to "server" (mainframe and unix). I want to shorten the 300 character string to a specific identifiable 8 character string (mainly in the mainframe), just like some small size using some sort of hashing algorithm. I got a SHA1 implementation but the resulting string is 40 characters long Can someone suggest VBA implementation for an algorithm?

The resultant string requirement is 8 characters long; I guess it should be appropriate that we have a border on the size of the input string

I think Jane's idea should work properly. If destroying SHA-1 hash is not your thing, then you can use CRC-32 (32bit ~ 8 ACI character 0 ... F). (You can try to use) As far as the CRC-32 conflict is concerned, it is not as safe, but it is at your end.


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -