1
0
Fork 0

Merge pull request 'Add "AUTH_TYPE" environment variable when client cert is present' (#14) from khuxkm/molly-brown:master into master

Reviewed-on: https://tildegit.org/solderpunk/molly-brown/pulls/14
This commit is contained in:
Solderpunk 2020-12-27 20:21:49 +00:00
commit 3d4d830e98

View file

@ -191,6 +191,8 @@ func prepareGatewayVariables(config Config, URL *url.URL, conn net.Conn) map[str
vars["TLS_CLIENT_ISSUER_CN"] = cert.Issuer.CommonName
vars["TLS_CLIENT_SUBJECT"] = cert.Subject.String()
vars["TLS_CLIENT_SUBJECT_CN"] = cert.Subject.CommonName
// To make it easier to detect when a cert is present
vars["AUTH_TYPE"] = "Certificate"
}
return vars
}