Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Urgent qn on DBMS_OBFUSCATION_TOOLKIT
nkt_sg_at_hotmail.com writes:
> Hi
> I have a question regarding the usage of DBMS_OBFUSCATION_TOOLKIT package.
>
> To encrypt a data string, I will call procedure
> DBMS_OBFUSCATION_TOOLKIT .DESEncrypt, and passing in the input_string(pad to the
> nearest 8 bytes), supply the key_string and it will generate the
> encrypted_string.
>
> My questions are
> 1) the key_string that I supply, must it be 56bits ie 7 bytes in length? Is it
> fixed?
The key must be at least 8 bytes. DES uses 64, not 56. The key can be anything that you want. I would use a good random number generator or the GetKey interface (available in 8i release 3, IIRC) to generate the key.
BTW, the requirement to pad the input string was removed in 8i release 3.
> 2)what is the length of the generated encrypted_string, in terms of bytes?.
>
> for e.g,
> if I supplied a input_string of 16 bytes, what is the length of the output
> encrypted_string? I will need this length information so as to define my table's
> field size.
The returned length will be the original length plus 1 byte.
Rick
-- Rick Wessman Security Assurance Group Oracle Corporation Rick.Wessman_at_oracle.com The opinions expressed above are mine and do not necessarily reflect those of Oracle Corporation.Received on Tue Sep 04 2001 - 09:41:06 CDT