Skip to content
This repository has been archived by the owner on Sep 23, 2021. It is now read-only.

BigSur 11.1 issue: The authorization was denied since no user interaction was possible #137

Open
kotapeter opened this issue Jan 14, 2021 · 1 comment

Comments

@kotapeter
Copy link

kotapeter commented Jan 14, 2021

If macOS asks password more than 1 it'll fail with the error message in the title.

For example if we want to save an x509 certificate into keychain. On Apple machines with BigSur 11.1 asks password twice. (who knows why..)

(I've tested with Intel mac and it works properly)

Reproduce:

Here is our command:

security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain "/Users/user/ssl/mysite.local.crt"

If you run this in terminal with sudo prefix then terminal'll ask your password and after that an OS dialog will be prompted and asks your password again. (video attached)

If you'd like to run the command with sudo-prompt (video attached) then you will get the following error:

The authorization was denied since no user interaction was possible

Because sudo-prompt hides the second dialog.

UPDATE

On the first video you cannot see password dialog because screencast app hides it. After I typed my pass in terminal an OS dialog came up and asked my pass again.

Screen.Recording.2021-01-14.at.19.04.26.mov
Screen.Recording.2021-01-14.at.19.06.37.mov
@kotapeter kotapeter changed the title Apple M1 issue: The authorization was denied since no user interaction was possible macOS issue: The authorization was denied since no user interaction was possible Jan 14, 2021
@kotapeter kotapeter changed the title macOS issue: The authorization was denied since no user interaction was possible BigSur 11.1 issue: The authorization was denied since no user interaction was possible Jan 14, 2021
@alectrocute
Copy link

This is macOS’s issue, not sudo-prompt IMHO.

But to help out, maybe try unlocking the user’s keychain first via node child_process and then execute the sudo command after. Other relevant stuff in that SO thread.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants