Subject | RE: [firebird-support] Encryption |
---|---|
Author | Leyne, Sean |
Post date | 2009-06-16T21:34:56Z |
Dmitry,
Sean
> >> What kind of SQL statements? Sum? Max? Min? Huh!While this approach will work, it is far to "naïve" to have real world use.
> >
> > SELECT ... FROM ... WHERE FIELDA BETWEEN :X and :Y
>
> Nothing is impossible for real perverts. Let's take set of values of
> fieldx, sort it and assign an sequenced integer value to each value.
> After that we encrypt fieldx and put it into database along with this
> integer value as fielda.
> Since then we can find out appropriate integers using encrypted
> fieldx and put them into the query for fielda.
> For example:
>
> 1 Ann
> 2 Dimitry
> 3 Sean
>
> select * from ... where name between 'Ann' and 'Sean'
> is equivalent to
> select * from ... where number between 1 and 3.
Sean