BasicAuthentication.jws Sample

This topic inludes the source code for the BasicAuthentication.jws Sample.

Sample Location

This sample is located in the following directory in your WebLogic Workshop installation:

BEA_HOME/weblogic81/samples/workshop/SamplesApp/WebServices/security/transport/basicAuthentication/

Sample Source Code


01 package security.transport.basicAuthentication; 
02 
03 /**
04  * To run this sample start WebLogic Server in the Workshop domain, and point 
05  * a browser at the following URL:
06  
07  * https://localhost:7002/WebServices/security/transport/basicAuthentication/BasicAuthentication.jws/hello
08  
09  * When you are presented with a security certificate from the server, click "Yes".
10  
11  * When you are asked for username and password, enter
12  
13  * User name: weblogic
14  * Password: weblogic
15  
16  * @common:target-namespace namespace="http://workshop.bea.com/BasicAuthentication"
17  */
18 public class BasicAuthentication implements com.bea.jws.WebService
19 
20     /**
21      * @common:operation
22      */
23     public String hello()
24     {
25         return "Hello, Authenticated World!";
26     }
27