Hi All.
We have a program on MAC, and another seperate app which is an updater.
The updater may need to copy/replace/delete some files in the /System/Library/ folders on the MAC.
But these folders need Admin Privileges to be able to edit the files inside them.
Our program is written in Qt, and i run shell commands, such as "cp" and "rm".
If i am able to run "sudo cp" and "sudo rm" then it should be fine. But the problem is that when i run sudo through the Qt app, it doesn't pop up any dialog to allow the user to type in the password.
Is there any function that can pop up the Standard MAC OS X Authentication Dialog and to give my app admin rights? so that when i call "sudo cp", etc, they wont need the password to be keyed in ?
This updater is also called from the main app.. so "sudo open updater" wont work as well ! same problem !
If theres any other ways around it, i'd be glad to hear as well !
THanks a lot!
We have a program on MAC, and another seperate app which is an updater.
The updater may need to copy/replace/delete some files in the /System/Library/ folders on the MAC.
But these folders need Admin Privileges to be able to edit the files inside them.
Our program is written in Qt, and i run shell commands, such as "cp" and "rm".
If i am able to run "sudo cp" and "sudo rm" then it should be fine. But the problem is that when i run sudo through the Qt app, it doesn't pop up any dialog to allow the user to type in the password.
Is there any function that can pop up the Standard MAC OS X Authentication Dialog and to give my app admin rights? so that when i call "sudo cp", etc, they wont need the password to be keyed in ?
This updater is also called from the main app.. so "sudo open updater" wont work as well ! same problem !
If theres any other ways around it, i'd be glad to hear as well !
THanks a lot!