Awhile ago I created a local JSS user that was solely for the purpose of using its credentials in scripts to perform actions via the API, namely updating the value for specific extension attributes within a computer record. I want this user to be as limited as possible since its credentials may be exposed in clear text in scripts.
In 9.62 this was working fine with the user only having create, read, and update privileges for computer objects. This broke when updating to 9.81. Is anyone doing something similar and can verify what privileges are needed? I tried adding delete for computer objects, as well as CRUD for computer extension attributes, but still no luck.
Here is the command I'm running and the associated output, which you can see states "Not authorized for a user PUT":
curl -k -v -u username:password
https://jss.url:8443/JSSResource/computers/name/TaggartJ-M0L5A
/subset/extensionattributes -T /tmp/ea.xml -X PUT
* Hostname was NOT found in DNS cache
% Total % Received % Xferd Average Speed Time Time Time
Current
Dload Upload Total Spent Left
Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:--
0* Trying ip.ip.ip.ip...
* Connected to jss.url (ip.ip.ip.ip) port 8443 (#0)
* TLS 1.2 connection using TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384
* Server certificate: jss.url
* Server certificate: Columbus College of Art & Design JSS Built-in
Certificate Authority
* Server auth using Basic with user 'api_upload'
PUT
/JSSResource/computers/name/TaggartJ-M0L5A/subset/extensionattributes
HTTP/1.1
Authorization: Basic YXBpX3VwbG9hZDpDYXNwZXIxNA==
User-Agent: curl/7.37.1
Host: jss.url:8443
Accept: */*
Content-Length: 200
Expect: 100-continue
< HTTP/1.1 100 Continue
} [data not shown]
* We are completely uploaded and fine
< HTTP/1.1 409 Conflict
< X-FRAME-OPTIONS: SAMEORIGIN
< Cache-Control: no-store, no-cache, must-revalidate, max-age=0,
post-check=0, pre-check=0
< Date: Wed, 16 Dec 2015 14:49:46 GMT
< Accept-Ranges: bytes
* Server Restlet-Framework/2.1.7 is not blacklisted
< Server: Restlet-Framework/2.1.7
< Vary: Accept-Charset, Accept-Encoding, Accept-Language, Accept
< Content-Type: text/html;charset=UTF-8
< Content-Length: 417
< Connection: close
<
{ [data not shown]
100 617 100 417 100 200 1304 625 --:--:-- --:--:-- --:--:--
1307
* Closing connection 0
<html>
<head>
<title>Status page</title>
</head>
<body style="font-family: sans-serif;">
<p style="font-size: 1.2em;font-weight: bold;margin: 1em 0px;">Conflict</p>
<p>Error: Not authorized for a user PUT</p>
<p>You can get technical details <a
href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.10">he
re</a>.<br>
Please continue your visit at our <a href="/">home page</a>.
</p>
</body>
</html>