Skip to content

Configure custom PIV slot for hardware key support#31732

Merged
Joerger merged 6 commits intomasterfrom
joerger/custom-piv-slot
Oct 11, 2023
Merged

Configure custom PIV slot for hardware key support#31732
Joerger merged 6 commits intomasterfrom
joerger/custom-piv-slot

Conversation

@Joerger
Copy link
Copy Markdown
Contributor

@Joerger Joerger commented Sep 11, 2023

Add support for configuring a custom PIV slot for hardware key support through client or server settings:

  • tsh --piv-slot=9d or TELEPORT_PIV_SLOT=9d tsh
  • teleport.auth_service.authentication.piv_slot: 9a
  • cluster_auth_preference.piv_slot: 9a

Other changes:

  • Refactor client retry-with-hardwarekey logic.

e PR: https://github.com/gravitational/teleport.e/pull/2191

Follow up PR: #32275

@github-actions github-actions Bot requested review from tcsc and zmb3 September 11, 2023 20:20
@github-actions github-actions Bot added size/md tsh tsh - Teleport's command line tool for logging into nodes running Teleport. labels Sep 11, 2023
@Joerger Joerger force-pushed the joerger/custom-piv-slot branch 3 times, most recently from 5e73ce0 to 1c50d89 Compare September 11, 2023 20:58
@Joerger Joerger marked this pull request as draft September 14, 2023 21:00
@Joerger Joerger force-pushed the joerger/custom-piv-slot branch from 9c2adad to f2ac3e0 Compare September 20, 2023 00:45
@Joerger Joerger changed the title Add tsh --piv-slot Configure custom PIV slot for hardware key support Sep 20, 2023
@Joerger Joerger force-pushed the joerger/custom-piv-slot branch from f2ac3e0 to 3504aa1 Compare September 20, 2023 00:50
@Joerger Joerger marked this pull request as ready for review September 20, 2023 00:51
@github-actions github-actions Bot added the rfd Request for Discussion label Sep 20, 2023
@Joerger Joerger force-pushed the joerger/custom-piv-slot branch from 582b9cf to 7aeaa0d Compare September 20, 2023 01:25
Copy link
Copy Markdown
Member

@ravicious ravicious left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't manage to get through the whole PR today, I'll continue the review tomorrow.

Comment thread lib/client/api.go Outdated
@ravicious ravicious self-requested a review September 20, 2023 14:15
@Joerger
Copy link
Copy Markdown
Contributor Author

Joerger commented Sep 20, 2023

I didn't manage to get through the whole PR today, I'll continue the review tomorrow.

Thanks Rafael, this PR grew larger than I intended. I'll try splitting it up into 1 or 2 more PRs for easier review.

@Joerger Joerger force-pushed the joerger/custom-piv-slot branch from e41df61 to b6cbf9b Compare September 20, 2023 17:55
@Joerger Joerger changed the base branch from master to joerger/custom-piv-slot-base September 20, 2023 23:20
@Joerger Joerger force-pushed the joerger/custom-piv-slot branch 3 times, most recently from 4b9a235 to 8060194 Compare September 20, 2023 23:39
@Joerger Joerger force-pushed the joerger/custom-piv-slot branch 2 times, most recently from 3c36c37 to a3a1509 Compare September 27, 2023 19:30
@Joerger Joerger changed the base branch from joerger/custom-piv-slot-base to joerger/piv-client-side-attestation September 27, 2023 19:31
@Joerger Joerger force-pushed the joerger/piv-client-side-attestation branch from 97d3f06 to 550cf20 Compare September 28, 2023 18:25
Base automatically changed from joerger/piv-client-side-attestation to master September 29, 2023 00:27
@Joerger Joerger force-pushed the joerger/custom-piv-slot branch 2 times, most recently from f660dbc to bdccdc6 Compare September 29, 2023 18:30
@Joerger
Copy link
Copy Markdown
Contributor Author

Joerger commented Sep 29, 2023

@tcsc @zmb3 friendly ping to review

@Joerger Joerger force-pushed the joerger/custom-piv-slot branch from bece00f to f8b0b73 Compare October 9, 2023 18:22
@Joerger
Copy link
Copy Markdown
Contributor Author

Joerger commented Oct 9, 2023

@tcsc @zmb3 friendly ping

Comment thread api/utils/keys/yubikey.go Outdated
Comment thread api/utils/keys/yubikey.go Outdated
Comment thread api/utils/keys/yubikey.go
Comment thread api/utils/keys/yubikey_common.go
@Joerger Joerger enabled auto-merge October 11, 2023 01:17
@Joerger Joerger added this pull request to the merge queue Oct 11, 2023
Merged via the queue into master with commit a36d4d1 Oct 11, 2023
@Joerger Joerger deleted the joerger/custom-piv-slot branch October 11, 2023 01:54
Joerger added a commit that referenced this pull request Oct 12, 2023
* Update RFD.

* Add custom PIV slot logic.

* Add custom piv slot to cluster auth preference.

* Fix error handling of parsing private key policy errors.

* Add new PIVSlot string type.
Joerger added a commit that referenced this pull request Oct 14, 2023
* Update RFD.

* Add custom PIV slot logic.

* Add custom piv slot to cluster auth preference.

* Fix error handling of parsing private key policy errors.

* Add new PIVSlot string type.
github-merge-queue Bot pushed a commit that referenced this pull request Oct 14, 2023
* Update RFD.

* Add custom PIV slot logic.

* Add custom piv slot to cluster auth preference.

* Fix error handling of parsing private key policy errors.

* Add new PIVSlot string type.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rfd Request for Discussion size/md tsh tsh - Teleport's command line tool for logging into nodes running Teleport.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants