• 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
Privileges problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Privileges problem


  • Subject: Privileges problem
  • From: Patrice Goetghebeur <email@hidden>
  • Date: Sat, 9 Nov 2002 05:13:03 +0100

Hello,

I'm trying to control a unix daemon from my cocoa app. As it requires root privileges i use the Security Framework, exactly as shown in the example on Stepwise(http://www.stepwise.com/Articles/Technical/2001-03- 26.01.html), thus i launch my daemon with AuthorizationExecuteWithPrivileges().
I have two problems:

- the daemon well run as root, its log file belongs to root, however it generates an error relative to its rights: "setuid'ed execution not allowed". (when it try to read a file that is only readable by root).

- In order to stop it, i use the "killall" command with the same authorizationRef as launch. It doesn't works if the daemon hasn't been launched by the application (manually or another way). that is, if i launch the daemon, then quit and relaunch the app, i can stop it.

Note that i also use the same authorizationRef to call others root commands that works fine.
And as recommended in the Stepwise article, i have one AuthorizationItem for each command i call.

what's wrong ?
Thanks for your help.

Patrice.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: Calling a unix command from Cocoa ?
  • Next by Date: Re: Calling a unix command from Cocoa ?
  • Previous by thread: Re: Setting up a Creator/Mine type
  • Next by thread: HELP : contex menu and mouseMoved events
  • Index(es):
    • Date
    • Thread