PIV login enforcement#15874
Conversation
|
@codingllama Could you give the current re-login flow a quick look? This is probably more in line with what you originally had in mind too. During implementation I realized it would be much easier and simpler to wire attestation logic directly into login (rather than #14774 (comment)). This way, we don't need to add any new endpoints, or worry about handling certificates with reduced privileges. Right now, the flow is simply: Another benefit of this approach is that we have a clear lifetime for attestations stored in the backend - the login certificate TTL. Once we agree on a solution in this PR, I'll update the RFD to reflect it. |
aaf6f73 to
8dfa264
Compare
Yep, that sounds even better to me. Is there anything in particular in the PR you'd like me to look at? |
568c473 to
c566eec
Compare
e55f6d7 to
1ccd9f7
Compare
0c308da to
c78104c
Compare
872bc4b to
91649a4
Compare
f3f5d56 to
ff839ed
Compare
91649a4 to
06b0e9a
Compare
5936f73 to
8501c7b
Compare
52c0fa0 to
659dcdc
Compare
8501c7b to
d4f4638
Compare
3cf42de to
f2676af
Compare
1351549 to
950a80e
Compare
f2676af to
fe700d0
Compare
950a80e to
5e83f77
Compare
fe700d0 to
bc70db2
Compare
… from mac and windows builds.
codingllama
left a comment
There was a problem hiding this comment.
Drive-by review, looking at a couple of changes that caught my eye.
protobuf oneof fields that json/encoding does not support.
90c0df2 to
2eed478
Compare
Part 3 for implementing #14774
Changes:
PrivateKeyPolicyextension for TLS and SSH certificates, and enforce them for every API request.hardware_key/hardware_key_touchenforcement during certificate signing operations.AttestationRequestfield. When provided, the auth server will verify the attestation data, sign the certificates with the proper key policy extension, and store the attestation for future checksrequire_session_mfasettings to see if attestation is required. If so, it will try to get a valid attestation from the signing request, or from a previously stored attestation in `/key_attestations/tshand Teleport Connect to automatically enable hardware key login when needed.private_key_policyfield to Ping response so that a cluster's default private key policy can be discovered.tshand Teleport Connect. Specifically:sshLoginFuncfunction of typefunc(context.Context, *keys.PrivateKey) (*auth.SSHLoginResponse, error)SSHLoginfunction, which takes ansshLoginFunc, prepares a private key for login, sends it through the login func, parses the response and returns a new client key.e PR - https://github.com/gravitational/teleport.e/pull/528
Fixes #10489