Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Ideas for storing numeric data encrypted?
Message
From
14/06/2018 12:12:22
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
14/06/2018 11:52:49
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012 R2
Network:
Windows Server 2012 R2
Database:
Visual FoxPro
Application:
Desktop
Virtual environment:
VMWare
Miscellaneous
Thread ID:
01660727
Message ID:
01660728
Views:
98
>Hi,
>
>Client has asked that key fields in their tables be encrypted (native VFP tables). This is fairly easy to do via wwEncryption from WestWind - at least for text data.
>
>For numeric data, the data has to be converted to a string, then encrypted and then stored as a string (same goes for date data).
>
>Question: instead of encrypting the numeric data, is there any other field type that I could convert the data to such that it would obfuscate it (render it less meaningful for the casual hacker) and to save a round trip through converting to string, encrypting and back again?
>
>I thought of storing a log value to the table but I think the amount of decimals stored is going to throw off the conversions.
>
>Anyhow, just thought I would ask in case someone who does more "mathy" stuff knows if VFP has some capability I am not aware of.
>
>Thanks,

Short answer is no (I assume "casual hacker" is not a beginner).

It also depends on the meaning of "numeric". For example, if the hacker is amateur enough, and the numeric is a double, then you could use it as datetime (what a datetime is behind the scenes). You could do bit shifting and rotating, bintoc, ctobin with a char field etc. However all of these would have back and forth overhead, converting to string and encrypting might just be the way to go. Probably, it would be easier to transfer the data to another backend and use it.

PS: Conversion + encryption overhead is generally negligible (of course it may not if what you often do is to insert lots of new data). Indexed searches on such a column would also be tricky. And you should keep in mind that string operations in VFP is very slow.

PS: And it is questionable why the key fields be encrypted.
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform