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];