SMJobBless() has no equivalent to 'un'bless

Originator:monsterandfriends
Number:rdar://12346612 Date Originated:21-Sep-2012 09:22 AM
Status:open Resolved:
Product:OS X Product Version:all
Classification:other Reproducible:yes
 
Summary:

<ServiceManagement/ServiceManagement.h>

SMJobBless() can be used to add privileged helper tools (daemons) to the system by handling privilege escalation and installing for you. SMJobRemove() is the only tear down function provided and it seems to only stop the daemon, not actually clean up any files (/Library/LaunchDaemons/com.something.plist and /Library/PrivilegedHelperTools/com.something

This is ok because you'll need to remove the old before re adding a job/daemon/etc. but not suffecient for a complete removal and would require additional tools/uninstallers/etc to properly clean up any app residue.

Steps to Reproduce:
Use the API and try and add a system daemon and remove it permanently.

Expected Results:
API is more complete. Can not only properly add/start/stop/remove but also query damon status(not just running but installed, etc)

Actual Results:
API in it's current state is half baked.

Regression:

Notes:
https://devforums.apple.com/message/732683#732683

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!