|
-
Feb 12th, 2008, 08:27 PM
#1
Thread Starter
Hyperactive Member
[Resolved] Mystery Strings?
Are there characters in the unicode table that can ruin an otherwise healthy string as it is being written to the registry, or as it is sent to a text box?
I ask because I have written a routine that uses a Blowfish Encryption class to conceal a password (and other info) which is then stored in the registry as a REG_SZ value (string). The routine works perfectly most of the time, but on rare instances, the output is truncated as it is being written to the registry or to a simple text box.
I have tested the encryption routine by encrypting a string and then immediately decrypting it, followed by comparing the original string to the decrypted string, in memory. They are the same up to the moment they are being written to a text box (or registry) using something as simple as the code below:
Code:
Text1.Text = EncryptedHash
Is it possible that VB6 (SP6) is trying to interpret the string as it is being written out, and then stumbling on some unprintable character that is causing the line to be erased, in part? The line I am working with currently is 120 characters while in memory, but just 9 by the time it hits the text box.
Any insight concerning this puzzle would be most helpful. Thanks!
Last edited by Quiver318; Feb 13th, 2008 at 06:41 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|