Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP implementation of the Cipher encryption
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01192734
Message ID:
01192960
Views:
19
I want to encrypt password string.
cOpenPassword = "dataworld4Asistdbc"
cKeyStr       = "qwertyuopasdfghjkl"

cEncryptPass = encrypt(cKeyStr, cOpenPassword)
?  decrypt(cEncryptPass, cKeyStr) && return  dataworld4Asistdbc [correct]


*** same open password different key string

cOpenPassword = "dataworld4Asistdbc"
cKeyStr       = "##################"

cEncryptPass = encrypt(cKeyStr, cOpenPassword)
?  decrypt(cEncryptPass, cKeyStr) && return  {`utnsoc5`tjrugmb [wrong]


*** diffrent open password same key string. Only one char is different in openpassword.

cOpenPassword = "dataworld4sistdbc"
cKeyStr 	  = "#################"

cEncryptPass = encrypt(cKeyStr, cOpenPassword)
?  decrypt(cEncryptPass, cKeyStr) && return  dataworld4sistdbc [correct]
>Which one are you encrypting, cPassword with cKeyStr or oposite?
>
>>If I used a key string having a different character , the chipher give correct result
>>
>>
>>cPassword = "dataworld4Asistdbc"
>>cKeyStr =   "qwertyuopasdfghjkl"
>>
>>? decrypt(encrypt(cKeyStr, cPassword), cKeyStr) && return  dataworld4Asistdbc [correct]
>>
>>*** same password different key string
>>
>>cKeyStr =   "##################"
>>? decrypt(encrypt(cKeyStr, cPassword), cKeyStr) && return  {`utnsoc5`tjrugmb [wrong]
>>
>>
>>
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform