Historization of user rights for audits

Hi all,

at our customer we have specific requirements for audits and ideally it would be possible to track changes in user managements.

Is there a way to find out which users were part of which group when and what roles were provided to the groups on what projects?
We would not only need the most recent setting of rights, but also would like to see what changed and who was able to access what when.

Do we logg these changes in postgre?
Thanks