mirror of
https://github.com/PurpleComputing/mdmscripts.git
synced 2026-02-03 06:03:26 +00:00
Create lock-device.sh
This commit is contained in:
9
lock-device.sh
Normal file
9
lock-device.sh
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/sh
|
||||
|
||||
jssUser=$4
|
||||
jssPass=$5
|
||||
jssHost=$6
|
||||
passcode=$7
|
||||
|
||||
id=$(jamf recon | grep '<computer_id>' | xmllint --xpath xmllint --xpath '/computer_id/text()' -)
|
||||
/usr/bin/curl -su "${jssUser}:${jssPass}" "https://${jssHost}/JSSResource/computercommands/command/DeviceLock/passcode/${passcode}/id/${id}" -H "Content-Type: application/xml" -X POST
|
||||
Reference in New Issue
Block a user