• 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
How do I drop elevated privileges in postflight?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How do I drop elevated privileges in postflight?


  • Subject: How do I drop elevated privileges in postflight?
  • From: Dave Camp <email@hidden>
  • Date: Fri, 13 Apr 2007 10:36:15 -0700

I've got an installer with a postflight script that performs some needed actions after the install is done. Our client wants the installer to open the user's default browser to a registration page on their website when the installation is complete, so I added a "open http://www.foo.com"; to the end of the script.

However, I've discovered that since the script is running as root, open launches root's default browser (Safari), not the default browser of the real user (e.g. FireFox).

What is the best way to fix this? Is there a better way to get the real users browser open, or is there a way I can get the rest of my script to run without elevated privileges (I know how to do that in C, I just can't figure out the right incantation in a shell script)?

Thanks,
Dave
---
In English, every word can be verbed.

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: How do I drop elevated privileges in postflight?
      • From: Brian Ray <email@hidden>
  • Prev by Date: Re: Get the package's NSBundle from a plugin
  • Next by Date: Re: How do I drop elevated privileges in postflight?
  • Previous by thread: Re: Get the package's NSBundle from a plugin
  • Next by thread: Re: How do I drop elevated privileges in postflight?
  • Index(es):
    • Date
    • Thread