Then check your requests from OR side, probably it uses some other kind of authorization rather than Basic.
Compare my two outputs.
First one is anonymous request:
Code: Select all
MacBook-Air:automation pieceofsummer$ curl -v http://127.0.0.1:8083/ZAutomation/api/v1/devices/OpenWeather_21
> GET /ZAutomation/api/v1/devices/OpenWeather_21 HTTP/1.1
> Host: 127.0.0.1:8083
> User-Agent: curl/7.43.0
> Accept: */*
>
< HTTP/1.1 404 Not Found
< Content-Type: application/json; charset=utf-8
< X-API-VERSION: 2.0.1
< Date: Tue, 15 Sep 2015 18:30:08 GMT
< Access-Control-Expose-Headers: Accept-Ranges, Content-Encoding, Content-Length, Content-Range, Content-Type, ETag, X-API-VERSION, Date, Cache-Control, If-None-Match, Content-Language, Accept-Language, ZWAYSession
< Access-Control-Allow-Origin: *
< Access-Control-Allow-Methods: GET, POST, PUT, DELETE, OPTIONS
< Connection: close
< Access-Control-Allow-Credentials: true
< Content-Length: 96
< Transfer-Encoding: chunked
<
{"data":null,"code":404,"message":"404 Not Found","error":"Device OpenWeather_21 doesn't exist"}
Second one is basic auth request:
Code: Select all
MacBook-Air:automation pieceofsummer$ curl -v -u admin:admin http://127.0.0.1:8083/ZAutomation/api/v1/devices/OpenWeather_21
* Server auth using Basic with user 'admin'
> GET /ZAutomation/api/v1/devices/OpenWeather_21 HTTP/1.1
> Host: 127.0.0.1:8083
> Authorization: Basic YWRtaW46YWRtaW4=
> User-Agent: curl/7.43.0
> Accept: */*
>
< HTTP/1.1 200 OK
< Content-Type: application/json; charset=utf-8
< X-API-VERSION: 2.0.1
< Date: Tue, 15 Sep 2015 18:29:56 GMT
< Access-Control-Expose-Headers: Accept-Ranges, Content-Encoding, Content-Length, Content-Range, Content-Type, ETag, X-API-VERSION, Date, Cache-Control, If-None-Match, Content-Language, Accept-Language, ZWAYSession
< Access-Control-Allow-Origin: *
< Access-Control-Allow-Methods: GET, POST, PUT, DELETE, OPTIONS
< Connection: close
< Access-Control-Allow-Credentials: true
< Content-Length: 669
< Transfer-Encoding: chunked
<
{"data":{"creatorId":21,"deviceType":"sensorMultiline","h":-1611286412,"hasHistory":false,"id":"OpenWeather_21","location":0,"metrics":{"scaleTitle":"°C","title":"Kiev","probeTitle":"Temperature","zwaveOpenWeather":{"main":{"temp":289.03,"pressure":1021,"humidity":67,"temp_min":288.15,"temp_max":290.15},"weather":[{"id":800,"main":"Clear","description":"clear sky","icon":"01n"}],"wind":{"speed":3,"deg":130}},"level":15.9,"icon":"http://openweathermap.org/img/w/01n.png","country":"UA","flag":"http://openweathermap.org/images/flags/ua.png"},"permanently_hidden":false,"tags":[],"visibility":true,"updateTime":1442341731},"code":200,"message":"200 OK","error":null}
As you can see, the only difference is Authorization header present in second request, so basic auth actually looks like working ok. Please try the same for your specific url, and compare the output.