APM Variable Assign force to Lowercase

Good Afternoon

I have an APM policy grabbing the username from a certificate - how can I force this to lowercase? regexp {(?x)(CN)=DOMAIN.([^,]+)} [mcget {session.ssl.cert.subject}] match CN USER; return $USER

Can’t test it right now, but off the top of my head, have you tried wrapping the $USER like this:

[string tolower $USER]

? or perhaps the mcget:

[string tolower [mcget {session.ssl.cert.subject}]]

.

this worked perfectly - thank you!

regexp {(?x)(CN)=lab.([^,]+)} [mcget {session.ssl.cert.subject}] match CN USER; return [string tolower $USER]