• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Distributed Objects client/peer identification
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Distributed Objects client/peer identification


  • Subject: Distributed Objects client/peer identification
  • From: Nicko van Someren <email@hidden>
  • Date: Mon, 11 Feb 2008 14:22:31 +0000

I have a background agent and a System Preferences panel to allow the user to configure it. They talk to each other using Distributed Objects. The Programming Topics for DO tells me that the delegate of the NSConnection gets asked to confirm is a new connection should be allowed.

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). It would seem that I might be able to do this with some complex manipulation of Mach port rights, but if I could just get the PID for the sender I can check if the process owner is the same user and be done with the problem. So, does anyone know who to find out where the other end of an NSConnection resides?

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!

	Cheers,
		Nicko

_______________________________________________

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


  • Follow-Ups:
    • Re: Distributed Objects client/peer identification
      • From: "Hamish Allan" <email@hidden>
    • Re: Distributed Objects client/peer identification
      • From: "Adam R. Maxwell" <email@hidden>
    • Re: Distributed Objects client/peer identification
      • From: John Pannell <email@hidden>
  • Prev by Date: Re: Loading saved file into NSArrayController
  • Next by Date: finding memory leaks
  • Previous by thread: Re: Loading saved file into NSArrayController
  • Next by thread: Re: Distributed Objects client/peer identification
  • Index(es):
    • Date
    • Thread