michelp / pgsodium

Modern cryptography for PostgreSQL using libsodium.
Other
555 stars 32 forks source link

Fix the 'role does not exist' error caused by uppercase characters in… #90

Closed aliyoge closed 1 year ago

aliyoge commented 1 year ago

When the current session_user contains uppercase characters, calling the update_masks and create_mask_view functions will throw a 'role does not exist' error.

We need to use quote_ident() to preserve the case, and ensure the view_owner stored username is consistent with session_user, containing the correct case.

image image
michelp commented 1 year ago

Sorry for delay! I approved test workflow, looks like some function signature checks are missing updates: https://github.com/michelp/pgsodium/pull/90/checks

aliyoge commented 1 year ago

Sorry, I just updated the signatures of these functions. Could you please check them again?