The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
|
|
Does Encryption add Length?
Posted: 25 Mar 09 10:07 AM
|
If I'm using the SLXRWEL dll to ecrypt a field, is this going to add length to the values?
So if I'm encrypting values that are 16 characters long, should I make the column VARCHAR2(32) instead? |
|
|
|
Re: Does Encryption add Length?
Posted: 26 Mar 09 1:30 PM
|
So I answered my question by using test values. It does increase the length.
But by how much? I tested with 16 characters and it went out to 35. I tested with 12 and it went out to 26. Is there a pattern to how much it increases? |
|
|
| |
| |
|
Re: Does Encryption add Length?
Posted: 27 Mar 09 10:06 AM
|
Excellent info.
Just an hour ago, I noticed the password field in our other database is Varchar2(240). So I was planning on doing what you said.
|
|
|
|
Re: Does Encryption add Length?
Posted: 29 Mar 09 12:54 AM
|
I think what you're seeing there is just the result of simple hex-encoding - twice the length of the original string, plus two or three additional bytes for the length specifier (or null terminator, whichever is being used). If the seed string or the password is longer than the string being encrypted, then the result will be twice the length of whatever the longest string is.
In other words, if you have a 16-character string that you want to store encrypted by SLXRWEL, you should be safe storing it in a 40-byte field, as long as the password you're using is 16 characters or less.
As always, this information should not be used as the basis for an actual cash wager... |
|
|
|