Record the common name in TLS metadata
It is useful to be able to save the client cert's Common Name for auditing purposes when using a central CA. This adds a "common_name" value to the Metadata structure passed from login.
This commit is contained in:
parent
f355049ef1
commit
e3d3012795
|
@ -62,6 +62,7 @@ func (b *backend) pathLogin(
|
|||
DisplayName: matched.Entry.DisplayName,
|
||||
Metadata: map[string]string{
|
||||
"cert_name": matched.Entry.Name,
|
||||
"common_name": connState.PeerCertificates[0].Subject.CommonName,
|
||||
},
|
||||
LeaseOptions: logical.LeaseOptions{
|
||||
Renewable: true,
|
||||
|
|
Loading…
Reference in a new issue