Re: Distributed Objects client/peer identification
Re: Distributed Objects client/peer identification
- Subject: Re: Distributed Objects client/peer identification
- From: "Hamish Allan" <email@hidden>
- Date: Tue, 12 Feb 2008 15:38:01 +0000
On Feb 11, 2008 2:22 PM, Nicko van Someren <email@hidden> wrote:
> What I want to do is determine what task is trying to make the
> connection to my application. In particular, I want to be able to
> make sure that the other end of the connection is a task belonging to
> the same user (for instance because some other user is also logged in
> using fast user switching).
As of Leopard, this should be taken care of. See:
http://developer.apple.com/technotes/tn2005/tn2083.html
> The ugly hack solution will be for the agent to put a random challenge
> in temporary file only readable by the correct user and demand that
> the SysPref plug-in send it a copy of the file, but I'd still like to
> know how to identify the endpoints of an NSConnection!
See:
http://developer.apple.com/documentation/Cocoa/Conceptual/DistrObjects/Tasks/delegate.html
http://developer.apple.com/documentation/Cocoa/Reference/Foundation/Classes/NSConnection_Class/Reference/Reference.html#//apple_ref/occ/instm/NSObject/authenticateComponents:withData:
The NSData you return could be a hash of the UID and the NSData from
the passed components salted with some shared secret.
Best wishes,
Hamish
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden