FoxPro Programming
wwEncryption and accented chars
Gravatar is a globally recognized avatar based on your email address. wwEncryption and accented chars
  Albert Gostick
  All
  Feb 21, 2018 @ 12:16pm

Hi Rick,

I have incorporated wwEncryption into the app to encrypt some fields. I then wrote a utility to test if all the data would succeed in a "round trip" of the data - encrypt, decrypt and then compare to the original.

The only records that have problems are those with accented characters.

My CPCURRENT() setting is 1252 which is what the tables are as well. Does the function need some other code page etc?

Thanks, Albert

Gravatar is a globally recognized avatar based on your email address. re: wwEncryption and accented chars
  Rick Strahl
  Albert Gostick
  Feb 21, 2018 @ 01:40pm

Example please?

You mean the input value has accented characters?

+++ Rick ---

Gravatar is a globally recognized avatar based on your email address. re: wwEncryption and accented chars
  Albert Gostick
  Rick Strahl
  Feb 21, 2018 @ 01:49pm

Yes, input string has accented chars:

input: José Pereira

encrypted (not that this matters): AJRrJhN928EJIpaE7HVG8w==

decrypted: Jos? Pereira

Does STRCONV() have to be used on the string before sending off and/or after getting back from the function?

Albert

Gravatar is a globally recognized avatar based on your email address. re: wwEncryption and accented chars
  Rick Strahl
  Albert Gostick
  Feb 21, 2018 @ 01:51pm

Found the problem - you'll need an update to the DLL. Basically the code in .NET uses ASCII encoding which doesn't account for the code page. Using UTF-8 should work with all upper ANSI characters in all languages and that works now.

I'll post it in a minute, but there's another bug in that needs addressing.

+++ Rick ---

Gravatar is a globally recognized avatar based on your email address. re: wwEncryption and accented chars
  Albert Gostick
  Rick Strahl
  Feb 21, 2018 @ 02:29pm

Hi Rick,

Not able to load ( ERROR "Unable to load wwDotNetBridge: Unable to load Clr Instance. 0x80131515: Unknown error 0x80131515 " )

I think I have seen this error on the board here but what's the quick answer? Am leaving for the day, back Friday. No panic if it requires a more formal installation as I can wait.

Albert

Gravatar is a globally recognized avatar based on your email address. re: wwEncryption and accented chars
  Albert Gostick
  Rick Strahl
  Feb 23, 2018 @ 03:01pm

That be it...thanks

© 1996-2024