APM Policy - Accept user 1, write user 2

I have an ask from our security team to use an APM policy to accept connections to a database LTM VIP from user 1 and once successfully authenticated, write to the database using user 2 credentials - can this be done?

I have very little experience with APM and nothing like this currently being done in our F5 environment.

Thanks

in principle nothing is stopping your from authenticating with user1 and then setting up the SSO credentials to user2. password will then have to be hard coded or collected during login.

but i wonder how the database “writing” is done, is there a webserver with authentication in front or such?