Search the MacOS Keychain; spec is like `auth-source'.
All search keys must match exactly. If you need substring
matching, do a wider search and narrow it down yourself.
You'll get back all the properties of the token as a plist.
The :type key is either 'macos-keychain-internet or
'macos-keychain-generic.
For the internet keychain type, the :label key searches the
item's labels ("-l LABEL" passed to "/usr/bin/security").
Similarly, :host maps to "-s HOST", :user maps to "-a USER",
and :port maps to "-P PORT" or "-r PROT"
(note PROT has to be a 4-character string).
For the generic keychain type, the :label key searches the item's
labels ("-l LABEL" passed to "/usr/bin/security").
Similarly, :host maps to "-c HOST" (the "creator" keychain
field), :user maps to "-a USER", and :port maps to "-s PORT".
Here's an example that looks for the first item in the default
generic MacOS Keychain:
(let ((auth-sources '(macos-keychain-generic)))
(auth-source-search :max 1)
Here's another that looks for the first item in the internet
MacOS Keychain collection whose label is 'gnus':
(let ((auth-sources '(macos-keychain-internet)))
(auth-source-search :max 1 :label "gnus")
And this one looks for the first item in the internet keychain
entries for git.gnus.org:
(let ((auth-sources '(macos-keychain-internet")))
(auth-source-search :max 1 :host "git.gnus.org"))
(fn &rest SPEC &key BACKEND CREATE DELETE LABEL TYPE MAX HOST USER PORT &allow-other-keys)