Exploring Web service security
-
- UpdatedAug 1, 2024
- 3 minutes to read
- Xanadu
- Platform Security
Enforce security using basic authentication, mutual authentication, or WS-Security.
Basic Authentication
To enforce basic authentication on each request for a WSDL document or posting of SOAP messages, you may set the property glide.basicauth.required to true. If you do so, each WSDL or SOAP request would have to contain the "Authorization" header as specified in the Basic Authentication protocol. Because the request is non-interactive, the Authorization header is always required during a request.
Supplying basic authentication information whether or not it is required has the added advantage that the data created or updated as a result of the Web Service invocation is done on behalf of the user supplied in the basic authentication credentials. As an example, when creating an Incident record, the journal fields have the user id of the basic authenticated user, instead of the default Guest user.
- BasicAuth
- CustomAuth
- When using C# .NET VS 2005 or older, you can take advantage of the Credentials object, for example:
- When using C# .NET VS 2008, you can take advantage of the ClientCredentials object, for example:Then in your app.config file look for the following and change None to Basic:
- When using VB .NET taking advantage of the Credentials object would look like the following:The resulting response when Basic Authentication is turned on and no credentials are supplied looks like this: