10-09-2015 08:09 AM
I've produced a webservice that runs on the application web server on a sbRIO-9626 device.
However I am having problems securing access to it with the standard NI-Auth tools.
I have set up a user and permissions as per the guide (for PC webservice):
http://digital.ni.com/public.nsf/allkb/DF41D5DA8EEB4840862577D90058C208
However at step 20, when I try to access a secured http method, i do not get a NI-Auth login screen, with opportunity to enter username & password, but just a '400 - bad request error'.
It does work if i access the method via the webservice page on the device web configuration screen (the silverlight page), with username & password credentials added under the 'Advanced' tab.
Why is the NI-Auth login prompt not being generated on my remote PC?
Thanks
Solved! Go to Solution.
10-13-2015 10:10 AM
Hi SuperDuperCoop,
Is it possible to upload your project with the webservice inside to look at the settings? If not could you take some print screens.
Are you connecting through Ethernet to the sbRIO? What version of LabVIEW are you using?
Cheers
Pete
10-13-2015 11:37 AM
Sorry but I cannot post any code or print screens! I'll try and add as much detail as possible here...
Version: LV 2014 32bit +RT module +FPGA module. Browser is IE8 on Windows 7 Enterprise.
Ethernet connection to sbRIO-9626 is via static IPs on a private (isolated) server. All is OK in terms of connecting to sbRIO in debug/interactive mode, and also deploying code to the unit. The NI auth does work when using the silverlight sbRIO configuration console and entering correct username and password, which makes me think the issue is getting the NI auth login page to start up automatically on the remote machine.
The webservice seems to be operating with no problems - just approx 10 GET / POST methods in Webservice/v1/...There's no 'private content' directory - all is in 'public content', where there's some css and javascript, and three html pages. There is also a startup vi, which sets some shared variables.
Webservice properties includes SSE2 enabled, and all methods return in terminal mode (XML).
Any ideas or tests very welcome.
10-16-2015 10:31 AM
Hi SuperDuperCoop,
I have been unable to replicate the problem. You could try to reinstall all software relating to Webservices on the sbRIO target. To do this go to MAX > Remote Systems > Expand the sbRIO-9626 > Right click Software > Add/Remove Software > Proceed to reinstall any software you feel will be necessary (recommend selecting all of the webservices software).
Alternately check your firewall settings to make sure the ports are not being blocked that you are communicating over.
Pete
NI Applications Engineer
10-20-2015 05:08 AM
Hi Peter
Thanks for your efforts in trying to solve this issue.
Do you have a working webservice on a sbRIO using NI auth? If so, could you post the project here so I can compare with mine?
Thanks
10-22-2015 08:59 AM
This problem was solved by formatting the sbRIO and re-installing the sbRIO software components onto the sbRIO.
This also solved another problem where web services would work when published as application web services, but refused to work when deployed as embedded web services.
Kudos to me smileyhappy: