Subject Re: [firebird-support] Querying Encrypted fields?
Author Riste Pejov
Lee Jenkins wrote:

> > Oops. Just checked and we do not keep the entire track data in the db.
> > Only a string which hold credit card number/exp/discretionary data
> portion
> > of track 2 data such as:
> >
> > 4005550000000019=0809222040303033
> Actually, that should be:
> 4005550000000019=0809
> So for us to concantenate the cc number with the exp date is simple enough
> before submitting it to a query!
> Excellent!

Well, there are alot of documents refering to encrypting data into
databases. One of the cleanest solutions is to do a hash on the values
that you want to search for and store the hash into the DB so after that
you just hash the search value and search for it. You can do a hash on a
partial value or on the full value. depending of your requirements.

further reading:

best regards,

Riste Pejov
Card Management System
National Payment Card
Kuzman Josifovski Pitu br.1
tel:++ 389 2 3293 826
Skopje, MKD