Hi,
I have a question regarding securing XPC communication. I'm trying to get on the server side the process audit token for the connecting client.
- I've saw
NSXPCConnection
has a member calledauditSessionIdentifier
which I saw it is always returning same number for different connections. What does this represent, can it be used to identify the client connecting process? NSXPCConnection
hasauditToken
, which is what I need, but it is a private property. I would use this, but I'm not sure if this will not result in app being rejected by Apple. Is anyone using it and had the app rejected/accepted?NSXPCConnection
hasprocessIdentifier
but this alone it is kind of useless. But I was thinking to combine this withtask_extmod_info
(detect process changes) and audit token withtask_name_for_pid
.
Any other suggestions to get the client process audit token based on NSXPCConnection
?
Thanks
I'm trying to get on the server side the process audit token for the connecting client.
To what end?
Most folks who ask this question are trying to restricted access to their XPC service, and going through the audit token is not the best option for that. See Validating Signature Of XPC Process.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"