I am trying to resolve an ongoing issue we have been having for some time where casper remote is not working in our environment. We are running JSS 9.96 and are experiencing this issue on all clients.
When launching a Casper Remote session 9 times out of 10 our support staff are receiving an error stating "Authentication failed to "127.0.0.1:5901"" (port changes depending on times tried)
Screen sharing is not enabled as default in our environment and I am experimenting on enabling this via a self service policy that runs a script:
#!/bin/bash
privs="-DeleteFiles -ControlObserve -TextMessages -OpenQuitApps -GenerateReports -RestartShutDown -SendFiles -ChangeSettings"
/System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -activate -configure -allowAccessFor -specifiedUsers
/System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -configure -access -on -privs $privs -users $4 -restart
I have analysed the way that Casper Remote works and have seen the casperscreensharing account being created and removed as required but my assumption is that something is going on with the password for the account which causes the error.
I have also noted that each time a session is created, the casperscreensharing account is added to the com.apple.access_screensharing group but never removed so there are many entries. cleaning this up manually has no affect on the issue.
Any assistance would be greatly appreciated.
