Skip to end of metadata
Go to start of metadata

Description

This script will enable screen sharing for a select users only.

Ingredients

  • FW Admin

Directions

  1. Create a new empty fileset.
  2. Click the script item in the button bar
  3. Create a new script
  4. Open the fileset and rename the script to be unique.
  5. Select the .sh file and choose "edit text" to open the script file.

    #!/bin/sh
    # benm @ filewave
    # Feb 2013 - original creation
    
    #Save output to client log
    exec 1>>/var/log/fwcld.log
    exec 2>>/var/log/fwcld.log
    
    #enable it
    sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -configure -allowAccessFor -specifiedUsers
    
    # For Change USERNAME to the name of the account you wish to enable. 
    # you must use the short name of the account (the name with no spaces in it)
    sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -configure -users USERNAME -access -on -privs -all
    sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -configure -activate
  6. Where USERNAME is the short name of a users.
    Use Short Name:

    username

    NOT

    User Name

Notes

If you add

sudo systemsetup -setremotelogin on


To the script, it will enable ssh login (aka Remote Login).