sfauthorizationpluginview

Code block in DispatchQueue.main.async is never getting executed

时光毁灭记忆、已成空白 提交于 2020-04-18 12:36:23
问题 I am working on a bundle project in swift which is used as an authorization plugin and in the bundle project I am doing API request call using URLSession.shared.dataTask and in the call back I receive, I am trying to update the UI and as updating UI has to be done using main thread I am using DispatchQueue.main.async and the code inside DispatchQueue.main.async is never getting executed! This works perfectly fine in a normal MacOS Cocoa application but the problem persists with Bundle project

Code block in DispatchQueue.main.async is never getting executed

荒凉一梦 提交于 2020-04-18 12:36:03
问题 I am working on a bundle project in swift which is used as an authorization plugin and in the bundle project I am doing API request call using URLSession.shared.dataTask and in the call back I receive, I am trying to update the UI and as updating UI has to be done using main thread I am using DispatchQueue.main.async and the code inside DispatchQueue.main.async is never getting executed! This works perfectly fine in a normal MacOS Cocoa application but the problem persists with Bundle project

Error acessing keychain item from OS X authorization plugin

白昼怎懂夜的黑 提交于 2020-01-04 10:22:21
问题 I'm using the NameAndPassword authorization plugin to login through the OS X lock screen (the fixed version of the plugin since original is broken). I need it to be able to access stored passwords somehow, and currently I'm trying to achieve this by using keychains. I managed to create the keychain and save some password inside, along with the ACL needed to access the password without prompting the user. Any application added to the ACL works fine with no prompts, but when I try to access the

Error acessing keychain item from OS X authorization plugin

 ̄綄美尐妖づ 提交于 2020-01-04 10:18:46
问题 I'm using the NameAndPassword authorization plugin to login through the OS X lock screen (the fixed version of the plugin since original is broken). I need it to be able to access stored passwords somehow, and currently I'm trying to achieve this by using keychains. I managed to create the keychain and save some password inside, along with the ACL needed to access the password without prompting the user. Any application added to the ACL works fine with no prompts, but when I try to access the

Custom login/lock screen in OS X Mavericks

只愿长相守 提交于 2019-12-29 04:55:06
问题 I'm trying to override the default login/lock screen in OS X to allow the user to login in other way than providing a password (think fingerprint scanner or how "Knock to unlock" works), and I'm looking for a way to do it for hours now - all I found that looks useful is the Authorization Plugin ADC reference and this example: https://developer.apple.com/library/mac/samplecode/NameAndPassword/Introduction/Intro.html#//apple_ref/doc/uid/DTS10004022 This NameAndPassword xcode project is a little

Accessing OS X keychain item from trusted application

痞子三分冷 提交于 2019-12-23 21:53:17
问题 I'm creating a keychain and then I'm adding an item with predefined trusted aplication list to it: SecKeychainCreate([keychainPath UTF8String], (UInt32)strlen(keychainPass), keychainPass, FALSE, NULL, &someKeychain); OSStatus someStatus = SecKeychainItemCreateFromContent(kSecGenericPasswordItemClass, &list, len, encryptedPass, someKeychain, accessRef, &someKeychainItem); When I open the newly created keychain with Keychain Access application, I can see my application on the trusted app list:

SecurityAgentPlugin not working anymore on Yosemite (SFAuthorizationPluginView)

大兔子大兔子 提交于 2019-12-09 13:18:55
问题 We have developed an Authorization Plug-in that uses an SFAuthorizationPluginView to present UI to the user. This example is based on the "old" NameAndPassword example provided by Apple. We are using this Authorization Plug-in to unlock the session (we have updated the "system.login.screensaver" authorization in the authorizationdb) using a custom view. This worked well until the last update to Yosemite. Since Yosemite, the SFAuthorizationPluginView is not closing anymore after the user

Creating an OS X authentication plugin

雨燕双飞 提交于 2019-12-05 01:30:15
问题 I need to create a plugin for OS X login mechanism so that I can unlock the screen other way than by typing a password. I know things like this already exist - Knock to unlock or Rohos USB key logon are examples. I found the sample code on ADC called "NameAndPassword" (https://developer.apple.com/library/mac/samplecode/NameAndPassword/Introduction/Intro.html), and after some struggle (Custom login/lock screen in OS X Mavericks) I managed to build and install it on Mavericks. The problem is

SecurityAgentPlugin not working anymore on Yosemite (SFAuthorizationPluginView)

ⅰ亾dé卋堺 提交于 2019-12-03 16:07:30
We have developed an Authorization Plug-in that uses an SFAuthorizationPluginView to present UI to the user. This example is based on the "old" NameAndPassword example provided by Apple. We are using this Authorization Plug-in to unlock the session (we have updated the "system.login.screensaver" authorization in the authorizationdb) using a custom view. This worked well until the last update to Yosemite. Since Yosemite, the SFAuthorizationPluginView is not closing anymore after the user logged into the session. We could update the example to force closing the window, by doing something like: /

Is it possible to replace the Mac login screen?

Deadly 提交于 2019-11-29 02:26:09
Is it possible to replace the Mac OS X login window, /System/Library/CoreServices/loginwindow.app, with a custom login window application? ( See my rational for doing so .) I'm afraid my Cocoa programming skills are rudimentary. I do find it interesting that, when I run probe CGSession (which is a undocumented utility that performs fast user switching) to see what functions it uses, by doing nm -mg /System/Library/CoreServices/Menu\ Extras/User.menu/Contents/Resources/CGSession that one of the linked function is: (undefined [lazy bound]) external _CGSCreateLoginSession (from