blawson7
asked on
AJAX webservice call authentication
I am calling a WebMethods web service using the XMLHttpRequest object and when the request is sent, I get a user prompt to log into the server. Is there a way to send the username/password with the POST request?
BTW, I know nothing of WebMethods. I am merely interfacing with it. I can put in my username and password and the request goes through, but I don't want my users to need to do this each time they send a query to the web service. Also, I'm using Internet Explorer.
Thanks!
BTW, I know nothing of WebMethods. I am merely interfacing with it. I can put in my username and password and the request goes through, but I don't want my users to need to do this each time they send a query to the web service. Also, I'm using Internet Explorer.
Thanks!
Are you using the .NET ? is the web service also being run by you ?
Try to use the Forms Authentication and disable the Windows authentication in the IIS server
Also have a look here : http://stackoverflow.com/questions/1879136/forms-authentication-and-post-requests-from-ajax
Also have a look here : http://stackoverflow.com/questions/1879136/forms-authentication-and-post-requests-from-ajax
here something.
https://www.experts-exchange.com/questions/23842059/Get-trough-Authentification-in-ASP-NET-for-a-Domino-WebService.html
The actual class i use is a bit different, i keep the
WEBService as Private Shared in a class, so i dont have to reconnect eatch time i call it. But I think you got something to srtart with.
https://www.experts-exchange.com/questions/23842059/Get-trough-Authentification-in-ASP-NET-for-a-Domino-WebService.html
The actual class i use is a bit different, i keep the
WEBService as Private Shared in a class, so i dont have to reconnect eatch time i call it. But I think you got something to srtart with.
ASKER
No .NET - just javascript
The web service is being run on the same domain, but not by me. We have a WebMethods contractor (who happens to be out for a few weeks) who set up the services.
Since we use the authentication for other purposes, I don't want to disable the authentication in the IIS server.
The web service is being run on the same domain, but not by me. We have a WebMethods contractor (who happens to be out for a few weeks) who set up the services.
Since we use the authentication for other purposes, I don't want to disable the authentication in the IIS server.
In that case, I guess, you don't have much choices left
ASKER
Is .NET so awesome that you can so much more with it than all other non-microsoft frameworks?
It is not the question of .NET. It is beacuse
1. you can't turn off the IIS Windows authentication
2. you can't modify the web methods( remember the web method is also function calls with specific signature)
If you are using Forms authentication then you can very well turn of Windows authentication in IIS with out any damage as it will still require the user to be logged in to use the web service .
1. you can't turn off the IIS Windows authentication
2. you can't modify the web methods( remember the web method is also function calls with specific signature)
If you are using Forms authentication then you can very well turn of Windows authentication in IIS with out any damage as it will still require the user to be logged in to use the web service .
masterpass was faster than me...
You said : "Since we use the authentication for other purposes, I don't want to disable the authentication in the IIS server."
Note that you dont have to disable it on the whole server. you could disable it only for that webservice.
You said : "Since we use the authentication for other purposes, I don't want to disable the authentication in the IIS server."
Note that you dont have to disable it on the whole server. you could disable it only for that webservice.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER