Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Encrypting a number into another number?

Re: Encrypting a number into another number?

From: Daniel Morgan <damorgan_at_exxesolutions.com>
Date: Wed, 27 Aug 2003 09:16:54 -0700
Message-ID: <3F4CD976.75C5DB50@exxesolutions.com>


Pomme-granite wrote:

> I need a simple PL/SQL algorithm for encrypting one integer (up to 6
> digits) into another 6 digit integer, so DBMS_OBFUSCATION_TOOLKIT
> isn't of use. I have already written something which uses simple
> XORing, Newvalue := InputValue XOR bitmask, but patterns still emerge
> for consequetive InputValues.
>
> What I need doesn't have to be too secure, but I do need to give a
> more diverse range in output than simple XORing. Any ideas?
>
> Thanks
> Pomme-granite

Create a table with six columns and use DBMS_RANDOM to load all columns for 1000 rows.

Then arbitrarily make a decision such as:

first digit equals the first digit of the 75th row. second digit equals the second digit of the 577th row. third digit equals the third digit of the 902nd row. etc.

Then take the decryption function and, write it as a local function in a package body or as an operator and wrap it.

No one other than a government agency with massive computing power will be able to decrypt it.

--
Daniel Morgan
http://www.outreach.washington.edu/extinfo/certprog/oad/oad_crs.asp
http://www.outreach.washington.edu/extinfo/certprog/aoa/aoa_main.asp
damorgan_at_x.washington.edu
(replace 'x' with a 'u' to reply)
Received on Wed Aug 27 2003 - 11:16:54 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US