-
Notifications
You must be signed in to change notification settings - Fork 60
docs: improvements to slot access codes how-to #268
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -16,31 +16,30 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |||||
| See the License for the specific language governing permissions and | ||||||
| limitations under the License. --> | ||||||
|
|
||||||
| # How to set, reset, remove, and use slot access codes | ||||||
| # How to set, modify, remove, and use slot access codes | ||||||
|
|
||||||
| The YubiKey's OTP application [slots](xref:OtpSlots) can be protected by a six-byte access code. Once a slot is | ||||||
| configured with an access code, that slot cannot be reconfigured in any way unless the correct access code in provided | ||||||
| configured with an access code, that slot cannot be reconfigured in any way unless the correct access code is provided | ||||||
| during the reconfiguration operation. | ||||||
|
|
||||||
| > [!NOTE] | ||||||
| > Attempting to perform an OTP application configuration operation without providing the correct access code will result | ||||||
| > in the following exception: | ||||||
| > | ||||||
| > ```System.InvalidOperationException has been thrown.``` | ||||||
| > ```YubiKey Operation Failed. [Warning, state of non-volatile memory is unchanged.]``` | ||||||
| Attempting to perform a slot configuration operation without providing the correct access code will result | ||||||
| in the following exception: | ||||||
|
|
||||||
| ```System.InvalidOperationException has been thrown.``` | ||||||
| ```YubiKey Operation Failed. [Warning, state of non-volatile memory is unchanged.]``` | ||||||
|
|
||||||
| So for example, let's say that the short press slot of a key was configured with a Yubico OTP credential and a slot | ||||||
| access code. If you want to reconfigure the slot with an OATH HOTP credential, you will have to provide the slot's | ||||||
| access code when calling ``ConfigureHotp()``. | ||||||
| ## Slot access code properties | ||||||
|
|
||||||
| Access codes can only be set, reset, or removed during another slot configuration operation: | ||||||
| Access codes can only be set, modified, or removed during one of the following slot configuration operations: | ||||||
|
|
||||||
| - [ConfigureYubicoOtp()](xref:Yubico.YubiKey.Otp.OtpSession.ConfigureYubicoOtp%28Yubico.YubiKey.Otp.Slot%29) | ||||||
| - [ConfigureHotp()](xref:Yubico.YubiKey.Otp.OtpSession.ConfigureHotp%28Yubico.YubiKey.Otp.Slot%29) | ||||||
| - [ConfigureChallengeResponse()](xref:Yubico.YubiKey.Otp.OtpSession.ConfigureChallengeResponse%28Yubico.YubiKey.Otp.Slot%29) | ||||||
| - [ConfigureStaticPassword()](xref:Yubico.YubiKey.Otp.OtpSession.ConfigureStaticPassword%28Yubico.YubiKey.Otp.Slot%29) | ||||||
| - [UpdateSlot()](xref:Yubico.YubiKey.Otp.OtpSession.UpdateSlot%28Yubico.YubiKey.Otp.Slot%29) | ||||||
|
|
||||||
| Therefore, the **only** way to modify a slot access code that doesn't result in the reconfiguration of the slot's current cryptographic credential is to use ``UpdateSlot()``. However, calling ``UpdateSlot()`` will revert a number of other slot settings (such as ``SetAppendCarriageReturn()``) to their default states unless otherwise specified during the operation. See [How to update slot settings](xref:OtpUpdateSlot) for more information. | ||||||
|
||||||
| Therefore, the **only** way to modify a slot access code that doesn't result in the reconfiguration of the slot's current cryptographic credential is to use ``UpdateSlot()``. However, calling ``UpdateSlot()`` will revert a number of other slot settings (such as ``SetAppendCarriageReturn()``) to their default states unless otherwise specified during the operation. See [How to update slot settings](xref:OtpUpdateSlot) for more information. | |
| Among these, the **only** way to modify a slot access code that doesn't result in the reconfiguration of the slot's current cryptographic credential is to use ``UpdateSlot()``. However, calling ``UpdateSlot()`` will revert a number of other slot settings (such as ``SetAppendCarriageReturn()``) to their default states unless otherwise specified during the operation. See [How to update slot settings](xref:OtpUpdateSlot) for more information. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about something like this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I reworked this sentence--let me know if you like the new version better.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you clarify the meaning of this header?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I see its coming from line 52 prior to the additions.
Was this change intended?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't update the header at all, but I did move some things from the intro section into this one, so that's probably why it shows up as green.