This sample takes you through the steps to enable an IMS™ application as a web service by using the IMS Phonebook sample application (IVTNO). This sample demonstrates how to enable web services security using Security Assertion Markup Language (SAML) 2.0 signed assertion, and how to create a client application for secure HTTPS communication to the IMS Phonebook web service that is deployed on the SOAP Gateway server on z/OS®.
The Apache Axis2 web services framework supports multiple XML data-binding approaches, such as XMLBeans, JiBX data binding, as well as the custom Axis Data Binding (ADB) approach developed specifically for Axis2. This sample demonstrates how to use the WSDL2Java tool that takes a WSDL document and generates fully annotated Java™ code from which to implement a service by using the XMLBeans approach.
You will create a client stub that sends messages via secure HTTPS communication (client authentication) to the Phonebook web service that is deployed on the SOAP Gateway server on the z/OS platform.
- IMS Enterprise Suite Version 2.2 SOAP Gateway
- IMS Version 11 or Version 12 with integrated IMS Connect
- The IMS Phonebook sample application files (included with this sample)
- IBM® Rational® Developer for System z® Version 184.108.40.206 or later.
- Optional: If you don't have access to the tool, the generated artifacts are provided for you.
- Required: The FEK.SFEKLOAD data set for Rational Developer for System z must be added to the STEPLIB in the IMS Connect startup procedure for the XML converter function to work.
- Apache Ant for compiling your client application from http://ant.apache.org/bindownload.cgi.
Note: This sample is tested with V1.8.2.
Contents of the sample ZIP file
Detailed instructions for this sample is provided in the attached PDF file. All sample files you need are included in the attached compressed file. The compressed file includes:
- The COBOL copybook for the Phonebook sample application that will be enabled as a web service
- The generated files from Rational Developer for System z V220.127.116.11 for your reference in case you do not have access to the required version of Rational Developer for System z Version
- The sample JCL for compiling and linking the XML converter
- Sample client application
- Sample files for enabling SAML signed assertion
|Phonebook copybook and files that are generated by Rational Developer for System z
With WS-Security enabled (with SAML 2.0 Signed Assertion security token) scenario
|IMSPHBK.cpy||IMS Phonebook application copybook|
|IMSPHBK.wsdl||WSDL file (generated by RDz V18.104.22.168)|
|IMSPHBK.xml||Correlator XML file (generated by RDz V22.214.171.124)|
|IMSPHBKD.cbl||XML converters file (generated by RDz V126.96.36.199)|
|IMSPHBK_migrated.xml||Migrated correlator file for the new correlator scheme.|
|Sample JCL for compiling and linking the XML converter|
|IMSPHBKD.jcl||Sample JCL for compiling and linking the IMSPHBKD.cbl XML converter|
|Sample Java application|
|IMSPHBK_Security.java||Sample Java client application|
|The SAMLSignedAssertion/ folder|
|saml-provider.jceks||A sample keystore file|
|client/bindings.xml and policy.xml||Client binding and policy files (different SAML token types will have their own corresponding binding and policy files)|
|SAML/saml-creation/SAMLIssuerConfig.properties||File containing configuration properties to control how the SAML token is configured|
|The files1347061119810/ folder|
|Target/xxxxxx.java||Generated Phonebook service stub files
Important: The IMSPHBKServiceStub.java file included here is a customized version to demonstrate the customization required.
|z/OS shell script files|
|wsdl2java_xmlbean.sh||Generate the client proxy code in xmlbean data bindings|
|antCompile.sh and ant.sh||Compile the source file|
|setpath.sh and setclasspath.sh||Set the Java PATH and CLASSPATH|