well anything means anything, right? 😄 Can you be a little more specific or give an example? You can do regex on a string, yes - where exactly is your issue?
Hi Andreas,
Thanks for giving me the opportunity to ask.
so here is the issue:
in Database, all the data are encrypted (e.g User Name and emails as well)
and its good to mention that I'm using MYSQL.
is there any way you can think of or suggest or have an idea, to perform regex search on top of this encrypted data?
For UserId 1, First Name is "Nikole" and UserId 2 is "Nokia",
what I want to achieve is, I would search with "No" and it should give me the UserId 2.
The catch is, I cannot directly search with the keyword, as it's stored in database encrypted.
Got it - well I don't see a way to do it directly in MySQL. You would have to walk through the whole table, decrypt each record and perform your regex search on it...
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hi Saikat,
well anything means anything, right? 😄 Can you be a little more specific or give an example? You can do regex on a string, yes - where exactly is your issue?
Hi Andreas,
Thanks for giving me the opportunity to ask.
so here is the issue:
in Database, all the data are encrypted (e.g User Name and emails as well)
and its good to mention that I'm using MYSQL.
is there any way you can think of or suggest or have an idea, to perform regex search on top of this encrypted data?
for the discussion lets take an example:
Users Table:
UserId | FirstName | LastName |
---|----------|-----------|---
1|4vzrOlgFJ15JVuEwxey6Vw==| 2rqKd00JJEvn0M3HMzuaDg==|
2|4vzrOlgFJ15JVuEwxey6Vw==| 2rqKd00JJEvn0M3HMzuaDg==|
In here say:
For UserId 1, First Name is "Nikole" and UserId 2 is "Nokia",
what I want to achieve is, I would search with "No" and it should give me the UserId 2.
The catch is, I cannot directly search with the keyword, as it's stored in database encrypted.
What encryption do you use?
aes256 with output_encoding base64 & the secret & Iv key used for this, is again made with pbkdf2Sync with sha512 digest & keylength of 100000.
Got it - well I don't see a way to do it directly in MySQL. You would have to walk through the whole table, decrypt each record and perform your regex search on it...