Is it possible to encrypt certain fields in user data in Keycloak?

For one of our application we are making use of Keycloak as the IAM. With the privacy concerns and regulations like GDPR it’s kind of mandatory to ensure the data is protected and encrypted at rest. We could encrypt the entire database but that still doesn’t address the need entirely as anyone with database access could still see the info in plain text.

Currently I haven’t seen any such configuration, is it possible to write a custom adapter which can do this?

We are using Keycloak 17.0 and using MariaDB 10.6 as the database.
Any guidance/advices are much appreciated.

@dasniko, @xgp any suggestions?