Is there a flag to detect if the request came from a client after doing mtls?

Hi, This is more of a discussion question.

Previously I was using mtls but mtls is not supported everywhere so I switched to Authelia. Now, I have the Authelia page in front of every thing and it’s not transparent like mtls. I am trying to figure out if in Caddy it’s possible to detect whether a request is coming from a client that did mtls authentication ?

If this is possible, Then I can selectively bypass Authelia and use mtls where ever possible and Authelia if mtls was not used.

I think http.request.tls may help here. I don’t know if these fields will contain the details from the outer mtls auth or the internal normal tls auth :thinking:

I will test this in a few hours