createCredentialAssertionRequestWithChallenge: After canceling login it doesn't work again.

Hi everyone, my first post here:

I am trying to integrate new macOS Monterey FIDO2 authentication into a macOS app and I have trouble with login issue.

After making an assertion request (calling createCredentialAssertionRequestWithChallenge) the Sign In dialog appears. When you click on the cancel button and make another assertion request the dialog doesn't appear and the application window's close button turns gray and the window loses its focus. (please see the attached screenshots). This happens only when pressed cancel button on Sign In, canceling registration or authenticating sign-in or log-in are ok.

Here is my code for authentication request:

   ASAuthorizationPlatformPublicKeyCredentialProvider* credentialProvider = [[ASAuthorizationPlatformPublicKeyCredentialProvider alloc] initWithRelyingPartyIdentifier:@"myrelyingparty.com"];
  ASAuthorizationRequest* request = [credentialProvider createCredentialAssertionRequestWithChallenge:challenge];
  ASAuthorizationController* authorizationController = [[ASAuthorizationController alloc] initWithAuthorizationRequests:@[request]];
   
  authorizationController.delegate = self;
  authorizationController.presentationContextProvider = self;
  [authorizationController performRequests];
   
  [[NSApplication.sharedApplication mainWindow] makeKeyWindow];
Answered by asmbaty in 708098022

Fixed on 12.3!

If you are still seeing this behavior on the latest version of macOS Monterey (currently 12.2, or the 12.3 beta), please let us know through Feedback Assistant 🙂

I've updated macOS Monterey from 12.1 to 12.2 and the issue still persist.

Accepted Answer

Fixed on 12.3!

createCredentialAssertionRequestWithChallenge: After canceling login it doesn't work again.
 
 
Q