setConnectionCodeSigningRequirement(_:)
Sets the code signing requirement for connections to this listener.
Declaration
func setConnectionCodeSigningRequirement(_ requirement: String)Parameters
- requirement:
A string that describes requirements expected of the connection peer. See CodeSigningGuide for more information on the code signing format.
Discussion
Use this method to enforce a code-signing requirement on incoming XPC connections.
The following example shows how a listener can ensure that the XPC client service on the other end of a connection has a specific entitlement.