Skip to content

PIV Errors are not displayed correctly #3701

@RyAndrew

Description

@RyAndrew

Describe the bug

Okta customer case # 00024632

Background:
I am using an embedded widget with a PIV/CAC login.
I recently upgraded to OIE and the latest version of the widget. We are in the process of rebuilding all login pages with all the interaction code grant and the newest okta library versions. The goal is a nice clean fresh start.
The topic of error handling the PIV login is the current focus.

Expected Outcome
When the browser PIV certificate selection prompt is displayed, and the user clicks cancel, I can see a nicely formatted json error in the browser console. This is what I would expect to see rendered into the widget.

Actual Outcome
Error displayed: "OAuthError: Your client is configured to use the interaction code flow and user interaction is required to complete the request."

At this time we are attempting to show the correct PIV error when a user cancels or the verification fails, but the only error Okta sends back is
image

Example Code
Example app: https://customized-okta-embedded-widget-7.glitch.me/
View the code here: https://glitch.com/edit/#!/customized-okta-embedded-widget-7?path=script.js

Reproduction Steps

piv 0

When the browser PIV certificate selection prompt is displayed, and the user clicks cancel.
These are the transactions involved. You can see at step 2 we have the correct error, but this does not get displayed.

  1. Initial MTLS connection:
    piv 1

  2. Error MTLS response -> forwarded to Okta: empty_cert_error "No certificate selected"
    piv 2

  3. Okta respond back to my application/widget with generic failure "interaction_required"
    piv 3

  4. Lame generic error presented to user instead of correct error 😔

SDK Versions

7.20

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions