We have several column in a legacy db that are stored as AES_ENCRYPTed
blobs. I would like to make a subclass of BLOBCol that will handle
this for me.
My plan would be to have it wrap all accesses with AES_DECRYPT(SSN,
'password') and all sets with AES_ENCRYPT(value, 'password'). Is there
a good way to do this?

I have already tested
Instructors.select(func.AES_DECRYPT(Instructors.q.SSN,'password').endswith('9'))
which works as expected, but the SSN atributes are still encrypted. I
would like to make a new column type so that all the goodies like
bySSN() will work. Also, I dont want to have to put __set_SSN and
__get_SSN in each class that needs them. If I  cant easily make a new
column type, is there an easy way to execute an sqlbuilder.func call?

Thank-you,
Mathias Stearn

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
sqlobject-discuss mailing list
sqlobject-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sqlobject-discuss

Reply via email to