Admin authorization and SMJobBless

Discussion in 'Mac Programming' started by lokoArt, Jan 18, 2012.

  1. lokoArt, Jan 18, 2012
    Last edited: Jan 18, 2012

    lokoArt
    Expand Collapse
    macrumors newbie

    Joined:
    Jan 18, 2012
    #1
    Hi guys!
    Please help me)
    My program needs in admin privilege.
    I downloaded this sample http://developer.apple.com/library/mac/#samplecode/SMJobBless/Listings/ReadMe_txt.html

    It shows how to bless my helper tool.
    After run in /Library/launchDaemons exists com.apple.bsd.SMJoblessHelper.plist
    and in /Library/privilegedhelpertools/ exist my helper tool.

    Please say me. How run my helper tool?
    I guess that I have to load and start daemon, but how it can?
    I'm disappointed...
     
  2. gnasher729
    Expand Collapse
    macrumors G5

    gnasher729

    Joined:
    Nov 25, 2005
    #2
    Why do you need administrator privileges? First, it means that your application will never, ever be able to be on the App Store. Second, it means that I would be very, very reluctant to use your software.

    And it is _impossible_ to run your helper tool without the user entering their password at some point, if that is what you are trying to achieve.
     
  3. r0k
    Expand Collapse
    macrumors 68040

    r0k

    Joined:
    Mar 3, 2008
    Location:
    Detroit
    #3
    I wrote an app that starts and stops a daemon. I have had a handful of complaints from users that don't want to enter an Admin password to do so. I say too bad. If you're app is doing something as admin and you're trying to find a way around entering an admin password, my question is why? Convenience never outweighs security.
     
  4. lokoArt
    Expand Collapse
    thread starter macrumors newbie

    Joined:
    Jan 18, 2012
    #4
    Thanks... I'm doing it because my pkg installed in Lion with admin privilegies, and owner of my application is root. I have to fix it. And I decided that I'll not use SMJobBless.
     

Share This Page