cossacklabs / acra

Database security suite. Database proxy with field-level encryption, search through encrypted data, SQL injections prevention, intrusion detection, honeypots. Supports client-side and proxy-side ("transparent") encryption. SQL, NoSQL.
https://www.cossacklabs.com/acra/
Apache License 2.0
1.33k stars 128 forks source link

Support PostgreSQL double qouted columns #590

Closed Zhaars closed 1 year ago

Zhaars commented 1 year ago

This PR contains only sqlparser changes to fix the open issue. During debugging we faced that sqlparser flow has incorrect flow for parsing statements as WHERE "column" = 'value' as it looks on value rule instead of column_name.

In this PR two new types were introduced

Checklist

Zhaars commented 1 year ago

@Lagovas I added a couple of unit tests to cover correct matching with tables from config. Please let me know if you want more tests to be added.