Data Power Redbook
Data Power Redbook
Data Power Redbook
Integration Services
Security Services
Mike Ebbers Bill Barrus Servais Bonazebi Peter Daly Charlton Lee
ibm.com/redbooks
International Technical Support Organization DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains October 2008
SG24-7620-00
Note: Before using this information and the product it supports, read the information in Notices on page vii.
First Edition (October 2008) This edition applies to Version 3.6 of the IBM WebSphere DataPower SOA Appliance firmware.
Copyright International Business Machines Corporation 2008. All rights reserved. Note to U.S. Government Users Restricted Rights -- Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
Contents
Notices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii Trademarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . viii Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ix The team that wrote this book . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ix Comments welcome. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi Chapter 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1.1 DataPower overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 1.1.1 Intended audience . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 1.1.2 Role of DataPower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 1.1.3 SOA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 1.1.4 Challenges in service-oriented integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 1.1.5 Meeting SOA challenges . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 1.2 IBM WebSphere DataPower SOA Appliance product line . . . . . . . . . . . . . . . . . . . . . . . 5 1.2.1 IBM WebSphere DataPower XML Accelerator XA35 . . . . . . . . . . . . . . . . . . . . . . . 5 1.2.2 IBM WebSphere DataPower XML Security Gateway XS40 . . . . . . . . . . . . . . . . . . 6 1.2.3 IBM WebSphere DataPower Integration Appliance XI50 . . . . . . . . . . . . . . . . . . . . 8 1.3 DataPower deployment examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 1.4 Use cases in DataPower Redpaper publications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 1.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 Chapter 2. DataPower services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.1 Overview of SOA services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.2 Introduction to the five core services of DataPower . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.2.1 Configuration architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.2.2 Configuring and using DataPower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.3 Multi-protocol gateway service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.3.1 When to use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.3.2 Use case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.4 Web Service Proxy service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.4.1 When to use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.4.2 Use case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.5 XML firewall service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.5.1 When to use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.5.2 Use case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.6 Web application firewall service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.6.1 When to use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.6.2 Simple use case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.6.3 Host virtualization use case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.7 XSL Accelerator (Proxy) service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.7.1 When to use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.7.2 Use case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.8 An architectural approach to service selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Chapter 3. Web services and policy management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.1 Web services. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.1.1 DataPower Web Service Proxy service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.1.2 Web services proxy summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 12 12 13 15 15 17 17 18 18 19 19 20 20 20 21 22 22 22 22 23 23 25 26 27 29 iii
3.2 Policy management. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.2.1 SOA governance. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.2.2 Web Service Policy Framework (WS-Policy Framework) . . . . . . . . . . . . . . . . . . . 3.2.3 Configuring Web Service Policy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.2.4 Policy management summary. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.2.5 Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3 Service registries. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3.1 WebSphere Service Registry and Repository. . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3.2 WSRR governance model. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3.3 The need to integrate WSRR with UDDI. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3.4 Querying WebSphere Service Registry and Repository . . . . . . . . . . . . . . . . . . . . 3.3.5 Dynamic endpoint lookup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3.6 UDDI service registries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3.7 Service registries summary. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.3.8 Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.4 Web services scenarios: A WSRR scenario . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.4.1 Request-response Web Service scenario. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.4.2 Service level monitoring: XML variation scenario . . . . . . . . . . . . . . . . . . . . . . . . .
30 30 30 32 40 41 42 42 43 46 48 51 53 54 54 55 55 62
Chapter 4. Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 4.1 XML threat protection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 4.1.1 Security requirements in an IT environment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 4.1.2 XML threats. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 4.1.3 Network-level security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73 4.1.4 Message level security within XML context. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77 4.2 IBM SOA security offering . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 4.3 WS-Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80 4.3.1 Goals and requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81 4.3.2 WS-Security and DataPower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82 4.3.3 Encryption/decryption capabilities. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82 4.3.4 Digital signature . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83 4.3.5 Other WS-* specifications supported . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84 4.3.6 Exceptional added value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86 4.3.7 Resources for further reading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88 4.4 Authentication, authorization, and audit (AAA) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89 4.4.1 Mechanisms supported by AAA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96 4.5 Integrating IBM DataPower and Tivoli for SOA Security . . . . . . . . . . . . . . . . . . . . . . . 103 4.5.1 Using WebSphere DataPower, Tivoli Security tools, and open standards . . . . . 106 4.5.2 AAA using Tivoli Access Manager (TAM) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106 4.5.3 IBM Tivoli Access Manager for e-business . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 4.5.4 AAA using LDAP Directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108 4.5.5 Summary. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109 4.6 DataPower security scenarios. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109 4.6.1 Scenario one: DataPower typical security. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110 4.6.2 Scenario two: WebSphere DataPower as an XML firewall . . . . . . . . . . . . . . . . . 111 4.6.3 Scenario three: DataPower as a Web application firewall . . . . . . . . . . . . . . . . . 114 4.6.4 Scenario: Securing a WebSphere Message Broker . . . . . . . . . . . . . . . . . . . . . . 118 4.7 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123 Chapter 5. Integration patterns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1 Enterprise service bus implementation patterns and SOA . . . . . . . . . . . . . . . . . . . . . 5.1.1 DataPower as an ESB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.2 Application awareness in the ESB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125 126 126 128
iv
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
5.1.3 Monitoring and managing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.4 Routing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.5 Protocol conversion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.6 Message transformation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.7 Securing messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.8 Connectivity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.9 Summary. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.10 Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.2 Integration to the heritage applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.2.1 WebSphere Transformation Extender (WTX) . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.2.2 DataPower and WebSphere MQ: Quality of service to the traditional . . . . . . . . 5.2.3 Service-enable CICS and IMS traditional applications with DataPower . . . . . . . 5.2.4 Building message flows in WebSphere Message Broker . . . . . . . . . . . . . . . . . . 5.3 Web 2.0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.3.1 Web 2.0 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.3.2 Sample Web 2.0 integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.3.3 Demonstration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.3.4 Summary. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.4 DataPower scenarios . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.4.1 ESB scenario: WESB, WSRR, Tivoli for ABC Hotel . . . . . . . . . . . . . . . . . . . . . . 5.4.2 ESB scenario 2: XYZ Insurance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.4.3 Food products corporation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.4.4 Brokerage firm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.4.5 Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Chapter 6. Configuration management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.1.1 File system directories and domains. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.1.2 Devices, environments, and load balancers . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.1.3 Boot sequence for DataPower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.2 Configuration options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.2.1 WebGUI interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.2.2 Command-line interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.2.3 XML Management Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.3 Package importing and exporting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.4 Using a repository . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.5 IBM Tivoli Composite Application Manager System Edition . . . . . . . . . . . . . . . . . . . .
128 130 131 134 136 136 144 144 145 145 151 160 166 167 167 168 177 178 178 178 181 183 187 189 191 192 192 192 193 194 194 195 196 198 199 201
Appendix A. The enterprise service bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203 Definition of an enterprise service bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205 Enterprise requirements for an ESB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207 Appendix B. XML security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . XML threats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Specific types of XML attacks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Single-message xDOS attacks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Multiple-message XDoS attacks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Unauthorized access attacks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Data integrity/confidentiality attacks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Systems compromise attacks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 209 210 210 210 211 211 211 211
Contents
Security services: Standards supported by DataPower . . . . . . . . . . . . . . . . . . . . . . . . . . . 212 When to use DataPower for security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212 References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213 Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215 Related publications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . IBM Redbooks publications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Other publications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Online resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . How to get Redbooks publications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Help from IBM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217 217 217 218 221 221
vi
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Notices
This information was developed for products and services offered in the U.S.A. IBM may not offer the products, services, or features discussed in this document in other countries. Consult your local IBM representative for information about the products and services currently available in your area. Any reference to an IBM product, program, or service is not intended to state or imply that only that IBM product, program, or service may be used. Any functionally equivalent product, program, or service that does not infringe any IBM intellectual property right may be used instead. However, it is the user's responsibility to evaluate and verify the operation of any non-IBM product, program, or service. IBM may have patents or pending patent applications covering subject matter described in this document. The furnishing of this document does not give you any license to these patents. You can send license inquiries, in writing, to: IBM Director of Licensing, IBM Corporation, North Castle Drive, Armonk, NY 10504-1785 U.S.A. The following paragraph does not apply to the United Kingdom or any other country where such provisions are inconsistent with local law: INTERNATIONAL BUSINESS MACHINES CORPORATION PROVIDES THIS PUBLICATION "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Some states do not allow disclaimer of express or implied warranties in certain transactions, therefore, this statement may not apply to you. This information could include technical inaccuracies or typographical errors. Changes are periodically made to the information herein; these changes will be incorporated in new editions of the publication. IBM may make improvements and/or changes in the product(s) and/or the program(s) described in this publication at any time without notice. Any references in this information to non-IBM Web sites are provided for convenience only and do not in any manner serve as an endorsement of those Web sites. The materials at those Web sites are not part of the materials for this IBM product and use of those Web sites is at your own risk. IBM may use or distribute any of the information you supply in any way it believes appropriate without incurring any obligation to you. Information concerning non-IBM products was obtained from the suppliers of those products, their published announcements or other publicly available sources. IBM has not tested those products and cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products. This information contains examples of data and reports used in daily business operations. To illustrate them as completely as possible, the examples include the names of individuals, companies, brands, and products. All of these names are fictitious and any similarity to the names and addresses used by an actual business enterprise is entirely coincidental. COPYRIGHT LICENSE: This information contains sample application programs in source language, which illustrate programming techniques on various operating platforms. You may copy, modify, and distribute these sample programs in any form without payment to IBM, for the purposes of developing, using, marketing or distributing application programs conforming to the application programming interface for the operating platform for which the sample programs are written. These examples have not been thoroughly tested under all conditions. IBM, therefore, cannot guarantee or imply reliability, serviceability, or function of these programs.
vii
Trademarks
IBM, the IBM logo, and ibm.com are trademarks or registered trademarks of International Business Machines Corporation in the United States, other countries, or both. These and other IBM trademarked terms are marked on their first occurrence in this information with the appropriate symbol ( or ), indicating US registered or common law trademarks owned by IBM at the time this information was published. Such trademarks may also be registered or common law trademarks in other countries. A current list of IBM trademarks is available on the Web at http://www.ibm.com/legal/copytrade.shtml The following terms are trademarks of the International Business Machines Corporation in the United States, other countries, or both:
alphaWorks CICS DataPower device DataPower DataStage DB2 developerWorks IBM IMS Lotus Parallel Sysplex pureXML RACF Rational Redbooks Redbooks (logo) System z Tivoli WebSphere Workplace Workplace Client Technology z/OS
The following terms are trademarks of other companies: Oracle, JD Edwards, PeopleSoft, Siebel, and TopLink are registered trademarks of Oracle Corporation and/or its affiliates. EJB, J2EE, Java, JDBC, JVM, Sun, and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both. Active Directory, Microsoft, and the Windows logo are trademarks of Microsoft Corporation in the United States, other countries, or both. UNIX is a registered trademark of The Open Group in the United States and other countries.
Other company, product, or service names may be trademarks or service marks of others.
viii
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Preface
IBM WebSphere DataPower SOA Appliances are purpose-built network devices that offer a wide variety of functionality such as the securing and management of SOA applications, enterprise service bus (ESB) integration, and high-speed XSL execution. A hardened appliance, DataPower provides robust security features including tamper protection of the device itself. This IBM Redbooks publication is for application architects and other consultants who want to include DataPower appliances in their solutions for reasons of speed, security, or ESB integration. This book covers DataPower services, Web services, security, and integration strategies.
ix
A special thanks to the following for their contributions: Peter Daly works for IBM Software Services for WebSphere in the UK. A former physics teacher, he returned to academia to create software for Protein Crytallography, which is widely used in leading laboratories throughout the world. Peter also worked at an international laboratory in France and managed supercomputing facilities in the UK. In 1998 he joined IBM as a UNIX Systems Administrator, then moved into Tivoli Systems Management before taking on his current role (in 2004) as a WebSphere and DataPower consultant. Peter holds degrees in physics and mathematics/computer science. He is a Chartered Engineer and a member of the British Computer Society. Srinvasan Muralidhara participated in the planning and review sessions of this book, as well as rewriting some sections of the text. He is an Advisory Engineer with 15 years of industrial experience, with nine years with IBM. He currently works on DataPower-related projects at the IBM WebSphere Technology Institute. He is widely experienced in SOA-related technologies in all tiers of the software development stack. He has studied SOA performance with DataPower appliances and has investigated integrating DataPower with other mid-tier and back-end traditional components such as WebSphere Application Server, MQ, CICS, and IMS in the SOA context of reusing existing systems and enterprise modernization. Figure 1 is a group picture of the onsite authors in Raleigh.
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Thanks to the following IBMers for their reviews of this document: Matt McLarty, Holger Reinhardt, Adolfo Rodriguez, Manuel Rohmann, and Gari Singh
Be an author
Join us for a two- to six-week residency program! Help write a book dealing with specific products or solutions, while getting hands-on experience with leading-edge technologies. You will have the opportunity to team with IBM technical professionals, Business Partners, and Clients. Your efforts will help increase product acceptance and customer satisfaction. As a bonus, you will develop a network of contacts in IBM development labs, and increase your productivity and marketability. Find out more about the residency program. Browse the residency index and apply online at: ibm.com/redbooks/residencies.html
Comments welcome
Your comments are important to us! We want our books to be as helpful as possible. Send us your comments about this book or other IBM Redbooks publications in one of the following ways: Use the online Contact us review Redbooks publication form found at: ibm.com/redbooks Send your comments in an e-mail to: [email protected] Mail your comments to: IBM Corporation, International Technical Support Organization Dept. HYTD Mail Station P099 2455 South Road Poughkeepsie, NY 12601-5400
Preface
xi
xii
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Chapter 1.
Introduction
IBM WebSphere DataPower SOA Appliances represent an important element in the holistic approach of IBM to service-oriented architecture (SOA). These appliances are purpose-built, easy-to-deploy network devices that simplify, secure, and accelerate your XML and Web services deployments while extending your SOA infrastructure. These appliances offer an innovative, pragmatic approach to harness the power of SOA. Through their use, you will be able to enhance the value of your existing application, security, and network investments. The emergence and proliferation of XML and Web services has seen an explosion in the middleware infrastructure required to support them. An important component in this middleware architecture is the enterprise service bus (ESB), a collection of runtime components that provide services such as routing, transformation/bridging, management, security, and other control functions. While XML and SOAP enable a rich application-aware communication, their emergence has resulted in challenges in terms of consumability, performance, and security. This book examines architectural patterns for using WebSphere DataPower SOA Appliances. Chapter 2, DataPower services on page 11, provides a look at the primary services in DataPower that are the building blocks for the succeeding patterns and includes guidance on the selection of services. We then cover Web services and governance (Chapter 3, Web services and policy management on page 25), security (Chapter 4, Security on page 69), integration patterns (Chapter 5, Integration patterns on page 125), and configuration management (Chapter 6, Configuration management on page 191).
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
1.1.3 SOA
Service-oriented architectures enable the creation of composite applications that comprise reusable, loosely coupled service components. The technical foundation of an SOA is in the support for the eXtensble Markup Language (XML) and Web services built atop it. Using the SOAP Protocol, SOA clients can invoke services without explicit support for a wide variety of transport protocols and message formats. A SOAP facade in front of an existing service enables virtualization where clients invoke a virtualized version of the underlying service, thereby eliminating the need to understand intricate details of the service's implementation. In this context, XML enables data to be self-describing with explicit language support for common operations that manipulate the data. For example, the XPath language enables a consistent way to select data items from within an XML document. In SOA, service intermediaries can use XML and other application-layer data to route, secure, control, transform, or otherwise process service requests and responses, decoupled from the actual service implementation that fulfills each particular request.
Consumability
Often, middleware service stacks have an underlying software engine (generally, J2EE) upon which a Web service hosting engine is built. In some sense, this camp of products has been built by joining together necessary components in an embedded fashion. For example, a J2EE servlet engine can be extended to receive SOAP over HTTP by providing a new Web service servlet. The Web service itself is deployed on this servlet. The result is a system built out of multiple software layers, each with its own configuration and maintenance requirements. Taken individually, each layers requirement may prove tedious. Taken together, the collective set of installation and maintenance requirements often proves prohibitive. For example, patch upgrades that affect in layer in the stack of embedded software must be coordinated in a single atomic action. Further complicating this problem has been the traditional software industrys focus of favoring adding more function to a software product over increasing the usability of existing function. These complexities associated with traditional software middleware built upon general-purpose computers affect other consumability aspects such as usability, learning-curve, trouble-shooting, deployment, and so on. The WebSphere DataPower SOA Appliance form factor (architecture and usability) greatly minimizes difficulties in these difficult areas, greatly enhancing overall consumability.
Security
The advent of SOA has created a common communication framework to understand and operate on application data like has never been seen. With self-describing XML, intermediaries are able to extract portions of the data stream and effect application-aware policies. Unfortunately, this has also enabled a new opportunity for malicious attacks. That is, as XML regularly flows from client to enterprise through IP firewalls without much impediment, the obvious place to attack is in the application data stream itself, the XML. While we are just beginning to understand the repercussions of these types of attacks, they
Chapter 1. Introduction
are emerging. XML Denial-of-Service (XDoS) attacks seek to inject malformed or malicious XML into middleware servers with the goal of causing the server to churn away valuable cycles processing the malicious XML. Enterprise-ready application servers are susceptible to many of these types of attacks, leaving open a security hole that must be closed.
Performance
Another key challenge that has emerged with the adoption of XML is in the computational cost of XML processing. Computing on XML in traditional software-based middleware is orders of magnitude more costly (from the computational sense) than native data structures. XML must be parsed and fluffed into the native data structures of the local computers architecture. Further, XML transformations exacerbate processing needs, as they require multiple passes through the XML structure and are highly sensitive to the transformation processing engine. Securing XML and SOA at the application (XML) level provides computational barriers that can require as much as 60 times the processing capability as plain XML (based on typical workloads). Additionally, it is often prohibitive from a performance point of view to enable key requirements such as monitoring, auditing, and security. Customers end up sacrificing those functions to keep equipment cost from growing unwieldy. Built from the ground up to perform SOA and integration workloads, DataPower is architected to handle data processing efficiently. It combines hardware offloading, pipelined processing, and streaming to create a high-performance SOA engine.
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Enhanced security: Key support includes, but is not limited to, XML/SOAP firewall and threat protection, field-level XML security, data validation, XML Web services access control, service virtualization, and SSL acceleration. Acceleration: Drop-in solution that can streamline XML and Web service deployments, helping lower total cost of ownership and accelerate return on your assets, as you continue to move to SOA. WebSphere DataPower SOA Appliances are purpose-built hardware devices capable of offloading overtaxed servers by processing XML, Web services, and other message formats at wirespeed.
Accelerates XML processing and transformation Increases throughput and reduces latency Lowers development costs
Help secure SOA with XML threat protection and access control Combines Web services security, routing and management functions Drop-in, centralized policy enforcement Easily integrates with exiting infrastructure and processes Transforms messages (Binary to XML, Binary to Binary, XML to Binary) Bridges multiple protocols (e.g. MQ, HTTP, JMS) Routes messages based on content and policy Integrates message-level security and policy functions
Chapter 1. Introduction
can be defined (or queried) to determine the appropriate routing action. Load balancing algorithms such as least-used and round-robin are also available. Additionally, the XA35 can throttle or adjust request rate based on routing criteria to employ traffic shaping. From a transformation perspective, the XA35 provides basic XSLT processing. Built on the underlying premise of all appliances, special-purposed hardware converts one XML schema to another at wire speed. XSLT 1.0 and XPath 1.0 support (with some 2.0 support) is available. The appliance is able to use and apply internal as well as external schema. This product can help speed up common types of XML processing by offloading this processing from servers and networks. It can perform XML parsing, XML Schema validation, XPath routing, Extensible Stylesheet Language Transformations (XSLT), XML compression, and other essential XML processing with wirespeed XML performance. Unmatched performance: DataPower's purpose-built message processing engine can deliver wirespeed performance for both XML-to-XML and XML-to-HTML transformations with increased throughput and decreased latency. Ease of use: The XA35 provides drop-in acceleration with virtually no changes to the network or application software. No proprietary schemas, coding, or APIs are required to install or manage the device. In addition, it supports popular XML Integrated Development Environments (IDEs) to help reduce the number of hours spent in the development and debugging of XML applications. Helps reduce infrastructure costs: Unlike simple content switches that only redirect business documents, the DataPower XML Accelerator XA35 fully parses, processes, and transforms XML with wirespeed performance and scalability to help reduce the need for stacks of servers. The XA35 also supports accelerated SSL processing to help further lessen the load on server software. Helps cut development costs: The XA35 can enable multiple applications to leverage a single, uniformed XML processing layer for all XML processing needs. By standardizing on high-performance hardware appliances, enterprises can deploy sophisticated applications while helping to eliminate unnecessary hours of application debugging and tuning for marginal performance gains. Intelligent XML processing: In addition to wirespeed processing, appliances support XML routing, XML pipeline processing, XML compression, XML/XSL caching, as well as other intelligent processing capabilities to help manage XML traffic. Advanced management: The XML Accelerator model XA35 provides real-time visibility into critical XML statistics such as throughput, transaction counts, errors, and other processing statistics. Data network level analysis is provided, and includes server health information and traffic statistics, as well as management and configuration data.
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
XML Denial of Service protection. Used in conjunction with schema validation and well-formedness checking, the XS40 is an integral part of an enterprise's network security. This appliance provides a security-enforcement point for XML and Web services transactions, including encryption, firewall filtering, digital signatures, schema validation, WS-Security, XML access control, XPath, and detailed logging, and includes: An XML/SOAP firewall: The DataPower XML Security Gateway XS40 filters traffic at wirespeed, based on information from layers 2 through 7 of the protocol stack, from field-level message content and SOAP envelopes to IP address, port/host name, payload size, or other metadata. Filters can be predefined with an easy point-and-click XPath filtering GUI, and automatically uploaded to change security policies based on the time of day or other triggers. XML/SOAP data validation: With its unique ability to perform XML Schema validation as well as message validation, at wirespeed, the XS40 ensures that incoming and outgoing XML documents are legitimate and properly structured. This protects against threats such as XML Denial of Service (XDoS) attacks, buffer overflows, or vulnerabilities created by deliberately or inadvertently malformed XML documents. Field-level message security: The XS40 selectively shares information through encryption/decryption and signing/verification of entire messages or of individual XML fields. These granular and conditional security policies can be based on nearly any variable, including content, IP address, host name, or other user-defined filters. XML Web services access control: The XS40 supports a variety of access control mechanisms, including WS-Security, WS-Trust, X.509, SAML, SSL, LDAP, RADIUS, and simple client/URL maps. The XS40 can control access rights by rejecting unsigned messages and verifying signatures within SAML assertions. Service virtualization: XML Web services require companies to link partners to resources without leaking information about their location or configuration. With the combined power of URL rewriting, high-performance XSL transforms, and XML/SOAP routing, the XS40 can transparently map a rich set of services to protected back-end resources with high performance. Centralized policy management: The XS40's wirespeed performance enables enterprises to centralize security functions in a single drop-in device that can enhance security and help reduce ongoing maintenance costs. Simple firewall functionality can be configured via a GUI and running in minutes, and using the power of XSLT, the XS40 can also create sophisticated security and routing rules. Because the XS40 works with leading Policy Managers, it is an ideal policy execution engine for securing next-generation applications. Manageable locally or remotely, the XS40 supports SNMP, script-based configuration, and remote logging to integrate seamlessly with leading management software. Its emerging support for WS-Policy and WS-SecurityPolicy further augments these capabilities. Web services management/service level management: With support for Web Services Distributed Management (WSDM); Universal Description, Discovery, and Integration (UDDI); Web Services Description Language (WSDL); Dynamic Discovery; and broad support for service level management configurations, the XS40 natively offers a robust Web services management framework for the efficient management of distributed Web service endpoints and proxies in heterogeneous SOA environments. Service level management (SLM) alerts and logging, as well as pull and enforce policies, help enable broad integration support for third-party management systems and unified dashboards, in addition to robust support and enforcement for governance frameworks and policies.
Chapter 1. Introduction
I for integration
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Figure 1-2 depicts common scenarios for deploying these appliances in the intranet, the demilitarized zone (DMZ), and a federated extranet (for example, a business partner). Of particular importance is DataPowers capability to pass even the most stringent requirements for enterprise DMZ deployment. Stated simply, the DataPower architecture is a secure environment with absolutely no Java on the appliance. Network ports are secured by default with no remote access beyond its command-line interface over the secure SSH protocol, Web Graphical User Interface (WebGUI) over HTTPS, and XML management APIs over HTTPS.
federated extranet
legacy enterprise application XI50 5. Legacy transformation SOA platform Demilitarized Zone
Internet
Demilitarized Zone
intranet
internal user
Internet user
Packet Filter
Packet Filter
Packet Filter
Packet Filter
Internet
XS40
1. Helps protect against incoming attacks; Incoming access control 2. Outgoing access control, SAML injection, role mappings
1.5 Summary
This introductory chapter provided an overview of the environment and challenges of service-oriented integration. We introduced the WebSphere DataPower SOA Appliance product line and described typical deployment scenarios. We pointed to detailed use cases available in IBM Redpaper publications. Performance and scalability aspects are not covered in this book. DataPower is built from the ground up for performance in such difficult areas as security and XML processing. It is commonly accepted that DataPower outperforms most middleware components in their core areas. Indeed, since DataPower can take on so many roles, it is difficult to come up with standard benchmarks. In the rest of this book we cover key features and uses of the appliances.
10
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Chapter 2.
DataPower services
This chapter discusses the following primary services that are provided by the DataPower devices: Multi-protocol gateway Web Service Proxy XML firewall Web application firewall XSL Accelerator (Proxy) After describing each services features, functions, and usage scenarios, this chapter provides an architectural approach to service selection.
11
Multi-Protocol Gateway Web Service Proxy XML Firewall Web Application Firewall XSL Accelerator
Figure 2-1 DataPower primary services
12
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
All of these services use the same basic programming constructs, and thus their capabilities often overlap. For instance, both an XSL proxy and an XML firewall can perform XSL transformations. Table 2-1 describes which services are offered on each appliance. Each successive service has the capabilities of the previous one. The exception is the WS-Proxy, which supports features such as SLM that are not available in multiprotocol gateway.
Table 2-1 Services offered on each appliance Core services offered Multi-protocol gateway DataPower appliances XS40, XI50 Typical scenarios Bridge request and response protocol differences. Multiple transports in and out. Process WSDL described services. Send and receive XML traffic over HTTP to and from XML-based applications. Protect heritage XML, SOAP, and B2B messages, non WSDL based Web services and non Web service applications. Optimize XML/XSLT transformations.
XS40, XI50
XSL accelerator
13
At the next layer, processing policy objects and the many objects referenced by a processing policy provide message handling and routing services. These objects perform such tasks as message transformation, message filtering, authentication and authorization, cryptographic operations, error handling, and dynamic message routing. Any single service has only one processing policy. The processing policy, however, might have any number of rules. Each rule might contain any number of actions. Many actions might employ an XML stylesheet language transformation (XSLT). See Figure 2-2 for an illustration of this relationship.
DataPower device Service Processing policy Rule Action Filter XSLT
A wide range of objects provide ancillary or supporting capabilities to top-level service or processing policy objects. For example, a service might require the use of SSL communications, and thus the services of SSL-related objects. A processing policy might include an action that routes messages, and this routing action in turn depends upon a routing map object. A service might require the use of monitoring for threat protection, which in turn requires the configuration of one or more monitor objects. All services on the device might use one or more log target objects to deliver real-time updates to SNMP consoles running elsewhere in the enterprise. At the most fundamental level, network and administration objects provide the configuration settings needed to connect the device to the physical network, enable the WebGUI or CLI interfaces, set user access policies, or create connectivity to other specialized network devices.1
WebSphere DataPower XML Integration Appliance XI50 WebGUI Guide, Version 3.6.1, Second Edition (December 7, 2007) (http://www.ibm.com/support/docview.wss?rs=2362&uid=swg24014405)
14
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
In addition to the Web GUI, DataPower provides a command-line interface (CLI) that is accessible via SSH and Telnet. The appliances provide console (serial) and SSH access to this CLI. All management actions that can be done via the Web GUI can also be performed using the CLI.
15
transport protocols. Detailed logging and audit trail, including non-repudiation support, completes this capability. The MPGW service is housed only in the XI50 and is typically located in the extranet or the intranet. It provides linkage to the System z platform, as indicated in Figure 2-4. It also can be located in the intranet, where it can provide Web service management. As mentioned previously, the XI50 contains a super-set of all the functions of XS40 and can thus be used in place of the XS40 at other locations, such as for security in the DMZ.
federated extranet
legacy enterprise application XI50 Legacy transformation SOA platform Demilitarized Zone
Internet
Demilitarized Zone Internet user
intranet
internal user
Packet Filter
Packet Filter
Packet Filter
MPGW can accept a variety of client-side protocol handlers. The gateway can subsequently provide a variety of server-side routing protocols. The client-side protocols do not need to be the same server-side protocols. The gateway employs protocol handlers to offer protocol-specific connection points to clients who need to request service from back-end servers. The back-end service can be statically or dynamically identified. The MPGW service supports the following client-side and server-side protocols: FTP The gateway can act as either an FTP client, polling a remote FTP server for requests, or as an FTP Server, accepting incoming FTP connections. Including GET and POST. POST can contain XML, SOAP, DIME, and SOAP with Attachments. Including GET and POST. POST can contain XML, SOAP, DIME, and SOAP with Attachments. The gateway can accept incoming IMS protocol requests and can initiate IMS connections on the back side, if licensed only on the XI50. The gateway can poll an NFS-mounted directory for the presence of new files and place responses on an NFS-mounted directory. The gateway can use GET and PUT queues to communicate using MQ messages, if licensed only on the XI50. Supports TIBCO Enterprise Messaging Service, if licensed.
16
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Packet Filter
WebSphere JMS
17
The document is transformed from XML to the appropriate back-end destination format (for example, from XML to COBOL Copybook). Then the message is routed to the appropriate destination. In this example, the message is routed to an MQ Queue, where it is ready for delivery to a back-end CICS. See Figure 2-5.
ODBC
MQ
MQ
CICS on z/OS
IM S
Co nn ec t
IMS on z/OS
18
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Use a Web Service Proxy when you need to perform one or more of the following tasks: Implement Web services Policy enforcement points, including security policies and reliable messaging policies. Implement Web Services Addressing protocol enforcement. Accept and send SOAP, raw XML, or unprocessed (binary) documents. Filter, validate, transform, encrypt, or decrypt XML documents. Route XML documents to the appropriate back-end service. Sign documents or verify signatures. Process large documents in the streaming mode. Implement document-level security or service-level security. Communicate with clients, servers, and peers with SSL encryption. Monitor and control data traffic based on request sources and requested resources to the WSDL operation level. Allow, reject, strip, and process attachments (MIME, DIME, MTOM). WS-Proxy is the primary component to enforce governance aspects of SOA such as SLM.
19
Error support and log activity subscription. Destination support includes SMTP, SNMP, Syslog, Syslog-NG, NFS, File, and SOAP/HTTP.
Based on a DataPower Forum entry by John Rasmussen on when to use XML fw, XSL proxy, MPGW, WSProxy, and Web App fw. Posted February 15, 2008, 3:25p.m.
20
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
21
Integrating Web applications with the DataPower Web application firewall service, IBM Developer Works, Ozair Sheikh, 12 Dec 2007: http://www.ibm.com/developerworks/websphere/library/techarticles/0712_sheikh/0712_sheikh.html
22
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
XSL Proxy is used to optimize transformation of XML/SOAP with XSLT by providing an order of magnitude performance increase by off loading it from servers and networks. The XSL proxy can provide SSL support via SSL hardware for communication with clients, servers, and peers and complete HTTP header RWD control. Message validation can be accomplished via the schema validation feature. The proxy can process large documents using streaming mode, provides count and duration monitors, and provides error-tracking support and log activity subscription features. Use the XSL Proxy service when you need to do one or more of the following: Accept and send SOAP, raw XML, or unprocessed input. Validate and transform XML documents. Process large documents in the streaming mode. Communicate with clients, servers, and peers with SSL encryption. Monitor and log activity by delivering log information to external managers. Allow, strip, or process attachments (DIME or MIME).
Source XML
Server
Client
23
Use Web application firewall to provide security, threat mediation, and content processing services for Web-based application Use the MPGW, instead of XML firewall, if you intend to use protocols other than HTTP. In most cases, services with HTTP front end and back end should use MPGW instead of XML firewall, because of its extensibility. Multiple Front Side Handlers are supported. Keep in mind that service level management is only available in MPGW and WSP. A multi-protocol gateway offers many of the same services and capabilities as a Web Service Proxy. Unlike a Web Service Proxy, a MPGW cannot use a WSDL to determine a configuration. Use MPGW when you want to do one or more of the following: Implement reliable messaging policies. Implement Web Services Addressing protocol enforcement. Accept and send SOAP, raw XML, or unprocessed (binary) documents. Transform XML to binary format documents and binary format documents to XML. Filter, validate, transform, encrypt, or decrypt XML documents. Route XML documents to the appropriate back-end service.
Service composition
SOA extends the object-oriented concepts of encapsulation and re-use into the distributed IT world of integrated applications and even integrated enterprises. For example, we can think of a well-crafted service framework implemented in an ESB such as DataPower as providing reusable components to serve as building blocks for complex applications. Concepts such as chaining services and reusing services in different applications can also be used to define how services can be determined. As an example, one might want to split a complex application into two firewallsa WAF frontending and serving HTML followed by an XSL Proxy doing only XML transformation. In this way, the later service can be reused as a means for intranet ESB-ESB communication. The remaining chapters of this book address SOA topics such as Web services, security, and integration.
24
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Chapter 3.
25
26
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Web services provide communication mechanisms that are location-transparent and interoperable. Web services are evolving through BPEL4WS, document-style SOAP, WSDL, and emerging technologies such as WS-ResourceFramework to support the technical implementation of well-designed services that encapsulate and model reusable function in a flexible manner. For further information see: IBM Web services http://www.ibm.com/webservices IBM on demand operating environment http://www-3.ibm.com/software/info/openenvironment/ IBM developerWorks: SOA and Web services zone http://www.ibm.com/developerworks/webservices
27
DataPower provides a way to address some of the issues associated with todays building of Web services in conjunction with SOA: DataPower provides support for Web services and SOA using open non-proprietary standards. DataPower supports multiple bindings through a WSDL, and is architected to proxy a HTTP transport and function as a gateway to a more secured transport. DataPower is designed from the ground up to drive a solution based on open standards. However, when the design calls for it, DataPower has onboard integration client run times for EMS, FTP, IMS, and SQL.
28
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
29
Process large documents in the streaming mode. Implement document-level security or service-level security. Communicate with clients, servers, and peers with SSL encryption. Monitor and control data traffic based on request sources and requested resources to the WSDL operation level. Allow, reject, strip, and process attachments (MIME, DIME, MTOM). This proxy service is also discussed in 2.4, Web Service Proxy service on page 18.
30
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
WS-Policy
To address the interoperability needs for Web services, DataPower fully leverages the Web Service Policy Framework. This is a set of specifications that were created to describe the capabilities and constraints of domain-specific policies that establish the framework for interoperability. Through WS-Policys defined metadata, DataPower enables interoperability between Web service consumers and Web service providers. Through the proven WS-Policy specifications, DataPower is able to automate the service governance models to create a concrete instance of Web service governance. DataPower uses WS-Policy to provide a general purpose model and syntax that describes and communicates the policies of a Web service. DataPower applies a policy as a collection of one or more policy assertions. Assertions express the capabilities and constraints of a particular DataPower-managed Web service. Some assertions specify traditional requirements and capabilities that will ultimately manifest on the wire (for example, authentication scheme, transport protocol selection). Some assertions specify requirements and capabilities that have no wire manifestation, yet are critical to proper service selection and usage (for example, privacy policy, QoS characteristics). DataPower leverages a single policy grammar to allow both kinds of assertions to be reasoned about in a consistent manner in the Web service. Tip: To establish governance around Web services, DataPower relies on the Web Service Policy Framework specification to define a flexible and concise syntax and semantic for service providers and service requestors that describes their requirements, preferences, and capabilities in flexible and concise domain-specific forms of assertions.
Policy attachments
Since WS-Policy does not specify how policies are discovered or attached to a Web service, DataPower uses the WS-PolicyAttachment language to define several methods for associating the WS-Policy expressions with Web services. WS-PolicyAttachment can describe how policies are to be attached to the elements of a WSDL. DataPower is WS-PolicyAttachment compliant.
Policy assertions
A policy assertion identifies a behavior that is a requirement (or capability) of a policy subject. DataPower uses assertions to indicate domain-specific (for example, security, transactions) semantics and are expected to be defined in separate, domain-specific specifications. Policy expressions allow for both simple declarative assertions as well as more sophisticated conditional assertions. A policy can be built up using assertions and nested combinations of operators. This policy syntax is used to describe acceptable combinations of assertions to form a complete set of instructions to the policy-processing instruction for a given Web service invocation. Each set of assertions is termed an alternative. The flexible syntax of the Web Service Policy Framework, however, can lead to potentially complex policies. So a normal form of policy language was defined to simplify the manipulation and to clarify the understanding of policies. Policies in the normal form are how the basic operation of the policy processing is to be carried out. Through normalization, complex policies can be reduced prior to executing more complex statements such as merge and intersection operations.
31
Tip: An assertion is the basic unit of policy. It can be thought of as an instruction to a policy-processing infrastructure. The meaning of individual assertions is specific to each domain. For example, the assertion could declare that the message be encrypted. The actual definition of this assertion would be in the WS-Security Policy domain specification.
Bringing it together
DataPower has a rich GUI to support building a Web services based policy. To build a policy, there is a hierarchy to consider: 1. Policy: A set of domain-specific policy statements 2. Policy Statement: A group of policy assertions 3. Policy Assertion: An individual preference, requirement, capability, or other property Framework extensibility: The WS-Policy framework was built to be extensible, and DataPower can easily leverage policy language additions as the business requirements dictate. For more advanced users, there may be a need to create new policy expressions from existing (or new) individual policy assertions from different policy domains (that is, WSSecurity, WSReliableMessaging). Policy authors should refer to the guidelines found at: http://www.w3.org/TR/2007/WD-ws-policy-guidelines-20070928/
WS-Policy configuration
For DataPower, the Web Service Proxy already supported the configuration of endpoints from a WSDL file, from a set of WSDL files, from a WSRR or UDDI subscription. Support for governance-enhanced WS-Policy augments endpoint configuration and supports the following behaviors: Parsing WSDL files that contain WS-Policy elements, which demonstrates WS-Policy internal attachment behavior and recognizes standardized policy domains. Configuring the Web Service Proxy to recognize and enforce standardized policy domains. Policy domains are field-extensive. The Web Service Proxy supports the following standardized policy domains: WS-SecurityPolicy WS-ReliableMessagingPolicy Associating, or attaching, WS-Policy expressions, which are not embedded in the WSDL file, to a WS-Policy policy subject (for example, a WSDL endpoint). You can use the service view of the Web Service Proxy from the WebGUI to attach WS-Policy expressions to a set of WS-Policy policy subjects.
32
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
WS-Policy models
DataPower uses an abstraction of the policy model from the physical WSDL for setting management policies of the service. So, a physical WSDL can change, but the abstract model remains the same (Figure 3-1).
Abstraction Model
Service
Inheritance
Port
Binding
Binding
Operation
Operation
Input
Input
Message
The DataPower policy abstract model leverages the hierarchical structure of the WSDL through inheritance. When attaching policy at different levels of the WSDL hierarchy, the policy applies to this level of the hierarchy and is inherited by lower levels of the hierarchy. At a lower level of the hierarchy, one can refine the policy at this level by attaching policy. The refined policy applies to this level of the hierarchy and is inherited by lower levels. Each level of the policy subject can inherit the parts policy attributes, but the inherited policy can be refined and that refinement of the policy will cascade to its children. This system behavior allows for concise control of policy statements as the granularity of the service increases, which maintains a coherent linkage of policies throughout the service object. This rich feature set of DataPower is a powerful way of applying policy statements throughout the service model and offers fine-grained control to the implementor.
33
The policy defines a base set of assertions that describe how messages are to be secured. Flexibility with respect to token types, cryptographic algorithms, and mechanisms used, including using transport-level security, is part of the design and allows for evolution over time. The intent of the policy language is to provide enough information for compatibility and interoperability to be determined by Web services participants, along with all information necessary to actually enable a participant to engage in a secure exchange of messages. DataPower uses WS-SecurityPolicy as a building block that is used in conjunction with other Web service and application-specific protocols to accommodate a wide variety of security models.
34
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
The general aspects of security include the relationships between or characteristics of the environment in which security is being applied, such as the tokens being used, which are for integrity or confidentiality protection and that are supporting the applicable algorithms to use, and so on. The security binding assertion is a logical grouping that defines how the general aspects are used to protect the indicated parts (for example, that an asymmetric token is used with a digital signature to provide integrity protection, and that parts are encrypted with a symmetric key that is then encrypted using the public key of the recipient). At its simplest form, the security binding restricts what can be placed in the wsse:Security header and the associated processing rules.
WS-ReliableMessagingPolicy
It is often a requirement for two Web services that wish to communicate to do so reliably in the presence of software component, system, or network failures. The primary goal of WS-ReliableMessagingPolicy is to create a modular mechanism for reliable message delivery. It defines a messaging protocol to identify, track, and manage the reliable delivery of messages between exactly two parties, a source and a destination. It also defines a SOAP binding that is required for interoperability. Additional bindings may be defined. This mechanism is extensible, allowing additional functionality, such as security, to be tightly integrated. This specification integrates with and complements the WS-Security, WS-Policy, and other Web services specifications. Combined, these allow for a broad range of reliable, secure messaging options. WS-ReliableMessagingPolicy is the second domain-specific assertion (WS-SecurityPolicy being the other) identified under the Web Services Policy Framework that DataPower supports. Many errors may interrupt a conversation. Messages may be lost, duplicated, or reordered. Furthermore, the host systems may experience failures and lose volatile state. WS-ReliableMessaging provides an interoperable protocol that a reliable messaging source and reliable messaging destination use to provide the source and destination with a guarantee that a message that is sent will be delivered. With DataPowers implementation of WS-ReliableMessaging (the source endpoint, destination endpoint, and DataPower acting as a mediator) delivery assurance is guaranteed (assuming no loss of infrastructure). DataPower leverages the standard four basic delivery assurances documented in the specifications that endpoints can provide: AtMostOnce: Messages will be delivered at most once without duplication or an error will be raised on at least one endpoint. It is possible that some messages in a sequence may not be delivered. AtLeastOnce: Every message sent will be delivered or an error will be raised on at least one endpoint. Some messages may be delivered more than once. ExactlyOnce: Every message sent will be delivered without duplication or an error will be raised on at least one endpoint. This delivery assurance is the logical and of the two prior delivery assurances. InOrder (Sequence): Messages will be delivered in the order in which they were sent. This delivery assurance may be combined with any of the above delivery assurances. It requires that the sequence observed by the ultimate receiver be non-decreasing. It says nothing about duplications or omissions.
35
Securing WS-ReliableMessaging
DataPower can be configured to select a specific AAA policy to perform authentication of incoming reliable messaging messages. As this AAA policy can be the same one that is used in later processing by the request or response rule, the AAA policy can be cached, so it does not have to be evaluated again. The same AAA policy can secure the reliable messaging control messages, such as CreateSequence and TerminateSequence, and it can secure incoming reliable messaging data messages, which have a sequence header. This prevents unauthorized clients from issuing CreateSequence requests, or from disrupting existing reliable messaging sequences with CloseSequence or TerminateSequence messages, or from falsely acknowledging messages with SequenceAcknowledgement messages. DataPower can establish a wire-level SSL session to protect sequence life-cycle messages. All reliable messaging control messages and sequence messages are bound to the original SSL/TLS session that is created by the reliable messaging source to transmit the CreateSequence control message. Sequence messages that are received by the reliable messaging destination with the correct identifier but on a different SSL/TLS session are rejected.
Destination accept two-way offers/source create sequence on request/source create sequence on response
DataPower can assume more of a mediator role with enablement of any of these conditions. DataPower can provide more granular control in the middleware layer for frequency and maximum count of acknowledgements retransmissions, maximum queue length, inactivity 36
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
intervals before time-out, and so on. Again with an eye on DataPowers memory constraints, it can provide strong reliable messaging support for the endpoints and absorbs much of the burden for exception processing.
37
RFC2616: HyperText Transfer Protocol 1.1 RFC2818: HTTP over TLS RFC2965: HTTP State Management Mechanism The Secure Sockets Layer Protocol Version 3.0 The profile provides constraints and clarifications to those base specifications with the intent to promote interoperability. Some of the constraints imposed by the profile are intended to restrict, or require, optional behavior and functionality, so as to reduce the potential for interoperability problems. Some of the constraints or requirements are provided to clarify language in the base specification that may be the source of frequent misinterpretation that have been a frequent source of interoperability problems. The highlights of the key constraints imposed by the profile are: Precludes the use of SOAP encoding Requires the use of HTTP binding for SOAP Requires the use of the HTTP 500 status response for SOAP fault messages Requires the use of the HTTP POST method Requires the use of WSDL1.1 to describe the interface of a Web service Requires the use of rpc/literal or document/literal forms of the WSDL SOAP binding Precludes the use of solicit-response and notification-style operations Requires the use of WSDL SOAP binding extension with HTTP as the required transport Requires the use of WSDL1.1 descriptions for UDDI Model elements representing a Web service Usage: WS-Conformance is a fundamental Web services extension that enables many other key Web services extensions. We recommend that WS-I BP 1.0 or 1.1 be turned on. Interoperability can be hampered if the partners are validating against a different WS-I Profile that a particular service is using. An agreement on profiles should be reached between the partners, while always striving to validate against the more recent WS-I BP 1.1 profile.
38
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Bridging between traditional front ends and WS-Addressing back ends Routing in any direction between WS-Addressing-enabled front ends and back ends to include the case where the server response does not pass through the appliance The DataPower service provides the mediation, if any, between the clients and servers. Support for a specific level of WS-Addressing does not preclude simultaneous support for traditional addressing formats. In other words, DataPower can provide a mediation service between WS-Addressing and other addressing methods. No WS-Addressing (default): This disables WS-Addressing support. Both clients and servers use traditional addressing. This requires no additional configuration. Synchronous gateway to WS-Addressing: This specifies that the DataPower service mediates addressing between clients that use traditional addressing and servers that use WS-Addressing. WS-Addressing gateway to synchronous: This specifies that the DataPower service mediates addressing between clients that use WS-Addressing and servers that use traditional addressing. Pure WS-Addressing: This specifies that the DataPower service mediates addressing between clients and servers that use WS-Addressing.
39
based on transaction errors. Also, there is dual rules capability, which implements level-specific restrictions based on transaction volume and error frequency.
40
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
3.2.5 Resources
For further information see: Patterns: Service-Oriented Architecture and Web Services, SC24-6303 http://www.redbooks.ibm.com/abstracts/sg246303.html?Open Patterns: Implementing an SOA using an Enterprise Service Bus, SG24-6346 http://www.redbooks.ibm.com/abstracts/sg246346.html?Open First look at the WS-I Basic Profile1.0, 2002 http://www.ibm.com/developerworks/webservices/library/ws-basicprof.htm WC3, Web Services Addressing (WS-Addressing), 2004 http://www.w3.org/Submission/ws-addressing/ Web Services Security Policy Language (WS-SecurityPolicy)
http://download.boulder.ibm.com/ibmdl/pub/software/dw/specs/ws-secpol/ws-secpol.pdf
developerWorks, developerWorks Forum, 2007 http://www.ibm.com/developerworks/forums/thread.jspa?messageID=14056243 developerWorks, developerWorks Forum, 2007 http://www.ibm.com/developerworks/library/specification/ws-rm/ IBM, BEA, Microsoft, TIBCO, Web Services Reliable Messaging Protocol Specification, 2005 http://specs.xmlsoap.org/ws/2005/02/rm/ws-reliablemessaging.pdf Web Services Reliable Messaging http://www.ibm.com/developerworks/webservices/library/specification/ws-rm/ Web Services Policy Framework
http://www.ibm.com/developerworks/webservices/library/specification/ws-polfram/
Understand WS-Policy processing http://www.ibm.com/developerworks/webservices/library/ws-policy.html Web Services Reliable Messaging http://www.ibm.com/developerworks/webservices/library/specification/ws-rm Web Services Reliable Messaging Protocol (WS-ReliableMessaging)
http://download.boulder.ibm.com/ibmdl/pub/software/dw/specs/ws-rm/ws-reliablemessaging200502.pdf
41
42
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Usage: WSRR subscriptions are by far the most robust method supported by DataPower to enforce governance policies. There are several access methods that are supported by WSRR and its policy object abstraction. In addition, caching the subscription objects is the only reasonable runtime option for working with dynamic runtime governance policy objects. Otherwise, production scenarios are most likely utilizing static WSDL objects defined in the file system. Remote lookup of UDDI repositories will probably introduce unacceptable latency issues without pre-caching.
43
Determining this is not a job for the WSRR but for the process developer. However, once the governance process is deployed, the WSRR needs to record who approved what changes for auditing purposes and to prove that the documented processes are being followed. See Figure 3-2 for a graphical depiction on the governance capabilities of WSRR.
GE
Organization Role Action Governed Entity Lifecycle State Concepts Documents Collections
State
State
GE
Access Control
Governed Entity
Actions
Development Specified
IT Governance Procured Approved State Process Published State Notification Collaboration Communication
New Version What was changed ? What was done to it ? Who changed it ? When did they change it ? Audit History Trail Operational
Deployment
Audit
Socialization
44
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Create
Plan
Authorize Development
Model
Assemble
Approve
SIT
Manage
Revoke Deprecate
Deploy
UAT Prod
Deprecated
Figure 3-3 WSRR default life cycle
From a DataPower perspective (runtime and management), we are interested in the interactions that WSRR has with the deploy and manage service life cycle.
45
are discoverable by DataPower. This capability gives you a trusted source for your SOA artifacts, since the artifacts cannot be changed or moved without the registrys knowledge. When UDDI is integrated with WSRR, the overview URL in UDDI points to the artifact inside WSRR. When artifacts in WSRR change, the UDDI registry is notified and updated. DataPower does not have any ownership of duties in these syncing events, as WSRR plug-in modules manage this activity. As discussed, DataPower by default can use file-based, static WSDL documents. But with WSRR it now can leverage the WSRR service discovery mechanism, which automatically searches a target application environment for services, and then loads the corresponding WSDL documents into WSRR. The service discovery mechanism also finds service component architecture (SCA) modules and loads them into WSRR. The service discovery mechanism updates the metadata in WSRR if the previously discovered services are uninstalled. This enables WSRR to be the authoritative source for all services, rogue and governed, in your SOA environment.
47
As an implementation device of Web services, DataPower does not have direct responsibility with the synchronization of WSRR and UDDI, but there are mapping considerations that must be taking into account that impact how the service or its policy is queried against either repository type (Figure 3-4).
WSRR-aware Products
UDDI-aware Products
UDDI Registry
48
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Security
As with all server communications that interact with DataPower, SSL is supported. We strongly recommend that each WSRR server connection be associated with a SSL Proxy profile.
Access methods
WSRR can store valuable service metadata that an application needs at run time to make decisions, such as where to route a message or what operation to execute upon receiving a message. In the role of a competent mediation appliance, DataPower can make intelligent queries for information from WSRR (such as WSDL information, owner of a service, or classification of a service). Figure 3-5 illustrates the use case of DataPower querying WSRR for runtime metadata. The architecture benefits of interjecting the flow with a mediation device is expounded upon in 3.3.5, Dynamic endpoint lookup on page 51. This enables key runtime information to be externalized from the DataPower configuration.
DataPower
Service Consumers
WSRR
Runtime ESB Metadata
49
DataPower uses the SOAP-based API to query WSRR as a default behavior (Example 3-1).
Example 3-1 Using a SOAP API to query WSRR amp;<xsl:stylesheet version="1.1" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:dp="http://www.datapower.com/extensions" xmlns:dpquery="http://www.datapower.com/param/query" extension-element-prefixes="dp" exclude-result-prefixes="dp"> <xsl:param name="dpquery:host" select="'WSRR'" /> <xsl:param name="dpquery:port" select="'9080'" /> <xsl:param name="dpquery:xpath-query" /> <xsl:param name="dpquery:comma-separated-properties" /> .... <xsl:template match="/"> <xsl:variable name="soap-query"> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <soap:Body> <executeQuery xmlns="http://www.ibm.com/xmlns/prod/serviceregistry/6/0/ws/sdo"> <datagraph xmlns="commonj.sdo"> <WSRR xmlns="http://www.ibm.com/xmlns/prod/serviceregistry/6/0/sdo"> <root>_1</root> <xsl:choose> <xsl:when test="string-length($dpquery:comma-separated-properties) > 0"> <artefacts xmlns="http://www.ibm.com/xmlns/prod/serviceregistry/6/0/sdo" xsi:type="PropertyQuery" bsrURI="_1" queryExpression="{$dpquery:xpath-query}"> <xsl:call-template name="process-properties"> <xsl:with-param name="properties-string" select="$dpquery:comma-separated-properties" /> <xsl:with-param name="count" select="1" /> </xsl:call-template> </artefacts> </xsl:when> <xsl:otherwise> <artefacts xmlns="http://www.ibm.com/xmlns/prod/serviceregistry/6/0/sdo" xsi:type="GraphQuery" bsrURI="_1" queryExpression="{$dpquery:xpath-query}" /> </xsl:otherwise> </xsl:choose> </WSRR> </datagraph> </executeQuery> </soap:Body> </soap:Envelope> </xsl:variable>
50
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Notice the parameters in this stylesheet, including one called comma-separated-properties, to choose between a graph query or a property query. Also notice that a soap-call() extension function is used to make the actual query to WSRR.
Change
Service Requestor
Service Provider
Service endpoint
Every time the physical endpoint of the service provider changes, every service consumer must reflect the changes in its application logic. DataPower can provide a better solution acting as an intermediary that intercepts a service call and routes it to the appropriate endpoint. Abstracting from transport-specific information to have a transparent intermediary layer between service consumers and providers is one aspect of the enterprise service bus (ESB) pattern (see 5.1.1, DataPower as an ESB on page 126). DataPowers Web Service
Chapter 3. Web services and policy management
51
Proxy implements a SOA-based ESB pattern by acting as such an intermediary layer. Implementing this part of an ESB layer in a static way by referencing WSDL files in the WS-Proxy component and providing a static service endpoint to the consumer provides a single point of control when changes are made to the real service endpoint, thus simplifying management of the service endpoint. With this approach, the service consumer is decoupled from the provider at the transport level, but changes on the proxy side are still necessary when changes are made on the providers endpoint (Figure 3-7).
Requestor Domain
Provider Domain
Change
Requires Change
Service Requestor
WS proxy
Service Provider
Service endpoint
Using DataPower's WebSphere Service Registry and Repository subscription feature inside the service proxy instead of statically referencing the WSDL file is the way to get a more dynamic service intermediary. DataPower can subscribe to WSDL files or to other artifacts stored in WebSphere Service Registry and Repository, and synchronize with changes either automatically by polling or manually driven from outside. From a service endpoint management point of view, this approach provides a flexible and dynamic ESB layer functionality that reflects changes to the endpoints automatically without having to make changes on the service consumer or on the ESB side (Figure 3-8).
Referenced service endpoint Service endpoint
Requestor Domain
Provider Domain
Service Requestor
WS proxy
Service Provider
Proxy endpoint
WSRR
Further reading: See Managing services dynamically using WebSphere DataPower SOA Appliances with WebSphere Service Registry and Repository at:
http://www.ibm.com/developerworks/websphere/library/techarticles/0802_rohmann/0802_rohmann.html
52
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
53
But this pattern is highly coupled. DataPower would be inserted as a mediation device to the services UDDI services repository, shielding and detaching the consumer from the services lookup and proxying the services interface (Figure 3-10).
Referenced service endpoint Service endpoint
Requestor Domain
Provider Domain
Service Requestor
WS proxy (DataPower)
Service Provider
Proxy endpoint
UDDI
3.3.8 Resources
For more information refer to the following resources: IBM WebSphere DataPower SOA Appliances Part IV: Management and Governance, REDP-4366 http://www.redbooks.ibm.com/abstracts/redp4366.html?Open WebSphere Service Registry and Repository Handbook, SG24-7386 Introduction to the IBM SOA Programming Model http://www.ibm.com/developerworks/webservices/library/ws-soa-progmodel/ Synchronize UDDI registries with WebSphere Service Registry and Repository for better SOA governance http://www.ibm.com/developerworks/websphere/library/techarticles/0802_olson/080 2_olson.html IBM WebSphere Service Registry and Repository Version 6.1 information center http://publib.boulder.ibm.com/infocenter/sr/v6r1/index.jsp Using DataPower SOA Appliances to query WebSphere Service Registry and Repository http://www.ibm.com/developerworks/websphere/techjournal/0805_peterson/0805_ peterson.html
54
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
A day in the life of WebSphere Service Registry and Repository in the SOA life cycle http://ltsbwass001.sby.ibm.com/cms/developerworks/websphere/library/techarticles /0609_mckee/0609_mckee.html Introducing IBM WebSphere Service Registry and Repository, Part 2: Architecture, APIs, and content http://www-128.ibm.com/developerworks/websphere/library/techarticles/0609_mckee2 /0609_mckee2.html
Client
WebSphere Server
Several BuyMyProduct.com customers have asked for an enhancement to the price quote service to respond with the current inventory level and the customer-specific committed price for the product. BuyMyProduct.com developed their new WSDL-Quote-Gold service and wants to offer this new service while continuing to support their WSDL-Quote service. The WSDL-Quote-Gold service is for privileged customers who register for the value-add service. When a customer sends a request to the WSDL-Quote-Gold service, the service responds with the price quote, the available discounts, and the current inventory level. To 55
support the discounts, the request and the response need to be signed and encrypted as well as contain a time stamp. At this same time, BuyMyProduct.com makes the decision to proxy both services on a DataPower device. The decision was to provide a single point for authentication and message security on the DataPower device while allowing the WAS engine to focus on application logic crunching (Figure 3-12).
Client
DataPower Device
WebSphere Server
The policy for the WSDL-Quote service indicates that the request must contain a UsernameToken in a WS-Security header. Because there is no attempt to verify the identity of the user, the policy is appropriate. The UsernameToken is important only for calculating the number of requests from a particular user. The policy for the WSDL-Quote-Gold service indicates that the request must contain a UsernameToken and message protection. The request and the response must be signed and encrypted. The request must contain a UsernameToken in a WS-Security header. The response does not contain the UsernameToken. To define the required policy for these services, an administrator to the DataPower device augments the base policy in the source WSDL files to include XML policy expressions in the provided policy templates. These templates contain the required WS-SecurityPolicy assertions to implement policy. These templates represent common security patterns.
This policy expression results in a message with the pattern shown in Example 3-3.
Example 3-3 Policy expression results <?xml version="1.0" encoding="utf-8" ?> <soap:Envelope xmlns:soap="..."> <soap:Header> <wsse:Security soap:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/ oasis-200401-wss-wssecurity-secext-1.0.xsd"> <wsse:UsernameToken> <wsse:Username>Shiu-Fun</wsse:Username> </wsse:UsernameToken> </wsse:Security> </soap:Header> <soap:Body> ... </soap:Body> </soap:Envelope>
56
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
57
58
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
<wsp:Policy wsu:Id="binding-policy"> <wsp:ExactlyOne> <wsp:All> <sp:AsymmetricBinding> <wsp:Policy> <sp:InitiatorToken> <wsp:Policy> <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ ws-sx/ws-securitypolicy/200512/IncludeToken/ AlwaysToInitiator"> <wsp:Policy> <wsp:WssX509V3Token10 /> </wsp:Policy> </sp:X509Token> </wsp:Policy> </sp:InitiatorToken> <sp:RecipientToken> <wsp:Policy> <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ ws-sx/ws-securitypolicy/200512/IncludeToken/ AlwaysToRecipient"> <wsp:Policy> <wsp:WssX509V3Token10 /> </wsp:Policy> </sp:X509Token> </wsp:Policy> </sp:RecipientToken> sp:AlgorithmSuite> <wsp:Policy> <sp:Basic128Rsa15 /> </wsp:Policy> </sp:AlgorithmSuite> <sp:Layout> <wsp:Policy> <sp:Lax/> </wsp:Policy> </sp:Layout> <sp:IncludeTimestamp /> </wsp:Policy> </sp:AsymmetricBinding> <sp:EncryptedSupportingTokens> <wsp:Policy> <sp:UsernameToken sp:IncludeToken="http://docs.oasis-open.org/ ws-sx/ws-securitypolicy/200512/IncludeToken/AlwaysToRecipient"> <wsp:Policy> <sp:WssUsernameToken10 /> </wsp:Policy> </sp:UsernameToken> </wsp:Policy> </sp:EncryptedSupportingTokens> </wsp:All> </wsp:ExactlyOne> </wsp:Policy> <wsp:Policy wsu:Id="request_parts"> <sp:SignedParts> <sp:Body /> <sp:Header Namespace="http://schemas.xmlsoap.org/ws/2004/08/addressing" /> <sp:Header Namespace="http://www.w3.org/2005/08/addressing" /> </sp:SignedParts> <sp:SignedElements>
59
<sp:XPath>/*[namespace-uri()='http://schemas.xmlsoap.org/soap/envelope/' and local-name()='Envelope']/*[namespace-uri()='http://schemas.xml soap.org/soap/envelope/' andlocal-name()='Header']/*[namespace-uri() ='http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecuritysecext-1.0.xsd' andlocal-name()='Security']/*[namespace-uri()='http: //docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility1.0.xsd' andlocal-name()='Timestamp'] </sp:XPath> <sp:XPath>/*[namespace-uri()='http://www.w3.org/2003/05/soap-envelope' and local-name()='Envelope']/*[namespace-uri()='http://www.w3.org/2003/05/ soap-envelope' andlocal-name()='Header']/*[namespace-uri()='http:// docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0 .xsd'and local-name()='Security']/*[namespace-uri()='http://docs.oasis -open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd' and local-name()='Timestamp'] </sp:XPath> </sp:SignedElements> <sp:EncryptedParts> <sp:Body /> </sp:EncryptedParts> </wsp:Policy> <wsp:Policy wsu:Id="response_parts"> <sp:SignedParts> <sp:Body /> <sp:Header Namespace="http://schemas.xmlsoap.org/ws/2004/08/addressing" /> <sp:Header Namespace="http://www.w3.org/2005/08/addressing" /> </sp:SignedParts> <sp:SignedElements> <sp:XPath>/*[namespace-uri()='http://schemas.xmlsoap.org/soap/envelope/' and local-name()='Envelope']/*[namespace-uri()='http://schemas.xmlsoap .org/soap/envelope/' andlocal-name()='Header']/*[namespace-uri()='http ://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0 .xsd 'andlocal-name()='Security']/*[namespace-uri()='http://docs.oasis -open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd' and local-name()='Timestamp'] </sp:XPath> <sp:XPath>/*[namespace-uri()='http://www.w3.org/2003/05/soap-envelope' and local-name()='Envelope']/*[namespace-uri()='http://www.w3.org/2003/05/ soap-envelope' andlocal-name()='Header']/*[namespace-uri()='http:// docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0 .xsd'and local-name()='Security']/*[namespace-uri()='http://docs.oasis -open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd' and local-name()='Timestamp'] </sp:XPath> </sp:SignedElements> <sp:EncryptedParts> <sp:Body /> </sp:EncryptedParts> </wsp:Policy> </wsp:Policy>
60
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
4. Sign the headers of the request message with the public key (PRK1) and public key (PUBK1) for the requestor. 5. Sign the body of the response message. 6. Encrypt the body of the response message. 7. Sign the headers of the request message with the public key (PRK2) and public key (PUBK2) for the provider or relying party. Instead of an administrator manually editing the WSDL file, the DataPower WebGUI allows administrators to abstract the tasks of authoring XML policy expressions and allows them to select different policy elements from common sets that are kept in XML files in the DataPower file system. Assumption: There are two key pairs that are needed for this message exchange, because BuyMyProduct.com must sign and encrypt the information that it sends back in the response to the requesting client. This required key material is already uploaded to the DataPower device. The configuration needs an identification credential and validation credential that were created from the key material in the Java keystore. To create the productQuoteService Web Service Proxy to use this policy, use the following procedure: 1. Log in to the WebGUI. 2. Click the Web Service Proxy icon on the control panel. 3. Select productQuoteService from the catalog. 4. Click the Policy tab. 5. Locate the WSDL-Quote-Gold service and click WS-Policy. 6. Click the Sources tab to define the additional source. a. Select store:///policies/templates and wsp-sp-1-1-was-wssecurity-username-default.xml from the URL selection lists. b. Click Attach Source. c. Click Done. You should see one external attachment beside the WS-Policy button. 7. Click the Processing tab to define the policy parameters for the key material. For signing messages: a. Select http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702 from the Policy Domain list. b. Select SignedParts from the Assertion Filter list. c. Select Signature Idcred from the Parameter Name list. d. Specify the name of the identification credential in the Parameter Value field. For verifying messages: a. Select http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702 from the Policy Domain list. b. Select SignedParts from the Assertion Filter list. c. Select Verification Valcred from the Parameter Name list.
61
d. Specify the name of the validation credential in the Parameter Value field. 8. Click Apply. 9. Click Cancel. 10.Click Save Config. For further reading see DataPower Web GUI Guide, 2007, IBM product documentation.
This design maps a service level agreement, such as bronze, gold, or silver, to criteria for determining which level of service should be permitted for each message. The XML is fairly easy to interpret. First, we know the SLA based on the AAA information. A particular user ID is entitled to one of the defined SLAs. Since this example is for a Web Service Proxy, we also know the WSDL name and the operation. Therefore, the stylesheet simply looks for an <operation> element in the XML, then for a <wsdl> element, then finally for an <sla> element based on the current message. The result, of course, is the number of TPS, which is the slm attribute in each of those elements. Example 3-7 is a snippet of the stylesheet.
Example 3-7 Snippet of stylesheet <xsl:variable name="wsdl" select="dp:variable('var://service/wsm/wsdl')"/> <xsl:variable name="result">
62
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
<xsl:variable name="byOperation" select="$mapdoc/SLAtoSLMmapping/sla[@name=$sla]/wsdl[@name=$wsdl]/operation[@name=$operatio nName]"/> <xsl:choose> <xsl:when test="$byOperation"> <root> <slm name="{$byOperation/@slm}"/> <slm-pool name="{concat($appId, '/', $wsdl, '/', $operationName)}"/> </root> </xsl:when> <xsl:otherwise> <xsl:variable name="byWsdl" select="$mapdoc/SLAtoSLMmapping/sla[@name=$sla]/wsdl[@name=$wsdl]"/> <xsl:choose> <xsl:when test="$byWsdl"> <root> <slm name="{$byWsdl/@slm}"/> <slm-pool name="{concat($appId, '/', $wsdl)}"/> </root> </xsl:when> <xsl:otherwise> <xsl:variable name="bySLA" select="$mapdoc/SLAtoSLMmapping/sla[@name=$sla]"/> <xsl:choose> <xsl:when test="$bySLA"> <root> <slm name="{$bySLA/@slm}"/> <slm-pool name="{$appId}"/> </root> </xsl:when> <xsl:otherwise> </xsl:otherwise> </xsl:choose> </xsl:otherwise> </xsl:choose> </xsl:otherwise> </xsl:choose> </xsl:variable>
The pattern is clear: The result contains a bit of XML, as in Example 3-8.
Example 3-8 Result with a bit of XML <root> <slm name="1TPS"/> <slm-pool name="bronze"/> </root>
63
The <slm name=1TPS/> element is passed to the SLM action in this example as an HTTP header, and the <slm-pool name=bronze/> element is passed as a SOAP header. Both are removed later by another stylesheet. They could just as easily be stored in context variables. In any event, these values are consumed by the SLM action downstream from the stylesheet. The SLM action is configured as shown in Figure 3-13.
64
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Each statement has a credential class that picks up the SLM level (from the <slm name=1TPS/> element) for the message. The resource class is the same for each statement, since it simply picks up the value from the <slm-pool name=bronze/> element. Figure 3-14 is an example of one of these SLM statements.
Note that the threshold level is the TPS value times the number of seconds, which is 3 in this case. The rest of the statement is unremarkable.
65
The credential class has to be set up carefully so that it will match the value from the <slm name=100TPS/> element (Figure 3-15).
In this example the TPS value, 100TPS, is picked up from the HTTP header and matched against the literal value 100TPS shown in the list box. This literal value must match the value in the <slm name=100TPS/> in the XML. The resource class just returns a string. In this example, it will either be something like bronze, bronze/parlayx_terminal_location_service_2_3.wsdl, or bronze/parlayx_terminal_location_service_2_3.wsdl/getLocation. Messages with the same string are grouped together for throttling, shaping, or logging.
You could even drive the scheduler stylesheet with its own XML configuration that specified the policies for choosing which message classes to favor. Alternatively, you could base the XML configuration on information determined off box.
67
68
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Chapter 4.
Security
The big benefit of Web services and XML is that these technologies make application integration easier and more intuitive. The counter to this is that this simplicity leads to new security exposures. Data must be protected from the public view and from tampering, control to critical services must be authorized, and malicious attacks must be detected and dealt with. WebSphere DataPower SOA Appliances offer a rich set of security features purposely designed to deal with these threats and exposures. In this chapter we describe DataPower's security features, including: Protocol-based security, including SSL Message-based security, including digital signature generation and verification, as well as data encryption and decryption The Authentication/Authorization/Audit (AAA) framework for access control Federated Identity Management The DataPower services addressed are: XML firewall (XF) Web services proxy (WS-Proxy) Web application firewall (WAF) Additionally, we address the close cooperation between DataPower and Tivoli's security management products.
69
Transport TransportSecurity Security Enterprise Information System Firewall Client System (browser, rich client) Firewall Web Application Server/Portal Server Existing Application Federate Identities with partners Auditing Confidentiality & Integrity ESB
Proxy
Propagate identity Fine level authorization Audit Propagate identity Application level authorization
For SOA to achieve its goal of business flexibility within an environment of governance and regulatory compliance, the definition and management of security policy need to be simplified. There must be consistent management terminology and semantics across the 70
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
various enforcement points. This defined policy can then either be directly enforced by the enforcement points or automatically translated into something that the endpoints can understand and enforce. Protection of data in transit and at rest Protection of data from unauthorized modification and disclosure is a key requirement within IT architecture. Data needs to be protected because it is business or privacy sensitive or both. A policy must therefore be in place to ensure that data is protected in both transit and at rest, with consistent security measures applied. Data protection is especially important when data moves outside the organizational boundary, which can happen without the knowledge of the consumer. For example, an internal service might be replaced with an outsourced service, with data now flowing to the external organization. If the data is business or privacy sensitive, then the service provider might need to ensure that appropriate protection is in place to satisfy the policy requirements of the calling organization. The need for demonstrable compliance with a growing set of corporate, industry, and regulatory standards Auditing of transactions is required to provide the data needed for assessing compliance, which measures the performance of the IT environment relative to measures established by the business policies. This might include verifying the working system against a set of internally created policies and also against external regulatory acts. Complexity is increased in SOA where different applications from different sources or vendors are targeted for different levels of compliance. This is especially true when accessing services provided by an external organization, where the regulatory and compliance regime is different from the requesting organization. If possible, the audit data produced by the various policy enforcement points must be integrated into a single repository, or federated into a single logical view of the data. This will facilitate the production of the required audit reports, verification of compliance against policy, and investigation of security-related events. The need for user and service identities and propagation of these identities across the organization The need to seamlessly connect to other organizations on a real-time, transactional basis
Chapter 4. Security
71
Potential SOA security breaches can come from anywhere, as shown in Figure 4-2. If a system can be accessed by outsiders (for example, through the Internet), an intruder could choose to send messages to a system in order to damage it or simply to consume resources. The same concerns apply to intranet or extranet access as well. Depending on the system, it is even possible that these intruders are authorized to use your system, but are trying to exploit that authorization in some inappropriate way. That is, the possibility of attacks (or other actions that can affect system response) from behind your own firewalls should not be discounted.
Identity Risk
General Population
Employees
Pr
iv a
te
Ne
tw
ork
Mitigation
Internet boundary
DMZ boundary
Intranet
boundary
Extranet
Partners
Suppliers
Identity Risk
Figure 4-2 Extended Enterprise SOA and IT assets: Where are the risks?
Web security has evolved from strictly Internet protections to internal considerations, so we expect that application security will also evolve to consider both external and internal threats. The distinction between external and internal threats is largely meaningless today, given large companies with sites spanning the globe, mobile workforces, contractors, wireless networking, and more. Nonetheless, in this chapter we use the term Internet-facing to signify outsider access. Therefore, one needs to consider the traditional security models, taking into consideration services integration across domains requirements. While the basic security issues (reliable authentication, authorization, DoS attacks, and so on) remain essentially the same, the existing solutions are not directly applicable. Systems hosting Web services, particularly public Internet-facing ones, should seriously consider the case for hardened gateway devices acting as XML firewalls to protect systems from XML threats. What is needed is something that understands the business-level protocols and can secure them. Stated simply, we need to ensure that only valid requests for valid services from
72
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
genuine clients penetrate the enterprise boundary. That is, an XML firewall is needed. That is where the DataPower appliance comes in. These threats are not addressed either when using traditional Web service gateways that neither look for most XML threats nor limit the traffic. This section illustrates how the above-mentioned security options can be accomplished with IBM DataPower appliances. The solution is to use DataPower as a proxy gateway. When acting in this role, the high-performance DataPower appliance can process incoming XML messages with validation turned on, while looking for XML threats. That XML-level protection enhances SOA security management. Protection from XML threats, as depicted above, is clearly only one way in which enterprise systems need to be protected. A comprehensive SOA security strategy requires multiple levels of defense and policy enforcement. But for these types of threats, DataPower helps protect SOA implementations with fine-grained access control, achieving integration with improved security access and leveraging policy systems, thus allowing for enterprise SOA deployments and centralized security policy management.
Firewall
Internet
HTTPS To Gateway
SECURE
SECURE?
Internet
SECURE? Business Partner
Chapter 4. Security
73
The dialog between the client and server points is represented in Figure 4-4.
Client
S D
PR O
Device
Pr o fe s s io na l Wo rkst at o i n 6 000
Client Hello
Verify protocol version Extract Server Random Extract select Cipher Suite and compression Algorithm
Verify it is a Client Hello Extract Client Random Select a CipherSuite and Compression Algorithm Server Hello
Verify Server Certificate Extract Public Key Recognize end of Server Hello Generate Premaster Secret Certificate* ClientKeyExchange Certificate Verify* ChangeCipherSpec Finished Indicates the Cipher Suite to be used for encrypted session to follow Decrypt and verify message content integrity with Cipher Suite and Keys Application Data * Optional Components
Certificate*
Server Key exchange* CertificateRequest* ServerHelloDone Decrypt the Premaster Secret with servers private key Generate Master and other keys Indicates the Cipher Suite to be used for encrypted session to follow Decrypt and verify message content integrety with Cipher Suite and keys ChangeCipherSpec Finished Application Data
SSL processing
SSL is a point-to-point security protocol supported by DataPower. Typically, this protection level is used to secure XML traffic through the Internet and inside the enterprise in certain circumstances. We can show how things are done by looking at the dialog between two points.
Client-to-device SSL
The main steps for this communication are: 1. The client sends a URL to the server beginning with https://. 2. The client wants to do SSL. The server sends the certificate to the client. 3. The client validates the certificate. 4. The expiration of the certificate is checked.
74
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
5. The identity in the certificate is checked to ensure that it is the same as that of the host that they are trying to reach. 6. The signer of certificate (could be signer chain) is checked against the trust store. 7. The certificate revocation list (CRL) is checked to see whether the certificate has been revoked. 8. The client encrypts a random secret message using the server's certificate and sends an encrypted message to the server. 9. The server uses its private key to decrypt the message and sends it back to the client. 10.The client verifies that this matches the secret message that it encrypted. 11.The client is assured that it is talking to the correct server. 12.The client and server now negotiate ciphers and begin encrypted communications over the transport. 13.In some cases we use mutual SSL, where both client and server verify each other.
Device-to-server SSL
For device-to-server SSL: 1. The cryptographic certificate is supplied by the endpoint application server. 2. The DataPower device validates the certificate (often including certificate chain). 3. The matching private key is maintained by the endpoint application server. 4. The application server may request the certificate from the DataPower device and validate (mutual authentication).
E n dpo int Ap p S ervers
W PM (A IX)
X S 40
Client-to-server-via-device SSL
The main steps are: 1. The DataPower device SSL terminates the connection with the client and provides the certificate. 2. The DataPower device SSL initiates a new connection with the server.
Chapter 4. Security
75
3. The DataPower device can use a back-end server certificate if the DataPower device has copies of the back-end server keys on board.
2. The external resource provides the certificate and may ask the DataPower device for the certificate. 3. The DataPower device validates the server certificate (actual certificate or CA certificate). 4. For the user agent configuration: a. Given a URL match, the user agent invokes the selected SSL Proxy Profile for outbound connections. b. The user agent invoked by the XML manager is used by the service. 5. SSL is applied: SSL proxy profiles (client, server, or both) may be used by: XML firewall MultiProtocol Gateway (through Front Side Protocol Handler) Web services proxy (through Front Side Protocol Handler) User agent (launched by XML manager)
76
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
SSL may be used through extension functions: i. URL-Open now takes an SSL Proxy Profile Argument. ii. SOAP-Call takes an SSL Proxy Profile Argument. iii. LDAP-* takes an SSL Proxy Profile Argument. Extension functions used by custom stylesheets
MQ and SSL
The steps are: 1. The remote MQ queue manager must first be configured to use SSL. 2. A client key is exported during that configuration process and uploaded to the DataPower device. 3. Both the key file and the password file must reside on the DataPower device. 4. The MQ queue manager object on the device must be configured to use the uploaded files. 5. The Cipher Suite Specification must agree with the remote QM.
Security Context
Requester
Intermediary
Intermediary
Web Sevice
Figure 4-9 Security context taken in account on message level protection basis
Chapter 4. Security
77
Figure 4-10 shows an example of this, where a Web service flow is sent encrypted using Web Services Security (WS-Security or WSS) standards from a client through the Internet. The intermediary DataPower appliance decrypts and authenticates the message before forwarding it in the clear over the last mile hop to the eventual service provider. Note that the appliance could just have easily secured the last mile encrypted under a transport-level mechanism such as SSL if the solution dictates.
Figure 4-10 Application-layer thread protection at message level with DataPower XS40
With Web services, message level standards have emerged, defining how to secure SOAP messages. The main concepts handled are: Data integrity Digitally sign the SOAP XML document, providing integrity, authenticity, and signer authentication, based on the W3C recommendation specification XML Signature. Data confidentiality Process for encrypting data and representing the result in XML, based on W3C recommendation XML Encryption. Username token profile Describes how a Web service consumer can supply a UsernameToken as a means of identification by user name and password. X509 Certificate Token Profile X.509 authentication framework within WS-Security.
Elements of a solution
To address the requirements of data protection, an ideal solution needs to include both business and technical aspects. From a business view, we need data protection, privacy, and disclosure control for managing the policies around how data needs to be protected in transit and at rest. This also includes interpretation of any privacy-specific policies. From a technical point of view, we need confidentiality and integrity services: A standards-based service to handle the data protection issues end-to-end. For example, Secure Sockets Layer (SSL) is the most common example of a secure transport level scheme. With SSL, the entire data stream is protected at a protocol level below the application layer. SSL is typically the secured protocol used to protect traffic between a Web browser and a Web server.
78
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
For these requirements, the advantage of using WS-Security instead of SSL is that it can provide end-to-end message level security. This means that the messages are protected even if the message traverses through multiple services, or intermediaries. Additionally, WS-Security is independent of the transport layer protocol. It can be used for any SOAP binding, not just for SOAP over HTTP. The solution can be delivered as shown in Figure 4-11.
Data Protection, Privacy and Disclosure Control
Policy Management
Firewall
Proxy
Firewall
Existing Application
ESB
Partner Application
Confidentiality Services
To address these needs, the DataPower implementation of the WS-Security specification provides such open standards based message level security and access control functionality. It can filter, validate, encrypt, and sign messages, helping to provide more secure enablement of high-value applications. DataPower can selectively share information through encryption/decryption and signing/verification of entire messages or of individual XML fields. These granular and conditional security policies can be based on nearly any variable, including content, IP address, host name, or other user-defined filters.
DataPower capabilities
The DataPower service allows the securing and encrypting of the communication channels between a service provider and a requesting client using Secure Sockets Layer by using the secure HTTP protocol named HTTPS. The DataPower portfolio currently includes two devices that can address security issues. The model XS40 is an XML firewall and a Web services gateway wirespeed appliance built mainly for security purposes. It can perform industrial-strength security as well as more advanced functions, such as operations on message content. The model XI50 is a complete super-set of the XS40. But in addition, the XI50 can enable an ESB because of its added interoperability with connectivity services.
Chapter 4. Security
79
As stated in previous chapters, DataPower is a SOA appliance that improves security with hardware and brings benefits such as: Sealed network-resident device Optimized hardware, firmware, embedded OS Single signed/encrypted firmware image Cannot install arbitrary software High assurance, default off locked-down configuration Security vulnerabilities minimized (few third-party components) Hardware storage of encryption keys, locked audit log No drives/USB ports, tamper-proof case FIPS level 3 HSM (option) Under evaluation by Common Criteria EAL4 Large financial and government customers usage DataPower provides front-end processing for Web services requests. It can work in close cooperation with Tivoli's security management products. It is a B2B XML Security Policy Enforcement system that includes XML acceleration. Additionally, DataPower appliances provide a sophisticated set of security capabilities, some of which are noted below.
Threat protection
DataPower includes XML threat protection as well as protection against non-XML threats such as Cross Site Scripting and SQL Injection.
4.3 WS-Security
WS-Security is an OASIS Standard and is the industry-adopted specification for securing SOA message exchange. This section tends to clarify how WS-Security is supported on the DataPower device and outlines the huge value engendered. The WS-Security specification describes enhancements to SOAP messaging to provide message integrity and confidentiality. The specified mechanisms can be used to accommodate a wide variety of security models and encryption technologies. 80
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
This specification also provides a general-purpose mechanism for associating security tokens with message content. WS-Security allows for the use of multiple security token types, which provides great extensibility. For example, a client might provide one format for proof of identity and provide another format for proof that they have a particular business certification. Additionally, this specification describes how to encode binary security tokens, a framework for XML-based tokens, and how to include opaque encrypted keys. It also includes extensibility mechanisms that can be used to further describe the characteristics of the tokens that are included with a message.
FIREWALL
Intranet
Gateway Back end Application Internet
Internet
SOAP message
Credentials
Business Partner
This specification provides a flexible set of mechanisms that can be used to construct a range of security protocols. The specification intentionally does not describe explicit fixed security protocols. As with every security protocol, significant efforts must be applied to ensure that security protocols constructed using this specification are not vulnerable to any one of a wide range of attacks. The examples in this specification are meant to illustrate the syntax of these mechanisms and are not intended as examples of combining these mechanisms in secure ways. The focus of this specification is to describe a single-message security language that provides for message security that may assume an established session, security context, or policy agreement. The Web services security language must support a wide variety of security models. The following list identifies the key driving requirements for this specification: Multiple security token formats Multiple trust domains Multiple signature formats Multiple encryption technologies End-to-end message content security and not just transport-level security
Chapter 4. Security
81
82
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Action types
The action types are: Encrypt action: An encrypt action performs full or field-level document encryption. Implementation of an encrypt action requires certain parameters that are supplied during service configuration. The DataPower interface provides a procedure to add an encrypt action to document processing rule. Decrypt actions: A decrypt action performs full or field-level document decryption. Implementation of a decrypt action requires certain parameters that are supplied during multiprotocol gateway configuration, a DataPower service. A DataPower interface provides a procedure to add a decrypt action to a document processing rule. The Decrypt Key drop-down list is employed to select a cryptographic key to use for decrypting the content.
Action types
The action types are: Sign action: A sign action digitally signs documents. In our case it mainly signs the incoming SOAP message before encrypting the message and sending it back to the client. Verify action: The decrypted SOAP message contains the signer certificate that can be verified to make sure that this is an acceptable message. Implementation of the verify action requires certain parameters that are supplied during the DataPower service configuration.
Chapter 4. Security
83
Note: This profile applies only to the use of the <ds:Signature> elements found directly within SAML assertions, requests, and responses. Other profiles in which signatures appear elsewhere but apply to SAML content are free to define other approaches.
WS-Federation WS-Policy WS-PolicyFramework WS-PolicyAttachments Policy Assertions WS-Security SOAP Foundation WS-Trust
WS-Authorization
WS-Privacy
WS-Policy
WS-Policy provides a flexible and extensible grammar for expressing the capabilities, requirements, and general characteristics of entities in an XML Web services-based system. WS-Policy defines a framework and a model for the expression of these properties as policies. Policy expressions allow for both simple declarative assertions as well as more sophisticated conditional assertions. WS-Policy defines a policy to be a collection of one or more policy assertions. Some assertions specify traditional requirements and capabilities that will ultimately manifest on the wire (for example, authentication scheme and transport protocol selection). Some assertions specify requirements and capabilities that have no wire manifestation yet are critical to proper service selection and usage (for example, privacy policy and QoS characteristics). WS-Policy provides a single policy grammar to allow both kinds of assertions to be reasoned about in a consistent manner. WS-Policy stops short of specifying how policies are discovered or attached to a Web service. Other specifications are free to define technology-specific mechanisms for associating policy with various entities and resources. 84
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Subsequent specifications provide profiles on WS-Policy usage within other common Web services technologies. WS-Policy is also covered in 3.2.2, Web Service Policy Framework (WS-Policy Framework) on page 30. Note: The specification that makes up WS-Policy is available for download from IBM developerWorks at: http://www.ibm.com/developerworks/library/specification/ws-polfram/
WS-Trust
WS-Security defines the basic mechanisms for providing secure messaging. WS-Trust specification uses these base mechanisms and defines additional primitives and extensions for security token exchange to enable the issuance and dissemination of credentials within different trust domains. The main goal of WS-Trust is to enable applications to construct trusted (SOAP) message exchanges. This trust is represented through the exchange and brokering of security tokens. This specification provides a protocol agnostic way to issue, renew, and validate these security tokens, and supports a range of security protocols. In order to secure a communication between two parties, the two parties must exchange security credentials (either directly or indirectly). However, each party needs to determine whether it can trust the asserted credentials of the other party. Thus, WS-Trust adds extensions to WS-Security, which provides: Methods for issuing, renewing, and validating security tokens Ways to establish assess the presence of and broker trust relationships Using these extensions, applications can engage in secure communication designed to work with the general Web services framework, including WSDL service descriptions, UDDI businessServices and bindingTemplates, and SOAP or SOAP2 messages. For a valid WS-Trust SecurityContextToken (SCT) request, a DataPower AAA policy can generate the appropriate security token response. This processing works as an on-box WS-Trust Secure Token Service (STS) that is backed by WS-SecureConversation. A WS-Trust token requires a symmetric shared secret key to initialize the security context. This processing can handle issue, renew, validate, and cancel operations against a request security token or request security token collection. Note: The specification that makes up WS-Trust is available for download from IBM developerWorks at: http://www.ibm.com/developerworks/webservices/library/specification/wstrust/
WS-SecureConversation
A requester can be authenticated by reference to an established WS-SecureConversation security context that must already exist. WS-SecureConversation credentials are taken from the WS-SecureConversation context token. After obtaining a set of credentials that attest to the identity of the client, a DataPower AAA policy can optionally map these credentials to a more useful format by performing custom processing on the received credentials and generating a requested WS-Trust token. This
Chapter 4. Security
85
token can then serve as a WS-SecureConversation token. The authentication credentials can then be mapped via any following WS-SecureConversation exchange.
Policy Administration
Policy Decision
Firewall
Firewall
Existing Application
Identity Services
Authentication Services
IT Security Services
Policy Enforcement
This is a very important aspect, because as part of the request flow from service consumer to provider through the DataPower ESB, the user context needs to be maintained and the security of the identity information ensured. For example, consider a use case where a request is coming from an internal service consumer using DataPower to invoke a service provider, as shown in Figure 4-14. The request arrives carrying a username token that carries identity information for the user USER1. DataPower calls the Security Token Services provided by Tivoli Federated Identity Manager to exchange the security token format to one supported by the service provider. For example, the username token is exchanged for a Security Assertion Markup Language (SAML) token. In addition to changing token type, the Federated Identity Manager STS can map the incoming identity information to an identity suitable for the service provider, for example, the USER2 identity is mapped to the service provider identity of USER1. DataPower has built-in capability for WS-Trust to invoke the Federated Identity Manager STS.
86
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
WS-Security acceleration
IBM performance labs have demonstrated a significant performance gain when using DataPower to handle some or all WS-Security processing in a message flow. This is the result of the hardware optimization used in both cryptographic and XML processing. For clients who wish to use WS-Security and have performance concerns, DataPower provides an ideal solution. The DataPower appliance can consume Web services using WS-Security at network speeds and then pass the messages on to the service provider without all of the WS-Security overhead. The same is true for the responses (when request/response is in use) where Web services responses can have WS-Security information added. Figure 4-15 shows this.
This proxying approach is very useful when identity propagation is used to bridge between multiple security contexts. For example, if the back-end Web service is hosted on WAS, DataPower can be used to extract the identity from a client credential, such as a SAML assertion, and presented to the WAS Web Service as an easily understandable LTPA token. There are many other examples of how DataPower can be used to extract, authenticate, and propagate identities. One must keep in mind that defining the correct security solution for any environment is an optimization exercise between protection level, performance, and maintainability. In complex distributed environments, expect the optimal security solution to be a mix of network-level, message-level, and data-level protection. This leads us to our next recommendation. For an application server based system using WS-Security where performance is a concern, consider using DataPower to handle this processing while establishing trust to the back-end service (for example, mutually authenticated SSL between DataPower and the application server).
WS-Security flexibility
When using DataPower to provide WS-Security as a proxy, we gain flexibility along three key dimensions. First, DataPower today (and in the near future) simply supports more of the WS-Security standards than our typical application server-based products. Secondly, DataPower fundamentally includes an XSL processing engine, so it is quite feasible to process Web services messages that are not quite in a format that an application server can understand. DataPower can alter those messages or more flexibly interpret them as needed. Thirdly, by offloading the WS-Security processing to DataPower, we eliminate the need to configure and reconfigure the back-end server (any application server) to understand different WS-Security messages. It is all transparent to the back end.
Chapter 4. Security
87
With regard to the first point, DataPower and other IBM products (such as WAS) will continue to be enhanced to support newer portions of the WS-Security standards, but at least for the near term, DataPower has features that are not found in other IBM products. This leads us to these recommendations: For clients who wish to use WS-Security but find that their application server is unable to support the standard of interest, they should evaluate DataPower to see whether it does support this standard or can be altered to support it. Clients expecting to frequently change the WS-Security formats expected or those with problematic messages (for example, nonstandard in some minor way) should evaluate DataPower as a solution to provide the needed flexibility. Closely related to the concept of flexibility is the concept of credential transformation. Since Web services requests often transition security domains, the credentials that arrive inbound to a boundary server often require transformation before being understood by the recipient or prior to sending on within the network. This transformation can occur along two dimensions: the technology and the naming. By technology we mean changing a credential from one type to another. For example, the sender might use digital signatures to provide identity information, while the internal systems expect username tokens. The second transformation is simpler but no less important. The name that represents a subject may change. For example, your identity to IBM might be your IBM serial number, but your identity to your bank could be your bank account number or social security number. Identity transformation addresses both issues. Traditionally, with IBM there have been two ways of approaching this problem: Custom developed ad hoc code. Leverage a product like Tivoli Federated Identity Manager (TFIM). Now DataPower provides a more robust means of providing credential transformation with Web services processing. DataPower can perform a fairly large class of credential transformations (both technology and naming) using built-in function as well as custom XSLT transforms. DataPower can also call out to products like TFIM to perform that translation. The obvious question is when to apply which technology. The answer is fairly straightforward. Recommendation: If DataPower is already in use for Web services security, when credential transformation is required, the native DataPower function should be used when sufficient. However, DataPower should be configured to contact identity-oriented products such as TFIM, particularly those requiring complex logic. TFIM should also be used when transformations occur in multiple places (for example, in DataPower and WAS) so that common function can be leveraged across the enterprise.
More information
Because Web services security is a quickly evolving field, it is essential for developers and designers to regularly check for recent updates.
88
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Make SOA real with IBM WebSphere Enterprise Service Bus and IBM WebSphere DataPower SOA Appliances, Part 2: Use WebSphere DataPower SOA Appliances extension functions for certificate-based XML standard encryption http://www.ibm.com/developerworks/webservices/library/ws-soa-real2/ Understanding SOA Security Design and Implementation, SG24-7310 http://www.redbooks.ibm.com/abstracts/sg247310.html?Open IBM WebSphere DataPower SOA Appliances Part II: Authentication and Authorization, REDP-4364 http://www.redbooks.ibm.com/abstracts/REDP4364.html?Open The XML Signature Workgroup home page can be found at: http://www.w3.org/Signature/ The XML Encryption Workgroup home page can be found at: http://www.w3.org/Encryption/ WS-Security specification 1.0 http://www.ibm.com/developerworks/library/ws-secure/ White paper of the Web services security roadmap http://www.ibm.com/developerworks/webservices/library/ws-secmap/ OASIS WS-Security 1.0 and token profiles http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=wss Understanding SOA Security Design and Implementation http://www.redbooks.ibm.com/abstracts/sg247310.html?Open
AAA framework
The acronym AAA stands for authentication, authorization, and audit. The framework set up by these concepts constitutes the cornerstone of access enterprise assets control by all users. Access control is about figuring out whether the identity claimed by an incoming message is indeed valid (authentication), and whether that identity is allowed to access the resource being requested (authorization).
Chapter 4. Security
89
DataPower appliances provide different means for implementing AAA. For more detailed information consult the DataPower XS40 or XI50 WebGUI documentation. Figure 4-16 illustrates the AAA framework.
IBM Tivoli Directory Server (LDAP) IBM Tivoli Access Manager Custom template AAA info file ...
Extract Identity
Authentication
Map Credentials
Extract Resource
Map Resource
Authorization
Accept IBM Tivoli Directory Server (LDAP IBM Tivoli Access Manager Any authenticated Passthrough Custom template AAA info file ...
This AAA framework makes a clear separation between authentication, authorization, and audit services in a loosely coupled way. DataPower appliances comprise these services loosely coupled, described in following paragraphs. For example, as a SOAP/XML message comes in, one has first to extract the identity claim, such as the user name and password, from the HTTP basic authentication header, and the resource, such as the Web services URL endpoint being accessed. Then one authenticates the extracted identity with either an on-board or off-board identity server, such as an LDAP directory. The result is a valid credential for the claimed identity. Both the credential and the resource can be optionally mapped using rewrite rules, then submitted during the authorization step to a policy server. In most security systems, authorization checking is only performed if authentication is successful. If authorized, one may do some post-processing for audit and accounting purposes, then pass the message on to the back-end application server. Otherwise, the message is rejected.
90
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
So an AAA policy offers the opportunity to use custom methods for most of the seven phases of AAA processing. These phases are: 1. Extract identity (EI). Establish an asserted identity from the contents of the message or protocol envelope. 2. Extract resource (ER). Establish a requested resource (commonly a URI). 3. Authenticate (AU). Authenticate the asserted identity. This is approved or disapproved by the authenticating agent. 4. Map credentials (MC). Transform or replace the extracted identity with another value, which may or may not be based in whole or in part on the extracted identity. This may also be none, which leaves the extracted identity intact. 5. Map resource (MR). Transform or replace the extracted resource with another value, which may or may not be based in whole or in part on the extracted resource. This may also be none, which leaves the extracted resource intact. 6. Authorize (AZ). Approve or disapprove the use of the mapped resource by the an agent identified by the mapped credentials. 7. Post processing (PP). Perform additional transformations or processing on the results of the previous steps. To handle the identity checking and related authorization, we need to represent and communicate it within the SOA infrastructure. Below are the main steps in processing AA.
Identity representation
The steps are: 1. Use a single identity representation mechanism and security policy across the entire architectural domain (whether that be project wide or enterprise wide). 2. Map a domain-wide identity down to the implementation identity (in the implementing application). In practical terms, a mixture of the two approaches is quite likely the only option, due to heritage application restrictions.
Identity communication
Use case: Identity propagation across ESB: Security context A security context is passed with all calls to the service via the communication transport (for example, RMI/IIOP, HTTP, or JMS). In the message The identity information and credentials are passed in the call to the service (that is, within the protocolfor example, in the SOAP header).
Chapter 4. Security
91
Extract identity
The extract identity phase retrieves the identity claim from the message. Within the standard AAA Framework, EI methods can include: XML standards-based identity claims such as WS-Security, SAML artifact, or SAML assertions, XML Signature DN Transport layer information such as HTTP Authentication header, SSL client certificate, HTTP cookie value Network metadata such as client IP address None of these methods require any custom processing or programming by a user. A custom method can be used to retrieve a custom identity claim. This section discusses the technical requirements to implement a custom identity claim. Inputs: The custom processing stylesheet receives the entire XML message as input. A range of DataPower extension functions (such as dp:auth-info() and dp:variable()) provide access to protocol header values. Outputs: The AAA system will consider any non-null value returned as the extracted identity. If the stylesheet returns no value, AAA will consider this as an error. Only auditing and post processing activities, if any are configured, will take place in this event. If a custom method is used for extracting an identity but a standard AAA policy method is used for authenticating, the custom method should provide certain information for the authentication method chosen.
Extract resource
The standard AAA policy can extract resources using any of the following: URL HTTP method (such as GET/POST) URI of toplevel element in the message Local name of request element XPath expression A custom processing method is not available for this step.
Authenticate
This step authenticates the extracted identity to obtain a set of credentials through any one of these standard methods, requiring no user development: On-board certificate or XML file listing valid identity claims Standards-based integration such as LDAP, RADIUS, XKMS, Kerberos, SAML assertions Integration with major access control vendors Custom authentication processing is also available. Inputs: The AAA system delivers the result of the EI phase wrapped in several tags. Outputs: The custom process should return a credential to signify authentication. This may take any form, including XML. To signify denied authentication, the custom process should return null or empty. The response from the authenticate phase is passed to the map credentials phase, then to the authorize phase. If there is no credential returned from the authenticate phase, and none is created at the map credential phase, then the authorize phase receives an empty map credentials phase. The standard AAA system then fails authentication and authorization.
92
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Map credentials
Optionally, map the credentials from the authenticate step to a different format, suitable for the authorization step. Inputs: The map credentials phase receives the result of the authenticate phase as its input, wrapped in several tags. Outputs: The AAA system imposes no requirements on the output of the map credentials phase. Any result is accepted. If the map credentials phase returns nothing, the standard authorize phase may fail, even if the Any Authenticated option is chosen. The presence of mapped credentials at the authorization stage represents successful authentication to the standard AAA system. A custom authorization method could change this behavior, however.
Map resources
This works the same way as map credentials, but this time mapping the extracted resource, such as rewriting the requested URL. Another example, the XS40 can concatenate the SOAP endpoint and the Web service operation to create a synthetic URL. This allows a traditional Web access control server (which only knows URLs as resources) to be used for authorizing access to the Web services. Inputs: The map resources phase receives the result of the extract resource phase. Outputs: The AAA system imposes no restrictions on the output of a map resources phase. If no resources are returned, the empty element will be forwarded to the authorization phase for processing.
Authorize
During this step, the mapped credential and mapped resource is used to authorize access. A number of standard methods are provided: XML file listing authorized credential/resource pairs Standards-based integration such as LDAP group membership, SAML queries, and SAML attributes from authentication Integration with major access control vendors It is possible to use a custom processing method to accomplish authorization. Inputs: The authorize phase receives four elements within a container for input. The ancillary information can be significant, such as when employing SAML. Check this value carefully, as it may contain information useful to the custom process. Outputs: The AAA system looks for a root <approved> node within the response from a custom authorize stylesheet. The response can be as simple as just <approved />. If the root node is not <approved>, the AAA system considers the authorization phase to fail, and thus the entire AAA action. To be explicit, the custom stylesheet can return a <declined> node for rejection. The contents of the <declined> node typically contain the reason for the decline.
Post processing
Within the standard AAA Framework, post processing provides for easily configured accounting and auditing. Post processing offers these features: Counters for authorized or rejected messages Logging of authorizations or rejections Security post processing, such as inserting a SAML assertion or a Kerberos ticket Custom processing
Chapter 4. Security
93
The post processing phase receives the output of the authorize phase. Post processing also receives the following variables: $identity $credentials $mappedcreds $resource $mappedres Output of the extract identity phase Output of the authenticate phase Output of the map credentials phase Output of the extract resource phase Output of the map resource phase
The output of the post processing phase is returned as the result of the AAA processing action.
AAA action
An AAA action is a DataPower object that references a specific AAA policy. It can be used on an existing processing rule. An AAA action can be implemented on every kind of DataPower service: XML firewall Multi-protocol gateway Web Service Proxy XSL Proxy While creating an AAA action, a reference to an existing AAA policy must be provided. If a AAA policy does not exist, it must be created, in keeping with the requirements and constraints of the current application. Note: An AAA policy is a DataPower object that can be referenced by different AAA actions, provided that they all (policy and actions) belong to the same domain.
It is possible to select several extraction methods. The DataPower AAA framework executes these methods in the following order: a. b. c. d. HTTPs authentication header Password-carrying usernametoken from WS-Security header Derived-key UsernameToken element from WS-Security header BinarySecurityToken element from WS-Security header
Therefore, it is possible to use a single AAA policy, which is in charge of extracting identity from different sources. These sources can implement different kinds of identification methods.
94
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
2. Authenticate. This step is mandatory. In this step, you define the method that is used to authenticate the asserted identity. There are many methods for authentication, a few of which are: Using a Lightweight Directory Access Protocol (LDAP) enabled directory server, such as IBM Tivoli Directory Server. Using IBM Tivoli Access Manager for e-business. Using a DataPower AAA info file: An XML file that contains authenticated identities and some values related to them. Using a custom template: Authentication may be managed through an XSL stylesheet that is responsible for authenticating the asserted identity. An empty output of this XSL means authentication failure to the DataPower AAA framework. 3. Map credentials. This step is optional. It may not be possible to use the extracted identity to authorize the use of the requested resource, especially when authorization is managed by an external authority. Interoperability between systems (DataPower device and system in charge of authorization) may require mapping between credentials. The supported methods that can be used for this mapping are: IBM Tivoli Federated Identity Manager AAA Info file XPath query Custom template WS-SecureConversation 4. Extract resource. This step is mandatory. The goal of this step is to retrieve the requested resource service, which is essential to complete authorization. The purpose of this extraction is to answer the question: What do you want to do? Several items are proposed to identify a resource, for example: Recover resource from local name of the requested of the message. HTTP operation. XPath expression. 5. Map resource. This step is optional. Interoperability between systems (DataPower device and system in charge of authorization) may require mapping between resources. Here are the supported methods and formats that can be used for this mapping: The IBM Tivoli Access Manager for e-business objectspace representation AAA info file XPath query Custom template 6. Authorize. This step is mandatory. Credentials and resources, which both may have been remapped, are submitted to the authority in charge of dealing with authorization. This authority may be the DataPower device itself or an external entity, such as: IBM Tivoli Access Manager for e-business An LDAP server, as IBM Tivoli Directory Server DataPower AAA info file
Chapter 4. Security
95
Custom template Authorization may be managed through an XSL stylesheet. Two different outputs are also possible for this XSL: Element <approved/>, which means authorization success to the DataPower AAA framework, Another element, as <declined/>, which means authorization failure
7. Post processing. This step is optional. Tasks may be set as a final step of an AAA policy. For instance, it is possible to add a WS-Security UserName token in the message. 8. Auditing. This step is optional. Audit consists of logging information that may assert that both authentication and authorization have succeeded or failed.
96
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
(SAML) AuthZ provider who can handle a SAML authorization query and produce a proper SAML authorization query response. For more details on SAML refer to: http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=security More information about the SAML specification is available from: http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=security
XACML PEP/PDP
There is an increasing demand today for a common language for expressing a security policy with a common policy language throughout an enterprise. XML is a logical choice as the basis for a standards-based security-policy language, due to its extensibility with syntax and semantics within the scope of security and policy management. The Extensible Access Control Markup Language (XACML) is an XML-based language that is designed to express security rules, policies, and policy sets that define the access rights of users (subjects) to resources. The XACML specifications were developed through a collaborative effort involving various companies including IBM, Sun Microsystems, and Entrust. XACML was ratified by the Organization for the Advancement of Structured Information Standards (OASIS) over five years ago. The goal of XACML is to provide a common policy language that allows organizations to enforce all of the elements of their security policy across all of the components of their IT infrastructure. After authentication comes authorization. Authorization means making a decision about whether an authenticated identity is allowed to access a resource. Two key inputs to making an authorization decision is an authorization policy and the security attributes of an authenticated user/system.
Chapter 4. Security
97
In some cases, such as for an XACML authorization scheme, the DataPower device can also act as the internal PDP (as well as a policy authorization point that holds the XACML policies) and provide a permit or deny decision based one or more XACML policies stored on the device. For example: Processing policy for a Web service Integrating Tivoli software products Tivoli Access Manager for e-business (TAM) or TIFM and Tivoli Directory Server (TDS) This maps the different steps of the DataPower AAA framework to specific IBM products and standards that may be used in each of these steps. For instance, for authentication, you may choose to use TFIM in a situation where you are implementing federated identity. DataPower acts as the point-of-contact server for that particular use case and defers the authentication to TFIM. Likewise, DataPower can defer authorization to TAM. (It should also be noted that when using TFIM, that TFIM will also use TAM for the same purpose.) Likewise, in the audit step, you can choose to log audit messages to the IBM Common Event Infrastructure.
Implementation
DataPower makes use of XACML authorization PEP and PDP to control access to a protected resource. The DataPower device usually works in the role of a PEP and coordinates (via a logical process called the context-handler) requests from a requestor, and queries an external PDP for a permit or deny decision and allows or prevents access to the protected resource. During the authorization phase of an AAA policy, one can select Use XACML Authorization Decision. The AAA policy acts as an XACML PEP. The PEP allows the XACML PDP to decide whether to authorize access. The DataPower device supports the mandatory to implement and optional functions that are listed in Section 10.2.8 of the OASIS Standard, eXtensible Access Control Markup Language (XACML) Version 2.0, dated February 1, 2005.
Summary
One challenge of having multiple PEPs and PDPs in the infrastructure is that they are often administered by different entities. Providing integrated and centralized decision capabilities reduces the administrative tasks related to policy management. There are many points of enforcement in the enterprise where a policy could be enforced over the wire from the Internet, within the extranet or by mail, VPN, remote access, and so on. DataPower as a security appliance helps to manage the configuration from centralized or decentralized endpoints, thus becoming a significant solution in controlling the costs of managing and implementing a robust and effective security policy. DataPower fits into the future direction to consolidate tools that communicate and operate via XACML language and enforce via PDP and PEP.
XACML scenario
A government agency provides medical and other services to veterans and has geographically distributed hospitals and physicians that need authorized access to private patient records over the Internet. This use case involves a physician A from ABC hospital making a request to read the medical record of her patient. Only the patients physician from ABC hospital has the security to access the records. 1. The physician logs in to her PC and uses the hospital software system to update the patients record located remotely at a government agency data center. The ABC hospital software generates a SOAP request (with a WS-Security header containing the doctor's username and password) to update the patient data in the government agencies' databases. A standard schema namespace http://www.medico.com/record.xsd is used for all transactions dealing with medical records, (Typically, DataPower would be leveraged to 98
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
digitally sign the record to ensure integrity and also encrypt it to ensure privacy, but that is out of the scope of this scenario.) 2. The request reaches the DataPower box (via the appropriate firewalls and routers) and is intercepted by the DataPower device acting as the PEP. 3. Extract Identity: The DataPower device extracts the user name and password from the WS-Security header. In a more typical scenario, the record would have first had its digital signature verified by DataPower and then encrypted prior to identity extraction. 4. Map credentials: None. (Output credential in the authentication is used.) 5. Authentication: The PEP uses the user name and password to authenticate the doctor using an XML file stored on the DataPower device. The output credential from the xmlfile is used in the authorization phase. This could very well have been any other authentication scheme returning an output credential like TAM, and so on. 6. Transform input: The PEP forms a XACML request using an XSL stylesheet XACML_Request_Transformer.xsl to transform the input SOAP message into a XACML request. The XSL stylesheet extracts the output credential obtained from the AU step from the DataPower device (using DataPower built-in functions and variables) and places it in the subject tag in step 7. The resource and action tags are copied directly from the SOAP request (using xsl:copy-of select= ). The subject, resource, and action that form an XACML request may be structured differently in the SOAP input depending on requirements. In that case the spreadsheet would have to do more work than a simple copy of tags from the input. 7. The XACML request is of the following form (Example 4-1).
Example 4-1 XACML request
<Request xmlns="urn:oasis:names:tc:xacml:2.0:context:schema:os"> Subject> <!-This is the identity that needs to access the resource --> <Attribute AttributeId= > <Attribute Value></Attribute Value> </Attribute> </Subject> <Resource> <!-The protected resource that needs to be accessed --> <Attribute AttributeId= > <Attribute Value> </Attribute Value> </Attribute> </Resource> <Action> <!-The action the identity wants to take on the resource --> <Attribute AttributeId= > <Attribute Value> </Attribute Value> </Attribute> </Action> <Environment/> <!-- This is optional --> </Request> 8. Extract resource (ER) is not really required because in this case the resource is being extracted directly from the input by the XSL stylesheet. No resource mapping is performed. 9. Authorization: The XACML request is forwarded to the deny-based policy decision point, which compiles the policy using the XMLManager (or retrieves a compiled policy from the cache) and validates the XACML request against the XACML policy. This particular
Chapter 4. Security
99
XACML policy is of the following form. Policies can vary and the XACML language is quite flexible, but that discussion is out of scope of this book. Look in the appendix for the actual policy used.
Example 4-2 Authorization
<PolicySet xmlns="urn:oasis:names:tc:xacml:2.0:policy:schema:os"> <Target> <Resource> <!-If the target resource (or subject) is not matched the PDP rejects--> <Attribute AttributeId= > <Attribute Value> </Attribute Value> </Attribute> </Resource> </Target> <!-Multiple rule results are combined by RuleCombining Algorithm - Policies contain rules' <Policy PolicyId="urn:vha:ReadWrite:policy" RuleCombiningAlgId=> <!-several rule combining algorithms are possible> <Target/> <!-Rules target matches attribute value to a fixed tag (designator) or a dynamic XPATH expression (selector) - Rule returns permit or deny depending on the "Effect" parameter ' <Rule RuleId="urn:vha:ReadWrite:rule" Effect="Permit"> <Target> <Resource> <ResourceMatch <AttributeValue> <AttributeSelector> OR <ResourceAttributeDesignator> </ResourceMatch> </Resource> </Target> </Rule> </Policy> </PolicySet> 10.Permit or deny returned by PDP to PEP, which returns a SOAP message to the client. The PDP could optionally return obligations that the PEP must fulfill successfully for a permit (not shown in Example 4-2). Resources for further reading are: Understanding SOA Security Design and Implementation, SG24-7310 http://www.redbooks.ibm.com/abstracts/SG247310.html?Open IBM WebSphere DataPower SOA Appliances Part III: XML Security Guide http://www.redbooks.ibm.com/abstracts/REDP4365.html?Open The XACML specification http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=xacml OASIS eXtensible Access Control Markup Language (XACML) Version 1.1 http://www.oasis-open.org/committees/download.php/2406/oasis-xacml-1.0.pdf
100
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
WebSphere Service Registry and Repository Handbook http://www.redbooks.ibm.com/abstracts/SG247386.html?Open Creating XACML Based Authorization using DataPower, Case Study by Karen Punwani
Auditing
Auditing includes maintaining detailed, secure logs of critical activities in a business environment. These critical activities can be related to security, content management, business transactions, and so on. Examples of security-related critical activities that can be
Chapter 4. Security
101
audited are login failures or successes, unauthorized or authorized access to protected resources, modification of security policy, non-compliance with a specified security policy, health of security servers, and so on. An audit logging service provides mechanisms to submit, collect, persistently store, and report on audit data submitted as events. The events can be in a common format, such as Common Base Event (CBE). Which events are audited and stored is defined in an audit policy. This policy needs to define which events are important, how long to keep the data, and whether to keep the audit data in a tamper-resistant form. Audit data must be collected for all of the security services.
Challenges
Figure 4-17 illustrates the challenge of providing access to consistent audit information across the environment. Audit information is required to be gathered from every component along the transaction path. That is, important events need to be logged and available for real-time or later forensic review. These events can be security specific, for example, authentication, authorization, identity mapping, identity provisioning, and policy management-related, or they can be of a more general nature, such as data or application access. There are a number of challenges when implementing an audit: Audit information is often physically located on the server that generates the event. For example, for all the different components, such as proxy, Web application server/portal server, and the ESB, a back-end database might write events to each components log file. This distribution of audit log information makes it difficult to later trace the events of a transaction end-to-end, because each log needs to be accessed. Additionally, different tools might be required to access this log information. Audit log format is often different on every component that generates an event. This is especially true when there is a heterogeneous mixture of middleware and applications. Real-time or forensic inspection of these logs becomes a difficult process of trying to understand the different log formats and collate related events. Compliance to internal or regulatory policy is very difficult to check. There is no automated way of knowing whether the security events that are being generated by the individual components are indicating compliance with policy.
Firewall
Proxy
Firewall
Existing Application
ESB
The DataPower devices can participate in the end-to-end auditing chain. Care must be taken to generate the correct log information and then verify compliance of the end-to-end system with internal and regulatory policy. In addition to out-of-the-box logging, one can build application-level logging by configuring log targets.
102
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Log targets capture logging messages that are posted by the various objects and services that are running in the system. Target types enable additional capabilities that include rotating files, encrypting and signing files or messages, and sending messages to remote hosts. Messages in log targets can be restricted by object filters, event category, and event priority. Many log target types can be used including SNMP, SMTP, caching, file on the device, and so on. By default, a log target cannot accept messages until it is subscribed to one or more events. One can use DataPower logs as the raw material to build higher level auditing capabilities by building application level logging. Application level logging is used as building blocks for specific auditing capabilities. In this way DataPower can participate in the end-to-end audit trail. In addition, offboard logging (out of memory) is also feasible.
Chapter 4. Security
103
XML-level protection enhances SOA security management. This simply maps the different steps of the DataPower AAA framework to specific IBM products and standards that may be used in each of these steps. For instance, as in Figure 4-18, for authentication, you may choose to use TFIM in a situation in which you are implementing federated identity. DataPower acts as the point-of-contact server for that particular use case and defers the authentication to TFIM. Likewise, DataPower can defer authorization to TAM. (It should be noted when using TFIM that TFIM will also use TAM for the same purpose.) Likewise, in the audit step, you can choose to log audit messages to the IBM Common Event Infrastructure.
Map Resource
Authorize
Extract Identity
SAML WS-Security SSL client cert HTTP Basic Auth
Authenticate
Map Credentials
TFIM
TAM
CEI
Figure 4-18 Combination of DataPower and Tivoli Solutions for AAA Framework
104
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Figure 4-19 shows a variety of users who are connecting to the applications at the bottom right. In this secured environment DataPower acts as the point-of-contact server (where requests actually arrive at the system). DataPower can then use the services of TFIM or TAM to authenticate and authorize access to the applications. DataPower would then pass authenticated and authorized requests on to the applications running on J2EE application servers, for example.
Access Manager (TAM) DataPower XS40 Federated Identity Management (TFIM) JAAS, JACC, W IM TAI, LTPA AMoS Applications
Security Enforcement - Authentication - Cred. Acquisition - Authorization - Single Sign-On - Policy Enforcement - Auditing
TAM provides authentication and authorization. TFIM provides federated identity between organizations.
Chapter 4. Security
105
4.5.1 Using WebSphere DataPower, Tivoli Security tools, and open standards
Figure 4-20 summarizes the use of security capabilities offered by DataPower and Tivoli.
Web Services
ws-security ws-security
Security . Enforcement
Presentation/Application Server
Security Enforcement
ws-trust
Web
ws-trust
ws-trust
TAM TDS
Identity and Access Management
ws-notification
TFIM
106
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Use
Use Tivoli Access Manager for secure Web SSO and XML Web services. XS40 provides the first line of XML defense and enforces access policy stored in TAM.
Access Manager
11.Federated identity among partners For example, an insurance company allows a retailers employees to check their insurance profile, stored in internal application servers, and not available previously.
Employer Insurance Co .
Internet
Application Server
Chapter 4. Security
107
Using a TAM client consists of two stepscreating the necessary TAM configuration files and then using them to create a DataPower TAM client. The TAM files that are created are: A configuration file that contains TAM infrastructure information A keystore file that contains the certificates necessary for communication with the TAM server A stash file (contains the password for the keystore) A DataPower TAM client object uses these files to interact with the TAM server specified in the configuration file. The TAM client configuration files can be used by multiple TAM clients in the same DataPower domain, but cannot be shared amongst other domains. Note that the remainder of this section discusses the TAM infrastructure of the management zone, as illustrated in Figure 4-23.
108
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
The remainder of this section discusses the TDS infrastructure of the management zone illustrated in Figure 4-24.
4.5.5 Summary
This section described the concept of the AAA policy with respect to DataPower SOA Appliances. In short, DataPower AAA policy objects provide a powerful mechanism to enforce access control for SOA deployments. The wide-ranging support of user identification, authentication, and authorization techniques of the AAA policy object offers a great deal of flexibility.
Chapter 4. Security
109
As background, we examine three different scenarios for using DataPower as part of the security infrastructure. These scenarios describe common cases for using DataPower, describe how the scenario is implemented with DataPower technology, and show why it is the best choice in each case. Using DataPower as an XML firewall Using DataPower as a Web services Gateway Using DataPower to secure service integration with WMB The use case is based on a DataPower XS40 appliance. One could also use the DataPower XI50 if you require its integration capabilities.
Suppliers
Partners
XS40 XML Security Gateway Data Repository Federated Identity, Security and Directory Services Centralized Security Policy Management Enterprise Directory
Users
As a first line of defense to securely implement external Web services, DataPower secures many applications and aggregate user interactions. Positioning a DataPower appliance in this manner give us a tremendous advantage to face the challenges below: Cross-enterprise interoperation: How can security be shared across organizational boundaries? Federated interoperability: For example, where do you store shared security states within a distributed network? Human and automated service invocations: How do components authenticate and apply access control to each other and to human operators?
110
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Dynamic service binding (as a result of loose-coupling) enablement: Implies the need to implement runtime security context generation and binding (for example, dynamic trust relationships). Global architectural layers impact: Enterprise, application, services, network, and transport layers. DataPower XS40 simplifies the secure integration of SOA applications by tying the SOA proposition to enterprise infrastructure security management solutions, enterprise identity management solutions, audit and compliance solutions, and other types of management solutions and tooling. Hercules provides one element of a secure SOA deployment. To be useful in an enterprise setting, it has to integrate or pre-integrate with some of the management solutions out there.
Chapter 4. Security
111
Web services are based on SOAP/XML/HTTP, which is very firewall friendly. What if you have a giant hole in the firewalls? Figure 4-26 shows standard SOA topology.
SOAPrequest
WSGW
Server
What is unfortunate about this topology is that requests must pass through the Web server, which provides little value other than being appropriate for DMZ deployment. The WebSphere Gateway (WSGW) does most of the real work. This is where DataPower comes in. Given what we have already discussed regarding its design as a hardened appliance (even more hardened than any reasonably hardened commercial grade operating system and Web server), we now have a new option. Our modified standard topology for Web services systems then becomes as shown in Figure 4-27.
S erv er
Notice that this topology eliminates the Web server as well as the Web Services Gateway. Not only is this more efficient, it is also more securea win-win situation. This leads us to the following recommendation. Recommendation: DataPower is appropriate for DMZ deployment. It should be used instead of WSGW in Internet-facing Web services applications. For testing, we chose a very simple but reasonable attack using a single SOAP message. This message is well formed, and can be sent to any Web service. The problem with the message is that it contains a large number of xml:ns tags. Such a message is easily generated using various programming tools. Sending this to a system does not take a high degree of skill. When the SOAP message was submitted to this Web service, application server CPU immediately raced to peak usage and remained there. Memory usage for the application server java.exe process also quickly spiked to its maximum configured JVM heap size. The
112
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
application server quickly ran out of memory, became unresponsive for an extended period of time, and then crashed with a javacore. This is a rather staggering situation. A single attacker can send a single SOAP message that will cause the product application server to fatally crash after first consuming enormous amounts of resources. If such a system was facing an untrusted network (for example, the Internet) it would be supremely vulnerable. To protect this system, we turn to DataPower. A Web services proxy has been configured on the DataPower box to front the Web service running on WAS. The default values were left intact on the Single Message XML Threats pane. Below is only a small sample of the many XML threat protection configurations available.
XDOS protection
When the application server was reinitialized, and the same request sent through with the DataPower proxy's host and port, the request was rejected by DataPower in less than one second, without WAS ever having to see or expend any resources processing it.
Chapter 4. Security
113
This pattern represented in Figure 4-28 offers tangible benefits such as: Availability as a DMZ component Masks internal resources: Host assets not directly accessible Secures transport layer: Offers SSL transport Validates messages XML well-formedness SOAP schema compliance Protects against denial of service: Examines messages for malicious format Really fast transform and filter services: Offloads expensive XML parsing from application servers Service level management
M essage B ro k e r
N etw o rk Infrastruc ture
S O A P /H T T P w ith W S -S e curity
ESB
Overview
The new and emerging tremendous challenge that we face today is not exposing Web user interfaces, but much more direct access to enterprise business logic in the form of Web services. In some cases, core business logic is now accessible outside of the enterprise for the first time. While such access enables greater flexibility and integration with partners, it also exposes business to far greater risks. Web applications come with intrinsic weakness that hackers can exploit to attack them.
114
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
To overcome such concern, you need to use IBM WebSphere DataPower SOA Appliances Services to enforce security within your enterprise. The DataPower Security Gateway Web application firewall (WAF) service can be deployed in front of multiple Web servers to protect Web applications. In this case, DataPower monitors application traffic, performs a wide set of checks for Web application attacks, and reacts in real time. On the WebGui, this service is represented by the icon shown in Figure 4-29.
Based on the typical deployment scenario diagram, in Figure 4-30 we depict the DataPower WAF service described in this section.
Web Application Servers
PRO L IAN T
External client
8000
SD
ESC
SD
DL T
The WAF service provides features to: Protect a back-end Web application from attacks using the built-in threat protection. Protect access to the Web application firewall. Validate parameters from an HTTP request using name-value profiles. The DataPower WAF service is used to offload some functions from Web-based service applications executing on application servers and to protect access to the enterprise back-end Web applications. For example, authentication, limiting requests, and parameter validation are typically Web application tasks, which can be configured with little effort on the DataPower appliance. These tasks are often performed on J2EE application servers such as WebSphere Application Server.
How it works
Deployed on the company DMZ or intranet, DataPower WAF service enforces security within the enterprise by executing a custom security policy on messages that go through HTTP traffic, before sending or receiving them to or from a back-end Web application. The DataPower Web application firewall service protection against malicious attacks is based on URL encoded strings. This allows defeating a wide range of application-layer attacks by providing immediate protection for applications against targeted vulnerabilities. WAF service is configured to virtualize a back-end Web application, handle rate limit requests, and enforce an AAA policy. In fact, the WAF service can listen for requests on
Chapter 4. Security
115
multiple TCP ports to virtualize or proxy back-end Web applications. The WAF service can also require Web clients to send requests over the Secure Sockets Layer. In situations when you need to limit the number of requests being sent to the back-end Web service, you can create a rate-limiting policy to control the number of requests. You can also require clients to provide credentials when trying to access the Web application, which can be enforced using a DataPower AAA policy. 1. A Web browser, as an external client, connects to the Web application firewall service. 2. Once the user has been authenticated, the request is forwarded to the back-end Web applications. 3. The Web application firewall service uses an AAA policy to validate users. This easy-to-apply policy saves time and provides immediate protection for production applications against Web application technology threats. Many of these threats simply pass through the Web-based typical security infrastructure. 4. In a production environment you would also need to secure the connection from the Web application firewall service to the back-end Web application, using either a security token or SSL. Of course, this is optional. The WAF service offers better support for HTTP-based traffic. For XML-only traffic, we would rather use other DataPower services such as XML firewall, Web Service Proxy, or multi-protocol gateway. HTTP threat protection is different from XML threat protection.
A map is chosen to execute based on the matching rule. More than one map can execute for a given request. Multiple maps can be defined per request and response. Maps execute based on the matching rule definition. Each profile implements the security policy configuration (AAA, HTTP threat protection, rate limiting, session management, and more).
Host virtualization
DataPower appliances are typically deployed in the DMZ, which lets them perform pre-processing on incoming messages before they enter a company intranet. Web clients should not know the back-end endpoint of your Web application because if the back-end endpoint changes, your Web clients need to be notified of those changes, and because malicious users can send multiple requests to try to overwhelm the back-end Web application. To hide the Web application end-point address from Web clients, you can define multiple TCP ports on which the WAF service listens for requests. This step is required when you are creating the WAF service.
In Figure 4-31, the front-side settings have SSL on, so the external client must connect using https. The part of the URI after the port number is the same URI sent to the back-end Web application.
Packet Filter
Demilitarized Zone
XS40
Internet
Packet Filter
Internet user
Intranet
Authentication
To authenticate: 1. 2. 3. 4. 5. 6. Create a new AAA policy. Create a new access control policy. Configure an access control policy. Define how to extract a user's identify from an incoming request. Define how to authenticate the user identity stated within the incoming request message. Check the credential mapping method.
Note: In a production environment, an authorized users list usually resides in a corporate directory server, such as a Lightweight Directory Access Protocol (LDAP) server. For test purposes, the list of authorized users can reside in an XML file named AAAInfo.xml. Since the file is included (disable in production) with every DataPower appliance, use it only for testing.
Authorization
Configure the authorization step in the access control policy to allow any authenticated user. 1. The Define how to extract the resources page specifies how the access control policy determines which resource the client has requested, for example, the URL sent by the client. 2. Check the resource mapping method. 3. The Define how to authorize a request page determines the access rules based on the resource and user.
Auditing
At the end, the AAA policy wizard lets you configure monitoring, logging, and post-processing options.
Chapter 4. Security
117
The authorized counter and the rejected counter keep track of how many requests were allowed or denied access, respectively. The rejected counter has an additional feature to block further requests if a threshold is reached. The logging section keeps track of the request and response message details for any authorized or rejected access attempts. The amount of message detail logged depends on the log level that you configure.
Post-processing
The post-processing section describes actions that you can apply to the message after the authentication, authorization, and auditing steps.
Rate limiting
High-volume Web sites may need to limit requests during certain periods. For example, a concert ticket Web site may experience a spike in traffic when concert tickets first go on sale. The WAF service lets you restrict the number of request messages within a given time interval. Requests over the specified number can be rejected, shaped, or logged. You can also limit the number of users connected and number of connections per user.
Summary
Securing the HTTP traffic in your company with the DataPower Web application firewall service provides you with a powerful and simple management solution of your back-end Web applications. You can use it to virtualize the endpoint address, handle rate limit requests, and enforce access control. You can configure these items using the Web application firewall service without writing any custom code.
118
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
The scenario in Figure 4-32 shows DataPower working in conjunction with WebSphere Message Broker. WebSphere Message Broker may be required for any of several reasons, for example, for the extensive predefined message sets, for the mapping capabilities of DataStage TX, the need for application-specific code (Java or C), or for complex event processing. The DataPower appliance is used to provide a high-performance Web services security gateway.
Clients
TAM TFIM
Clients connect to the DataPower appliance using SOAP over HTTP. The DataPower connects to WMB using MQ. Protocol transformation is a capability of DataPower XI50. This solution shows: Using WMB for existing code, or support for SWIFT, and so on. HTTP in MQ Out. WMB hosting an XML Web service. Use MPG or WS-Proxy, preferably. All the security infrastructure is based on XI50.
Chapter 4. Security
119
Alternative
The solution with DMZ placement should ideally be the one represented in Figure 4-33.
Enterprise Secure Zone
WMB V6 Subscribers
MQ
(disribute events)
MQ
Publishers
MQ
DataPower xs40
SOAP/ HTTP
Web Application
WAS ND V6 UDDI
TFIM
This solution shows: Using WMB for distribute events, and so on. WMB hosting an XML Web service. Use MPG or WS-Proxy, preferably. All the security infrastructure is based on XS40. Figure 4-34 illustrates the end-to-end scenario.
120
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
In this section, a multiprotocol gateway has been created as the core transformation engine. It will be enhanced to process WS-Sec messages as follows: 1. Request decryption. 2. Request verification. 3. Response encryption. 4. Response signing. 5. Policy enforcement. DataPower includes its own AAA info XML file that can be used to store rudimentary access control policies locally. However, it can also call out to external policy servers in order to make authorization decisions. Recommendation: DataPower should be used as the policy enforcement point for Web services authorization. It should interact with a central policy decision point, such as Tivoli Access Manager. 6. ESB security solution. The ESB security solution addresses the following requirements: Security for service consumers connecting to the broker via HTTPS and MQ Security for broker connections to service providers via HTTPS and MQ Transport-level message protection End-to-end propagation of user IDs in message security context Service-level authorization for ESB integrated with existing TMS's authorization providers such as Siteminder Policy Server and eDirectory LDAP Web services gateway for service consumers connecting to the broker based on WS-Security standard End-to-end identity management Definition of enterprise-wide security roles and security policies
Chapter 4. Security
121
Component architecture for the ESB Security solution is shown in Figure 4-35.
7. Security for service consumers connecting to the broker. Security for service consumers connecting to the broker is based on an implied trust security model: The ESB trusts all service consumer applications to implement the appropriate user authentication. The user identity is propagated by the service consumer applications to the broker in a trusted fashion. Based on the architectural decision AD01, the broker will require authentication of service consumers. For phase 3 the broker will use the following transport-level authentication mechanisms for service consumers: Two-way SSL for HTTPS connections: Authentication is based on the x509 Certificate presented by the service consumer application during the SSL handshake. MQ level security: Identification information included in MQ headers by MQ queue managers used by service consumers to send the message to the broker.
122
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Figure 4-36 pattern offers tangible advantages such as: Enhanced WS-*, WS-Security support Web services gateway functions Protocol transform HTTP<->MQ High performance non-XML and XML transforms
Non-XML
Network Infrastructure
ESB
4.7 Summary
WebSphere DataPower SOA Appliances enforce enterprise security policies uniformly on SOA traffic spread throughout the IT environment. DataPower's breadth of functionality combined with its hardened appliance form factor make it an ideal solution for SOA security. This is demonstrated through both its industry leadership and numerous deployments in the most secure IT environments in the world. The use of the DataPower Appliance provides security-conscious IBM clients with new and powerful options for creating secure systemsin some cases, new options where no feasible option previously existed. The results are: The highest levels of Web services security with negligible performance overhead The highest levels of SOA standards compliance Centralized management and enforcement of security policies
Chapter 4. Security
123
124
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Chapter 5.
Integration patterns
For small to large integration scenarios, IBM WebSphere DataPower appliances can simplify deployments, improve performance, and enhance the security of SOA implementations in the enterprise integration arena. The three product offerings of XA35, XS40, and XI50 provide a broad solution that addresses several integration scenarios. In addition to standalone scenarios, WebSphere DataPower SOA Appliances complement other productsboth IBM and third partyto support each stage of the SOA life cycle. But DataPower can also be implemented in non-SOA architectures and serve as a key component in messaging-based gateways with XML and non-XML binary traffic. Combined with its strengths in security, the XI50 appliance is a very powerful offering for managing messaging flows entering and traversing the enterprise.
125
126
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Web services gateway functionality (eligible for DMZ deployment). Optimized any-to-any transformation, including non-XML via WTX. Other integration client support WS MQ Database ODBC interface TIBCO EMS IMS
As such, they differ from traditional software approaches of hub-centric or application server centric integration architectures along these three dimensions. That is, DataPower appliances are a hardened solution, targeted toward specific functional processing. DataPower provides core ESB functionality, which is to provide a service infrastructure within an organization, and it can also be used to federate ESBs within an enterprise. There are three possible placements of DataPower in an ESB scenario, shown in Figures Figure 5-1 through Figure 5-3 on page 128. Federated ESBs can be serviced through either internal gateway placement or the DMZ.
Enterprise Demilitarized Zone
Partner Zone
<Service Provider>
ESB
<Service Provider>
XI50
<Service Consumer>
<Service Consumer>
Partner Zone
<Service Provider>
<Service Provider>
XI50
ESB Federated Gateway
<Service Consumer>
ESB
<Service Consumer>
127
Partner Zone
<Service Provider>
ESB
<Service Provider>
XI50
DMZ Gateway
Domain Firewall
<Service Consumer>
<Service Consumer>
DataPower can provide fundamental ESB functionality within and at the edge of the ESB. Placement of DataPower in the DMZ would be required to allow for proper credentials around secure access.
128
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Therefore, an ESB should provide efficient, flexible logging facilities that allow messages to be captured and logged, based on a number of user-defined filters.
129
than one duration monitor for any given service. Duration monitors can distinguish the direction of the message. These monitors can be queried through the SOAP interface. Duration monitors can support the same use cases as count monitors and can shape traffic with delay or throttle requests. Relevant examples are: Protecting back-end application resources when application latency reaches a configured threshold Emitting shaping traffic events when processing latency reaches a configured threshold, so as to meet service level agreements
5.1.4 Routing
Routing is one of the more complex yet useful facilities offered by an ESB. For most practical purposes, there are two major reasons why a message may need to be routed, both of which an ESB should support: Quality of service: Not all services are created equal, nor are all customers. When a service level agreement exists for a service, it is sometimes necessary to prioritize requests based on information about the request, about policies that relate to that request, and about the level of service that is available from the services on the bus. Support of specific functionality or affinity: In many cases, there are alternate providers of a service that differ in service version or implementation. Session state may exist on a particular destination, requiring affinity-based routing. In both cases, there are several ways in which the information comprising the message should be examined, leading us to several other routing capabilities that must be supported by an ESB: Content-based routing: Routing based on the actual message body, or on the content of headers specific to the transport or protocol over which the messages are traveling Context-based routing: The ability to rely in other sources of information to determine the routing path of messages Aggregation and disaggregation: The ability to split or recombine messages DataPower has strong support for content-based routing and can interrogate either the header or body for routing instructions. Because it leverages the near wire-speed of its XSL processor, its decisions on IP and port decisions are extremely fast. For static instructions, the fundamental object that drives this functionality is the XPath routing map, which is an object found in the OBJECTS/XML processing/XPath routing map. The XPath routing map enables XPath-based forwarding on the part of the device. That is, the selection of a target Web or application server can be based upon the contents of the XML document being processed. An XPath routing map consists of one or more forwarding rules, arranged in a sequential list. Each forwarding rule consists of an XPath expression accompanied by an IP address-port pair (specifying the destination address) and a binary flag designating the intent to secure the wire with SSL. With XPath-based forwarding enabled, the device employs user-provided XPath expressions to scan the contents of incoming XML documents. If the document contents match an XPath expression contained in a forwarding rule, the document is forwarded to the specified IP address-port. A candidate document is sequentially evaluated against each of the XPath maps forwarding rules, with the first match providing the forwarding instructions.
130
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Content-based routing is fundamentally dynamic in nature, and follows the proxy pattern where the initial inbound message flow is halted at the device (that is, within the DMZ), a proxy is established, and the flow is re-initialized. It is at this point that the routing instructions are established and IP/port determination is made prior to sending on the proxied message. This routing pattern should not be confused with the static routing capabilities of DataPower in configuring a VLAN. DataPowers multi-protocol gateway (MPGW) can be configured to heavily leverage the dynamic routing pattern. This gateway can support more than one client (or front-side) protocol, and it can also support more than one back end, server, or protocol. With support of many-to-many protocols and routes, the MPGW will be making decisions on different IP/port destinations that map to the specific protocol that is being converted or maintained. Thus, by default the MPGW will be employed in some fashion in many scenarios that require dynamic routing, particularly when there are requirements for protocol conversion. See Figure 5-4.
131
For any protocol conversion requirements, ESB architecture or other, the DataPower multi-protocol gateway service (2.3, Multi-protocol gateway service on page 15) provides the necessary functionality to handle the protocol conversion (or protocol bridging) and is housed only in the XI50. The MPGW service supports the following client-side and server-side protocols: HTTP HTTPS MQ messages WebSphere JMS FTP Including GET and POST. POST can contain XML, SOAP, DIME, and SOAP with Attachments. Including GET and POST. POST can contain XML, SOAP, DIME, and SOAP with Attachments. The gateway can use GET and PUT queues to communicate using MQ messages, if licensed only on the XI50. Supports the default WebSphere JMS server. The gateway can act as either an FTP client, polling a remote FTP server for requests, or as an FTP server, accepting incoming FTP connections. The gateway can accept incoming IMS protocol requests and can initiate IMS connections on the back side, if licensed only on the XI50. Supports TIBCO Enterprise Messaging Service, if licensed. The gateway can poll an NFS-mounted directory for the presence of new files and place responses on an NFS-mounted directory.
A typical protocol conversion example for which DataPower XI50 is optimized is a SOAP/HTTP/HTTPS request that comes in and a back-end EJB service provider that is listening and communicating over JMS. See Figure 5-5.
Service Requester
SOAP/HTTP
Service Provider
JMS
As the protocol mediator, DataPower must address the situation where HTTP/HTTPS traffic is inbound and has the capability of mediating the following message requests of request/response (asynchronous or synchronous) or fire-and-forget (see Types of message requests on page 136). Regardless of message type, DataPower has the ability to become a high-performance HTTP proxy whether the client is in blocking mode or not. Typically, todays Web-based scenarios are asynchronous, but back-end systems are transaction oriented and prefer to consume their messages synchronously for transactionality. So there are state management responsibilities for the mediator as well as protocol conversion. A distributed architecture can push these mediation duties to each provider, but it is a more efficient and effective architecture to have a centralized mediation point to provide mediation services and off load this work away from the application servers. For example, leading J2EE servers such as WebSphere Application Server (WAS) have a mediation engine with WebSphere ESB that has protocol conversion capability. But the mediation engine puts load on the application processors and can degrade performance, particularly when message transformation and translation duties are included. It is application friendly to provide the protocol that each respective application front end prefers while
132
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
pushing the mediation duties to devices that are dedicated for such services. With DataPower, combining mediation duties with its other security and messaging proxy duties is an extremely efficient architectural decision. Usage: Protocol mediation has support in several of its primary services but in varying degrees based on the service (see product documentation for more detail). MPGW: Multiple protocol support is provided in the following: Front Side Handlers HTTP HTTPS FTP Server FTP Poller MQ Raw XML JMS NFS Poller HTTP/S MQ WAS-JMS TIBCO-EMS FTP
Back-end URLs
Limited in XML firewall (HTTP/HTTPS) WS-Proxy Endpoint handlers: Front Side Handlers HTTP HTTPS FTP Server FTP Poller MQ Raw XML JMS NFS Poller)
Limited back-end choices URL-opening a style sheet adds more opportunity HTTP/HTTPS FTP ICAP NFS SMTP SNMP TCP MQ SQL TIBCO-EMS WAS-JMS
133
Binary transformations For an ESB to be useful in an enterprise environment it must be able to deal with services that have not been implemented using XML or the latest in WebService-* protocols. The majority of corporate data today exists in traditional format. For the large customers this means mainframe databases. The ability to interface with existing COBOL and RPG programs gives an ESB designer much more flexibility to provide service modernization. This increases the number of service consumers that can take advantage of these programs and data and extends the reach of the ESB further into the enterprise. In the end, this increases overall value of the ESB and can improve time-to-market of new enterprise services. DataPower is a device very focused on transformation and translations based on open standard technologies such as XML. But DataPower has been enhanced with WebSphere Transformation Extender (WTX) to provide support for XML-to-binary and binary-to-XML transformation on the appliance without having to write any XSLT. As in the standalone product, writing binary transformations is as simple as using the Design Studio graphical user interface to define inputs and outputs and then map between them. This is discussed in detail in 5.2.1, WebSphere Transformation Extender (WTX) on page 145.
134
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Content enrichment and filtering Enterprise modernization often requires that a result from service invocation be enhanced with additional information from other data sources in order to meet the requirements of industry-specific XML schemas. Content enrichment is the ability to invoke several services or database queries and combine the results as a single service response. An equally important function, content filtering, is the removal of extraneous content from a message based on rules and policies. The DataPower XI50 provides several avenues to support content enrichment. By itself, XSLT and binary transformation is an inline process that does not directly support content enrichment (it could be achieved but would be convoluted and difficult to build). So we need a way to augment the transformation on the fly. DataPower provides several connectivity services that can provide access to data services that could be the source of enrichment. In most scenarios the multi-protocol gateway service is the service selected for content enrichment, as multiple inputs and protocols are required. The connection alternatives are: SQL data object: This is the typical access method used, since databases provide the most relevant data for enrichment. Content enrichment is unique in that almost always read only is the typical data access method required. This is because the enrichment task is populating or rewriting a body or header during the inline processing of the document. Data altering functionality at the source is usually not required and not typically desired, so that one does not impede the messages in flight with latency issues associated with a commit transaction. DataPower supports this with a read-only object parameter. Messaging objects, JMS, MQ, EMS: These DataPower objects are also an option, but usually there is too much potential latency in a request/response scenario on a message bus for content-enrichment requirements. Typically, only small runtime increments are allotted for content-enrichment activities. DataPower, with its high-throughput capability, can be caught in time-out scenarios in high-latency request/response scenarios, and the resulting exception processing would have to be treated as a failed request and processing of the message halted. See Figure 5-6 for a content-enrichment scenario.
Service Provider
SOAP/HTTP
DataPower MPGW
Service Consumer
JMS
135
5.1.8 Connectivity
In this section we discuss connectivity.
136
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Fire-and-forget The requestor sends a message to the ESB and no response is expected. The client can immediately continue to do other work. Publish/subscribe The pub/sub pattern supports one-to-many relationships between publishers and subscribers. Subscribers indicate their interest in topics. Whenever a message is sent to this topic by a publisher, the message is forwarded to all subscribes. This pattern is extremely useful to address many business problems and hence should to be supported by the ESB. It requires an additional integration product to help DataPower participate in a pub/sub scenario. DataPower by itself does not provide built-in publish/subscribe functionality. But Datapower can leverage integration products that do have built-in pub/sub capabilities such as WMQ, JMS, and TIBCO, and all of which have client support on the Datapower device.
JMS
Java Message Services (JMS) is Sun's standard API for messaging middleware. JMS is a Java API for accessing messaging middleware. Messaging middleware acts as a broker to provide asynchronous delivery of data between applications. Messaging middleware: Acts as an intermediately between the producer and consumer of the message Ensures reliable message delivery Messaging middleware stores, routes and manages messages for delivery. Imagine a courier service where you drop off a package for delivery. That company ensures that your package will be delivered by a certain time. If the other party is not available, it will hold the package for later delivery or pickup. This is essentially how messages are routed through messaging middleware's services such as JMS. The application that produces the messages is known as producer, and the application receiving the messages is known as consumer (Figure 5-7).
Client applications (producer) puts messages on a queue Server applications (consumer) gets messages from a queue
Producer
Consumer
Queue
137
provider in WebSphere Application Server using JMS. Instead, it uses the IBM JetStream Formats and Protocols (JFAP) to communicate with the service integration bus. JFAP is conveniently used by the default JMS provider in WebSphere Application Server. With JFAP support via a WebSphere JMS object, a multi-protocol gateway can provide default JMS capabilities both as a client-facing and a server-facing messaging service (Figure 5-8).
WebSphere JMS Server Object (JFAP) Web service client WebSphere JMS messages SOAP/JMS Web service "Put" request queue "Get" reply queue
138
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
A bootstrap server is an application server running the SIB process, but need not be running any message engines. Rather, the bootstrap server selects a messaging engine that is running in an application server that supports the bootstrap protocol requested by the remote device (Figure 5-9). To connect to a messaging engine, the remote application first connects to a bootstrap server. The bootstrap server selects a messaging engine and then tells the client application to connect to that message engine to gain bus access.
Bootstrap Server
3. Optionally, configure security (SSL, user name/password), transactionality, connection, and memory settings.
139
140
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
To facilitate the schema validation process, we introduce Schematron, a declarative validation language that enables the checking and cross-checking of XML content through the specification of rules in XPath, and of custom error messages should the rules fail. This language allows us to dynamically create intermediate XSL stylesheets based on simple rule language constructs. After Schematron rules are defined in an XML format, the rules document is transformed into an intermediate XSL stylesheet using the Schematron XSL stylesheet. The resulting new XSL stylesheet is then applied to each XML document and will, if the content is not as expected, produce custom messages in the exception process. Figure 5-10 shows the architecture design for this scenario.
SOAP/HTTPS with WS-Security Schematron XSL Stylesheets
Patients XI50 XML WAS Web Service Java bean XML DB2 pureXML Patient database
Doctors
Administrative
Federated Identity, Security and Directory Services Centralized Security Policy Management Enterprise Directory
<?xml version="1.0" encoding="utf-8"?> <schema xmlns="http://purl.oclc.org/dsdl/schematron"> <title>Simple Schematron Validation Example</title> <pattern name="Personal Information"> <rule context="/person/name/first"> <report test="text() = 'gerard'"> First name must not be 'gerard'!
141
</report> </rule> </pattern> </schema> The above example looks up the first name in an XML document, checks whether the first name equals gerard, and prints a validation failure message if it does. In case of validation failure, the message would be First name must not be 'gerard'!. 4. Sample XML documents are created that are valid and invalid with respect to validation against the XML schema and test the Schematron rule defined above.
Summary
This section showed how DB2 pureXML and the WebSphere DataPower SOA Appliance can compliment each other to realize powerful applications, where the WebSphere DataPower appliance performs XML validation, and the DB2 pureXML database manages the XML storage, indexing, and querying. Both XML structure validation (through XML schema) and content validation (through Schematron) have been described. The combination of the two products, WebSphere DataPower and DB2 pureXML, provides flexible and speedy access to validated XML documents. 142
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Note: This scenario is based on work found in the article XML schema and content validation using DataPower and DB2 pureXML, which provides a detailed overview on how the scenario is set up, including a sample XML schema, sample XML documents, a Schematron example, a DB2 pureXML database, a data Web service, and the configuration of a WebSphere DataPower SOA Appliance. http://www.ibm.com/developerworks/db2/library/techarticle/dm-0805malaika3/index .html?ca=drs-#resources
Resources
For further reading see: XML schema and content validation using DataPower and DB2 pureXML: http://www.ibm.com/developerworks/db2/library/techarticle/dm-0805malaika3/index .html?ca=drs-#resources DB2 9: pureXML Overview and Fast Start, SG24-7298: http://www.redbooks;.ibm.com/abstracts/SG247298.html?Open Schematron Web site: http://www.schematron.com/overview.html Generate Web services for DB2 9 pureXML: http://www.ibm.com/developerworks/db2/library/techarticle/dm-0706bommireddipalli/ Get started with Industry Formats and Services with pureXML: http://www.ibm.com/developerworks/db2/library/techarticle/dm-0705malaika/ Industry Formats and Services with pureXML: http://www.alphaworks.ibm.com/tech/purexml
TIBCO EMS
The TIBCO EMS server is analogous to a WebSphere MQ queue manager in that it manages PUT and GET queues. The TIBCO EMS server provides messaging services for communicating applications by monitoring queues, by ensuring that sent messages are directed to the correct receive queue, or that messages are routed to another queue manager. With the TIBCO EMS connector object, DataPower can act as a gateway to another bus technology that resides in the ESB. There is no rule that says that any ESB must use only one bus technology. In reality, larger enterprises will quite possibly possess more than one bus technology that has been procured in different budget cycles or that was obtained in an acquisition with the resulting merging of IT infrastructures. With gateway capability to TIBCO EMS as well as to WebSphere MQ, DataPower is particularly strong when acting as a proxy to multiple ESBs. This is known as a Federated ESB topology. TIBCOs EMS is JMS compliant. This simplifies the task of DataPower in a federated gateway role, particularly as the XI50 has a JMS connector object. For more information see JMS on page 137. Note that TIBCO Rendezvous (RV) is not supported. TIBCO RV is an older bus technology that is still used today in heritage solutions. The supported architecture for this scenario is to connect a TIBCO EMS provider with an RV request, and the DataPower EMS client would connect to that EMS provider.
143
For all of these scenarios, refer to Figure 5-11. Note that the XI50 can also reside in the DMZ.
Enterprise Demilitarized Zone
Partner Zone
<Service Provider>
MQ
ESB
<Service Provider>
XI50
ESB Federated Gateway
JMS
<Service Consumer>
ESB
<Service Consumer>
EMS
5.1.9 Summary
Enterprise service bus is an architectural concept that is well supported by the IBM product portfolio including DataPower. These products will continue to be enhanced to meet the evolving requirements of the ESB. Using an ESB will become a critical system resource for many that will provide the availability, reliability, manageability, and security necessary for enterprise integration systems. DataPower possesses all the major services that are required in order to implement an ESB: Transformation Routing Validation Authentication Logging Protocol bridging When some connectivity is required outside of WMQ, JMS, EMS, or SQL, then the solution can be augmented with such products as WESB and WMB that contain full suites of IBM connector technology. As an appliance, hardware and software are contained in one solution. When the performance capabilities are considered, the price performance of DataPower as an ESB solution is hard to beat.
5.1.10 Resources
For further information see: Combining Service-Oriented Architecture and Event-Driven Architecture using an Enterprise Service Bus http://www.ibm.com/developerworks/library/ws-soa-eda-esb/ Enterprise Service Bus implementation patterns http://www.ibm.com/developerworks/websphere/library/techarticles/0712_grund/071 2_grund.html 144
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
RV
Patterns: Implementing an SOA using an Enterprise Service Bus, SG24-6346 http://www.redbooks.ibm.com/redbooks/pdfs/sg246346.pdf Security Patterns within a Service-Oriented Architecture http://www.ebizq.net/topics/soa/features/6554.html?&pp=1 Make SOA real with IBM WebSphere Enterprise Service Bus and IBM WebSphere DataPower SOA Appliance http://www.ibm.com/developerworks/webservices/library/ws-soa-real1/ BPEL or ESB: Which should you use? http://www.ibm.com/developerworks/websphere/library/techarticles/0803_fasbinder2 /0803_fasbinder2.html Exploring the Enterprise Service Bus, Part 2: Why the ESB is a fundamental part of SOA http://www.ibm.com/developerworks/library/ar-esbpat2/ Make SOA real with IBM WebSphere Enterprise Service Bus and IBM WebSphere DataPower SOA Appliances series http://www.ibm.com/developerworks/views/webservices/libraryview.jsp?search_by= Make+SOA+real+with+IBM+WebSphere+Enterprise+Service+Bus+and+IBM+WebSphere+ DataPower+SOA+Appliances eWeb Services ArchitectureW3C Working Group Note 11, February 2004 http://www.w3.org/TR/ws-arch/#service_oriented_architecture
145
transformation on the appliance without having to write any XSLT. As in the standalone product, writing transformations is as simple as using the Design Studio graphical user interface to define inputs and outputs and then map between them.
Any-to-any transformation
DataPower is a device very focused on transformation and translations based on open standard technologies such as XML. But there are several scenarios, including heritage and B2B solutions, where XML is not the standard data format. Over time this will change as the landscape evolves and accepts open standard protocols, which are beginning to accelerate. However, even today most B2B integration today is done over non-XML protocols, such as EDI. To address this traditional requirement and others, the XI50 has been augmented with tight integration to WebSphere Transformation Extender (WTX). With WTX, XI50 can parse and transform arbitrary binary, flat text, and other market-based protocols. WTX is a powerful, transaction-oriented, data integration solution that automates the transformation of high-volume, complex transactions without the need for hand coding. This provides enterprises with a quick return on investment. This product supports EDI, XML, SWIFT, HIPAA, and other standards-based B2B integration. It also supports the real-time integration of data from multiple applications, databases, messaging middleware, and communications technologies across the enterprise. WTX, in the context of DataPower: Enables integration developers to visualize and transform complex data without coding. Handles large, semi-structured, hierarchical, and nested data such as EDI documents. Provides a library of ready-to-use, frequently required functions. It supports a wide variety of industry-standard exchange formats featuring financial services and health care. Integrates with IBM WebSphere Enterprise Service Bus offerings, DataPower, WESB, and WMB. Connects with a range of file-based and message-based transport protocols including WebSphere MQ. Runs stand-alone in message and event-driven IT architectures, or embedded with applications and J2EE servers. Runs on the IBM z/OS platform and works as an excellent companion to WebSphere MQ, DataPower, WebSphere Message Broker, and WebSphere Enterprise Service Bus on that platform. Provides a universal transformation engine for SOA. Provides a unified experience with a transformation and mapping IDE for DataPower, WBM, and WESB. It needs to learn only one tool for mapping and transformation. The DataPower xformbin policy action transforms a non-XML document, such as binary or flat text, using processing control files. WTX is composed of several components. Of interest to DataPower are: Design Studio: Design time tool that models and tests data mappings Type Designer: Defines data structures (type trees) Map Designer: Defines and tests data mappings between structures Launcher: runtime Engine that supports multiple deployment environments
146
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
DataPower uses a patented technology called DataGlue that enables the use of externally generated mappings to perform a binary transformation onboard DataPower (Figure 5-12).
Map
Created using visual tool or
FMRFD
Text or XML file Defines message format (A here) Examples: XML Schema XSD, Corba IDL, ASN.1, COBOL copy book, etc.
Derived from existing maps XML file Defines mappings between different messages May include XSLT, XPath
FMRFD
Text or XML file Defines message format (B here) Examples: XML Schema XSD, Corba IDL, ASN.1, COBOL copy book, etc.
DataGlue Engine
Application Message A
DataGlue translator
Application Message B
Creating maps
Once you have defined all of the type trees that you are transforming, it is time to start mapping. WebSphere Transformation Extender Design Studio provides a graphical tool called Map Designer that makes this process simple. First, create a map source file with
Chapter 5. Integration patterns
147
a.mms extension, which is a physical artifact that contains all the mappings that you might perform. Next create an individual map. Map source files can contain many maps, but in this chapter we limit it to one. Each map has input and output cards. WebSphere Transformation Extender allows multiple inputs and outputs, so you can read from various sources and write out to various places within the context of a single map. When creating an input card, the most important setting is the card name. After you define your input and output cards, mapping is as easy as dragging from an input to an output field. To perform more complex functions, WebSphere Transformation Extender provides built-in functions for tasks such as converting your data, performing mathematical operations on it, or manipulating strings. When you have mapped all the output fields, you are ready to build your map and run it, which you do from within the Map Designer tool. For the following items refer to Figure 5-13. The panel on the far left shows the individual fields and any groupings definitions of a type tree. The center panel shows the sequenced structure of a type tree. At the highest level is the RECORD_COUNT and a record. The RECORD_COUNT specifies how many occurrences of record exists. The record can be composed of sub-structures composed of individual fields. Translation rules are also stored. Type trees can be analyzed for logic and structure consistency. Type trees are in MTT files, which are in a binary format. Type tree scripts are in MTS files. An MTS file is a XML-formatted representation of the MTT file, and is the format that DataPower understands.
148
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
For the following items, refer to Figure 5-14. 1. A build of the map must occur before the run is executed. For a DataPower run time, this produces the MTS files (XML-formatted files) needed by DataPower from the MTT files (binary files) used by WTX. 2. To view the results of the test, select Run Results. It then prompts for which input/output cards you actually want to see. In the area near the in and out cards, the selected input and output cards appear. In this case, the input shows the COBOL stream, and the output shows the resulting XML structure.
Build first
In summary, the files needed for input into DataPower and generated by the above steps are: MyMapName.xml: Containing the mappings and created by the build of the map that is used in the binary transform action specification MyInputTypeTree.mts: XML format of the MTT file MyOutputTypeTree.mts
149
DataPower provides an advanced operation to allow for processing of binary transformations. This option, xformbin, is an action (xformbin) in a policy rule (Figure 5-15).
The steps required after the type trees and mappings are defined and the MTS and XML files are generated are: 1. Upload MTS and XML files to the appliance. 2. Configure a document processing policy that uses a binary transform (xformbin) action. In the DataPower run time, the map XML file does the work, with help from the MTS files. 150
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Usage: WTX Design Studio can build type trees by importing XSD, DTD, and COBOL copybooks. So WTX can serve as the de facto mapping tool for DataPower for open standards XML objects as well binary and other non-xml objects such as EDI. This product combination extends DataPowers capabilities in the ESB. Use WTX/DataPower for B2B, B2C scenarios where EDI and other market-based protocols are required, pre-existing WTX libraries manage the inbound proprietary protocols, and DataPower does protocol translation for downstream consumption. This shields the internal enterprise from proprietary data formats.
Scenarios
Refer to the WTX scenario found in IBM WebSphere DataPower SOA Appliances Part I: Overview and Getting Started, REDP-4327. Refer to the WTX scenario found in Getting started with WebSphere Transformation Extender Design Studio on DataPower in developerWorks at: http://www.ibm.com/developerworks/websphere/library/techarticles/0712_vila/0712_vila .html Information about WebSphere Transformation Extender can be obtained from: http://www-306.ibm.com/software/integration/wdatastagetx/library/index.html
151
offers a great deal of flexibility for tuning the optimal interconnection. This section discusses these configuration options in the context of an enterprise architecture. IBM WebSphere MQ performs all network communications over a channel. More specifically, the software program that allows network communication between a MQ client and the MQ queue manager is known as a client channel. The channel is a program that runs on the same host as the MQ queue manager that provides network connectivity, rather than the connection itself. If a client application is local to the queue manager, then a channel is not necessary, but is allowed. Since the DataPower appliance is always remote to the queue manager, communication always takes place over a channel.
Basic MQ architecture
The following illustrations represent the basic architecture created when a DataPower XI50 is used to connect an HTTP-based messaging system (typical of a Web services architecture) to a WebSphere MQ- based messaging bus inside the enterprise. Figure 5-17 on page 153 includes the primary configuration objects created on the DataPower device as well as the configuration of the MQ queue manager to which the DataPower device connects and exchanges messages. In both of these architectures, the DataPower device acts as an MQ client only. It does not act as a queue manager to provide guarantees of message delivery or full rollback capability. The DataPower device does implement some transactionality, as discussed below.
152
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
HTTP to MQ
The Front Side Handler object implements HTTP transport connectivity on the client (front) side of the device. The multi-protocol gateway employs MQ-based URLs to determine the MQ queue to which requests are forwarded, and also from which replies are pulled.
Server Host Queue Channel
HTTP Services Q Mqr Object App
DataPower
Reply Request
MultiProtocol Gateway
Error
Server MQ Queue Manager
Processing Policy
Figure 5-17 HTTP to MQ
Q Mqr Group
In Figure 5-17, HTTP to MQ, messages flow to and from the DataPower device and work is performed by the DataPower device in the following sequence: 1. The HTTP client sends an HTTP-based request (typically an HTTP post containing a SOAP XML document, but may contain binary data) to the DataPower device. A Front Side Protocol Handler listens on an assigned port for incoming requests. 2. The Front Side Handler passes the message to the multi-protocol gateway service object. The MPGW then applies any and all relevant processing policy actions on the message. 3. The multi-protocol gateway may dynamically determine the appropriate destination to which to route the message, or may route all messages statically to a particular destination. In either case, in this architecture, the destination is a particular queue managed by a particular MQ queue manager. The DataPower MQ queue manager object contains the necessary information to establish a connection to the MQ queue manager. 4. The message is placed on the destination queue. If the network connection to a queue manager fails for any reason, the DataPower device can automatically retry the connection (as determined by the automatic retry property of the queue manager object). If the remote queue manager becomes unavailable, the DataPower device can optionally attempt to place the message on an alternate, or failover, remote queue manager, determined by a queue manager group. The DataPower device will automatically retry placing a message on a queue that can be reached once, in response to a 2009 MQ error code. Any further retries must be handled by the error handling configuration of the multi-protocol gateway. If the PUT attempt ultimately fails, an error is returned to the front side of the transaction (HTTP 500 in this case). 5. The DataPower device polls the reply-to queue to find a correlated response message. The gateway examines the correlation ID value in the MQ header of messages on the reply-to queue. When this ID is the same as the message ID assigned to the request, the
153
gateway takes the message as the response. If such a message is found, the multi-protocol gateway may again apply any configured processing policy actions to the response and returns the reply to the requesting HTTP client. This includes error responses from the back-end application server. If no response is found, the MPGW generates an error to the front -client. The multi-protocol gateway can be configured to retrieve and process any message found on the reply-to queue, rather than only the correlated message. This can be done by using the Setvar processing action, or by using the set-variable() extension function. Using either method, set the extension header variable X-MQMD-Get to a blank or null value. The multi-protocol gateway can be configured to ignore any response, including no response, by setting the gateway's response type property to pass-thru. In this case, the gateway will continue to poll the designated reply-to queue for a correlated response message. If one is found, it is returned without change to the front-side client. If none is found, nothing is returned to the front side by default. The gateway does not treat the lack of a response message on the reply-to queue as an error. The URL used to open the connection to the back-end request queue can omit designating a reply-to queue. In this case, the multi-protocol gateway will not wait for a correlated response message, terminating the transaction. No response is sent to the front side HTTP client.
MQ to HTTP
Conversely, Figure 5-18 is an illustration of the basic architecture created with a DataPower XI50 that is used to extend a WebSphere MQ-based messaging system out to a Web services architecture.
Server Host Queue Channel Reply
Front HTTP
Request Error
Server MQ Queue Manager Side Handler
DataPower
MultiProtocol Gateway App Server
Q Mqr Object
Processing Policy
Q Mqr Group
Here, the Front Side Handler polls a particular MQ queue for request messages, and places replies from the back-end services on another MQ queue. The front-side queue manager object may optionally place messages in an error queue on the MQ queue manager. A standard HTTP URL is used to determine the destination to which requests are forwarded, and from which answers are received in accordance with the HTTP specification.
154
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Messages flow to and from the DataPower device and work is performed by the DataPower device in the following sequence: 1. An MQ Front Side Protocol Handler polls the configured request queue, managed by the referenced MQ queue manager, for incoming requests. All messages found on the queue are copied from the queue. To implement redundancy, the multi-protocol gateway can be configured to use more than one Front Side Protocol Handler polling a range of queues. It is then up to the MQ system, independent of the DataPower device, to route messages to an active queue. By default, all request messages are immediately removed from the request queue. The device can be configured to leave the request message on the request queue until processing by the gateway is complete with no errors by setting the units of work property of the MQ queue manager object in use by the Front Side Protocol Handler to 1. 2. The Front Side Handler passes the message to the multi-protocol gateway service object. The MPGW then applies any and all relevant processing policy actions on the message. The multi-protocol gateway may dynamically determine the appropriate destination to which to route the message, or may route all messages statically to a particular destination. In this scenario, the back end employs HTTP. The gateway opens an HTTP connection and typically posts the request. 3. The multi-protocol gateway gets the response from the back-end application server. In this scenario, the HTTP protocol requires a positive response (which may contain an error message) or the gateway will register an error. The gateway applies any applicable processing policy actions to the response. Any errors will terminate the transaction. If the response type property of the gateway is set to pass-thru, no processing is performed on the response. The response message, if any, is returned unchanged to the front-side response queue. 4. The response message may be placed on the reply-to queue specified in the Front Side Protocol Handler. Unlike HTTP, the MQ protocol does not require a response. If the gateway response type has been set to pass-thru and the gateway has encountered an error, then no message is placed on the reply-to queue. If the queue manager units of work has been set to 1, the transaction is marked complete and the message is removed from the request queue even if an error has occurred. The gateway can also remove a message that results in an error and place the offending error on an alternate queue available through the same MQ queue manager. To enable this behavior, set the units of work to 1 and automatic backout to on in the MQ queue manager object. You may then set the number of times the messages will be reprocessed, and designate an alternate queue for placement.
Transactionality
In general, a transaction is a sequence of operations that either commit or roll back their work. A transaction rolls back if any one of the operations in the transaction fails. A transaction commits if all the operations in the transaction succeed. The MQ protocol includes the concept of transactionalitythat is, the ability to remove messages from a queue only when the agent that removed the message has successfully processed the message. This concept also includes the ability to roll back transactions, much like a database system. The MQ system implements transactionality in part through the use of units of work. The terms transaction and unit of work are interchangeable. Resource managers such as WebSphere MQ queue manager can participate in a global unit of work, which involves the processing of resources from multiple resource managers. A transaction manager is required to coordinate such a transaction. It uses the two-phase
155
commit protocol, a prepare and commit phase. The prepare phase ensures that all resources marked for commitment can be recoverable. The commit phase sends a request to all resource managers to commit their work. The MQ system allows either: Local units of work between an MQ client and an MQ queue manager. A local unit of work is when only the queue manager resources are being updated. Global units of work, which may involve a series of clients and managers. A global unit of work is when resources of other resource managers are also being updated. The DataPower device does not participate in globally managed transactions and cannot communicate with a transaction manager. The DataPower device can only participate in local units of work. Furthermore, a unit of work can apply only to one message. Therefore, by default, the DataPower device does not enforce transactionality. Rather, messages are put on queues with no expectation of a response. Messages are removed from queues immediately, without regard to success of processing. However, with MQ augmenting an ESB infrastructure, it can partner with DataPower by assuming the transactionality responsibilities by correctly setting the units of work property of the MQ queue manager object. The DataPower device can provide message accountability and guarantee that messages are not lost between DataPower and MQ. This architecture thus allows for DataPower to inherit the global transactionality that MQ is participating in at the time. In the event of failure during a unit of work, or if the application determines that it cannot complete the unit of work for any reason, changes to resources that have already been made are backed out, or rolled back. If DataPower does not participate in the global unit of work, then how do we fail back through DataPower? A good design pattern is to let the MQ queue manager inject a message back to DataPower representing the failed event. DataPower itself does not need to know the intent as long as there is a correlation ID correctly set. DataPower can therefore return the response to the client and the client will manage the rollback message. Because DataPower is loosely connected in the flow, it readily participates as a first class citizen in long-running transactions that have XA global signatures. To further enhance the quality of service with either local or global transactionality, you can have DataPower interact with the MQ infrastructure in a particular way. The best design for DataPower/MQ interaction is to have DataPower communicate with one and only one MQ queue manager for any particular message flow. The reason for this is that DataPower uses the correlation identifier (CorrelID) as the correlation key for any request response scenarios. This identifier is unique to that particular queue manager.
156
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
It is important to understand that DataPower will propagate a transaction between two different WebSphere MQ queues managers. But to maintain integrity with request and reply messages between DataPower and WebSphere MQ, a handshake with a single queue manager is required because of the correlation identifier aspect. Thus, in Figure 5-19 the following two scenarios are accurate, but the bus scenario is preferred. This is necessary for request and reply correlation, particularly with transactional or guaranteed messaging requirements.
In Line Scenario
Bus Scenario
PUT GET PUT
GET PUT
Back-side processing
When the destination URL used by a gateway includes Sync=true, then the MPGW will commit the message to the request queue only when the entire message has been successfully put to the queue, thus making it available for other programs, such as the back-end application, to get the message. The multi-protocol gateway can be configured to retrieve and process any message found on the reply-to queue, rather than only the correlated message. This can be done by using the Setvar processing action, or by using the set-variable() extension function. Using either method, set the extension header variable X-MQMD-Get to a blank, or null, value. For example: setvar INPUT 'var://context/INPUT/_extension/header/X-MQMD-Get' '<MQMD/>'
157
may then set the number of times that the messages will be reprocessed and designate an alternate queue for placement.
Routing
A multi-protocol gateway can route messages to and from MQ queues, just as messages are routed to and from HTTP destinations using the same basic mechanisms. The gateway may use a static back end or dynamically determine a route.
Routing inputs
A multi-protocol gateway can examine the following inputs to help determine the desired message routing: Message content: The gateway can dynamically determine the destination queue by employing an Xpath routing map to examine the content of the message, or by using a custom stylesheet. Protocol header: The gateway can dynamically determine the destination queue by examining the value of the MQ protocol headers. As of firmware version 3.6.0.0, these values are easily obtained using a processing metadata object. A processing metadata object returns an XML nodeset containing the selected headers and values.
Routing destinations
The gateway can route all messages to the static back-end URL determined by the gateway configuration. The gateway may also determine the back-end destination dynamically. If the gateway uses dynamic determinations, then the gateway processing policy must set a back-end target at some point, using either the set-target() or xset-target() DataPower Extension Function calls. Messages may also be sent or routed to one or more alternative destinations using the route (or route async) processing actions, just as with HTTP messages. For example, a single request message may contain a number of attachments. These attachments may be separated from the original request and routed individually to a particular destination (that may or may not be an MQ queue). The processing policy of the gateway may collect the responses and construct a reply message, may ignore the responses, or may send a response message that does nothing more than acknowledge receipt of the original request. All destination determinations can employ an MQ URL to express the destination.
Error handling
A multi-protocol gateway can employ all of the standard error-handling capabilities available for HTTP traffic. This includes processing policy error rules, the on-error action, automatic fault generation when a request or response message does not pass validation checks, and custom error message generation. The MQ protocol allows requests that have no response. The gateway may be configured to return no response message when an error is encountered during processing. As mentioned above, the Gateway response type must be set to pass-thru to implement no response. The device provides a number of MQ-specific event (error) codes that can be read and used for error processing.
MQ and JMS
It is possible to transport JMS messages over an MQ system. In such a case, some architectures allow for the selection of MQ messages based on values contained in the JMS message headers. As of Version 3.6.0.0, the DataPower device does not natively recognize the JMS headers as header values in the MQ message. The DataPower device cannot select and GET messages based on JMS header values.
159
It is possible to use the DataPower device to read and select messages based on JMS header values by using a binary transform operation on the MQ message body to extract the JMS header values into an XML nodeset. This extracted nodeset can then be examined for the desired attributes.
Traditional MQ objects
The device includes a number of MQ-related services that predate the multi-protocol gateway. These are the MQ gateway, the MQ host, and the MQ proxy. These objects should no longer be used for MQ interoperability. The multi-protocol gateway (or, alternately, a Web services proxy) provides all of the functionality offered by these services, in addition to many new features and capabilities. The device provides a number of traditional system variables containing information that might be useful for routing messages. An example is: var://service/correlation-identifier R/W examines or sets the value contained in the MQMD (Message Descriptor) Correlation Identifier header, used for MQ host and proxy services. These variables are not available to the multi-protocol gateway or Web services proxy and should not be used.
Resources
For further information see: WebSphere DataPower WebSphere MQ Interoperability Release 3.6.0.0, developerWorks http://www-1.ibm.com/support/docview.wss?uid=swg21255199 Integrating WebSphere DataPower SOA Appliances with WebSphere MQ, developerWorks http://www.ibm.com/developerworks/websphere/library/techarticles/0703_crocker/0 703_crocker.html?S_TACT=105AGX78&S_CMP=ART WebSphere MQ product home http://www.ibm.com/software/integration/wmq/ IBM WebSphere MQ V6 Fundamentals Redbooks publication http://www.redbooks.ibm.com/abstracts/sg247128.html
160
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
The adapter usually resides outside the infrastructure component that hosts the application component that is to be service enabled. Adapters have been employed in the past to provide integration with middleware such as Web application servers.
161
Transition approaches
Select the appropriate transition approach depending on the level of service integration and SOA standardization that already exists, and the level that is to be achieved. There are three transition approaches available: Improve: Focuses on service-enabling the assets that already exist. Service enablement means that assets get a new type of interface that opens them up for service consumers. This approach should not require any recoding or redevelopment of applications. Adapt: Focuses on service integration. The vehicle to achieve flexible service integration is the ESB. Innovate: Results in a restructured, rewritten application that natively conforms to SOA-compliant standards and protocols using an ESB. An innovated application is fully modularized so it can be reused more easily in the future, and should have a service interface. Focuses on SOA enablement of existing assets, without writing any new code, and does not discuss the innovate approach.
162
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Solution techniques
The technique that you use in your solution should include technologies and products that help the solution meet the required level of service integration. Figure 5-24 shows the relationship between service interface patterns and transition approaches.
163
This section discusses the IBM DataPower appliance approach only. However, before choosing a solution technique, do a thorough requirements analysis. Some questions to consider are: What is the scope of the solution? Is it a one-time solution, or will it be deployed enterprise wide? How long is the solution expected to live? Is it a temporary tactic solution, or a long-term strategic choice? Does the solution need to interoperate with an ESB? How about a service registry? What is the knowledge level or maturity of the developers? Are there development standards in place for building services in an SOA? What are the nonfunctional requirements? What are the volumes? Response time? Security? Transactions? Do the services need to be part of a distributed unit of work (UoW)? Systems management? Requirements on tools and routines for monitoring the solution?
164
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Summary
In this section we explored scenarios for service-enabling CICS and IMS applications using DataPower. You learned important aspects to consider for service-enabling traditional applications, including determining the ambition level and whether the traditional code can be reused and exposed as a service using a native service interface, adapter, or a broker, or whether it needs to be completely redeveloped.
165
You discovered how IBM WebSphere DataPower Integration Appliance can help you service-enable your applications. In cases where back-end (MQ-enabled) mainframe applications are to be Web-service-enabled, the DataPower Integration Appliance enables you to: Keep all Web services standards, security, and definitions in one place. Avoid traditional programming because message transformations are done using schemas and configurations. Perform high-speed transformations, offloading XML handling from the mainframe. Have a non-intrusive solution that plugs easily into the existing architecture.
Resources
For further information see: Service-enable CICS and IMS traditional applications using the IBM WebSphere DataPower SOA Appliance http://www.ibm.com/developerworks/library/ar-datapow/ SOA Transition Scenarios for the IBM z/OS Platform, SG24-7331 http://www.redbooks.ibm.com/abstracts/sg247331.html?Open Integrating WebSphere DataPower SOA Appliances with WebSphere MQ http://www.ibm.com/developerworks/websphere/library/techarticles/0703_crocker/0 703_crocker.html?S_TACT=105AGX78&S_CMP=ART
166
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
incoming requests. WMB transforms the incoming request and sends it to CICS for customer information. CICS processes the request and sends the data back to WMB. WMB transforms the data, builds the reply message, and sends it to DataPower via WebSphere MQ, which in turn sends it to the original requester.
Resources
For further information see the following resources: IBM WebSphere DataPower SOA Appliances Part III: XML Security Guide, REDP-4365 Integrating DataPower with WebSphere Message Broker using the Broker Explorer http://www.ibm.com/developerworks/websphere/library/techarticles/0707_storey/07 07_storey.html
167
While the underlying technology that supports Web 2.0-enabled sites has not changed, the way in which the Internet is used has. The Internet is no longer a one-way street where content is delivered to the users browser for consumption. Web 2.0 technology allows users to easily submit their own content for others to see or use a Web-based application as though it were part of their own desktop.
168
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
The Web service responds with a list of customers, including their names and IDs. A sample response is shown in Example 5-3.
Example 5-3 Sample Web Service response <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:dp="http://www.datapower.com/schemas/management"> <soapenv:Body> <CustomerList xmlns="http://sample10.datapower.ibm.com/crafted/"> <Customer xmlns=""> <CustomerID>0</CustomerID> <CustomerName>customer0</CustomerName> </Customer> </Customer> </CustomerList> </soapenv:Body> </soapenv:Envelope>
Atom Feed
As described in Web 2.0 technologies on page 168, Atom feeds are XML based. An Atom document is shown in Example 5-4.
Example 5-4 Sample Atom document <?xml version="1.0" encoding="utf-8"?> <feed xmlns="http://www.w3.org/2005/Atom"> <id>[email protected]</id> <title>This is an example feed</title> <link href="http://my.test.feed.org/feed/" rel="self"/> <link href="http://my.test.feed.org/"/> <updated>2007-10-05T18:30:02Z</updated> <author> <name>John Doe</name> <email>[email protected]</email> </author> <entry> <title>DataPower Test Atom Feed</title> <updated>2007-10-04T18:30:02Z</updated> <summary>This is a test of the DataPower ATOM feed.</summary> </entry> </feed>
The feed element describes the title, ID, and update time stamp of the feed, as well as other metadata such as the authors name and relevant Internet links. The entry elements define the actual informational content of the feed. Every feed and entry element must contain a title, ID, and time stamp element. To represent the Web service as an Atom feed, the list of customers returned by the Web service needs to be transformed into individual Atom entries.
169
XSL transformations
The previous section briefly described the format of the Atom Syndication Format. To display the SOAP responses from the SampleRead Web service in this format, some XSL transformations must be performed by DataPower. This involves the following: Transforming the empty GET request from the Atom client to a SOAP request to the Web service Converting the list of customers returned by the Web service to Atom entry elements Adding metadata that describes the feed and its entries These operations are performed using two XSLT stylesheets. The first generates a SOAP request and sends it to the SampleRead Web service. The response from the Web service is passed to the second stylesheet for processing. This stylesheet extracts the customer elements of the CustomerList element and converts them to Atom Syndication Format entry elements. It also inserts the required Atom metadata elements ID, title, and time stamp for both the entry elements and the root feed element.
DataPower configuration
This section describes the steps to configure the DataPower appliance to enable the SampleRead Web service as an Atom feed. Two XML firewalls are created to support the SampleRead Web service as a Atom feed. The architecture is shown in Figure 5-28.
The first firewall receives the request from the feed reader and forwards the request unchanged to a second loopback firewall. The second (loopback) firewall has a processing policy that consists of two XSL transforms. The first of these transforms generates a SOAP request to the SampleRead Web service to obtain the list of customers. The second transform processes the Web services response, and translates it into the Atom format. The translated output then becomes the response input of the first firewall. The first firewalls response processing policy adds the Atom Content-Type. Note that the reason that two
170
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
firewalls are needed is because it is not possible to set response headers in a loopback firewall.
171
8. In the main XML firewall panel (also shown when entered through the control panel/XML firewall) we select the newly created firewall. First we have to change the request type on the bottom right-hand side of the panel from SOAP to Non-XML. This is because the initial request from the feed reader is not in an XML format. 9. Select the ellipsis button (...) beside the atom firewall policy to customize it. 10.Drag and drop a Transform action onto the processing rule diagram.
172
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
11.Double-click the new Transform action icon to configure this action. We have to upload the genRequest XSLT file we want to use. This is the XSLT that sends an out of band SOAP request to a Web service and receives a SOAP response with the requested list of items.
12.Click Done on the Configure Transform Action panel. 13.On the policy diagram insert another Transform action after (that is, to the right of) the existing Transform action.
173
14.Double-click the newly created Transform action and configure it to use the atomResponseMapper.xsl file. This stylesheet performs the transformation of the SOAP response from the previous step to the Atom format.
Figure 5-33 The final rule for the atom XML firewall
15.Apply the changes to this rule and close the policy editing window. 16.Click Apply and Save Config to save the changes.
174
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
4. Commit the configuration of this firewall on the next panel (Figure 5-35).
5. Select the newly created atom-mime XML firewall from the Configure XML Firewall page (Figure 5-36).
6. We set the request type and response type to Non XML. 7. Select the ellipsis button beside the atom-mime firewall policy to customize it. 8. Create a new rule action and make it a Server to Client (Response Rule). 9. Drag and drop an Advanced action onto the processing rule diagram. Double-click it and select the setvar (set variable) option.
175
12.Double-click the matching rule icon (=) to open the configuration window.
176
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
13.Select the ellipsis beside the atom-mime matching rule. On the Rules tab change the URL matching type to match only /feed* URLs. Save the changes. See Figure 5-39.
14.Apply the changes to the processing policy and close the policy editing window. 15.On the main configuration panel, select the tab Advanced and set Disallow GET (and HEAD) to ON. That is, we want to allow GET requests for this firewall. 16.Click Apply and Save Config to commit the changes to the atom-mime XML firewall.
5.3.3 Demonstration
By turning on the probe for the firewalls, we can view the data as it traverses the appliance. To test out the configuration, we direct a feed reader to the client-facing XML firewall called atom-mime. This firewall has the port number 3001, so the URL that the feed reader should use is http://<datapower host name>:3001/feed. Requests sent to this firewall are sent unchanged to the atom XML firewall. Viewing the probe for the atom firewall, we can see that the first transform action sends a SOAP request to the Web service. The SOAP response is then translated by the second transform into the Atom format, as shown in Example 5-5.
Example 5-5 Translated SOAP response <atom:feed xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:date="http://exslt.org/dates-and-times" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:dp="http://www.datapower.com/schemas/management"> <atom:id>atom.sample.com</atom:id> <atom:title>feed demo: List of Customers</atom:title> <atom:updated>2007-11-14T22:56:58+11:00</atom:updated> <atom:entry> <atom:id>0</atom:id> <atom:title>customer0</atom:title> <atom:updated>2007-11-14T22:56:58+11:00</atom:updated> <atom:content> <Customer xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <CustomerID>0</CustomerID> <CustomerName>customer0</CustomerName> </Customer>< /atom:content> </atom:entry> </atom:feed>
177
The Atom content is then returned to the atom-mime firewall, where the response-processing rule is invoked. Viewing the response probe for the atom-mime firewall, we can see that the Content-Type header has been updated by the set variable action from application/text+xml to application/atom+xml.
5.3.4 Summary
This section demonstrated how the DataPower appliances can be used to enable existing applications to support Web 2.0.technologies. Web 2.0 entities such as blogs, wikis, and social networking are becoming increasingly popular as a means for both individuals and companies to interact with one another. Using a simple XSL transformation, we have shown how SOAP-enabled Web services can provide content in the Atom Syndication Format. This format is widely used to provide syndicated news and other informational content to users. The XSL transformation performed by the DataPower appliance converted the Web services SOAP-based response into the Atom format by adding the necessary Atom metadata around the Web service response.
178
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Summary of ESB requirements presented to IBM is presented below: Request routing and workload management: Multiple copies of individual services were deployed within the infrastructure to facilitate reliability, serviceability, and availability. The ESB should route client requests to appropriate versions and instances of requested services. The ESB should also make some provisions for workload management, distributing requests to identical service instances. This could be a simple load distribution algorithm, but there was strong interest in more active, endpoint-driven load workload management. Registry integration: ABC employed a UDDI-based service registry for a build-time catalog of services. There was no provision for a more active runtime service registry, but the requirement to support such a registry was understood. Mediation: ABC expected the ESB to mediate between clients and services. Service data is expressed in WSDL/XML, so there was no need to handle more esoteric data formats. Message validation (WS-I and XSD) as well as support for performance/transformation acceleration were key drivers. Transaction management: ABC had certain use cases that would require compensation and rollback of committed service requests (distributed transaction support in composite services). They desired support for rule-based, atomic, and process-driven transactions. Service choreography and workflow: Complex workflow support was a requirement for a small subset of service interactions. BPEL support was highly desirable for these cases. Support for business state machines, scheduling and timing of interactions, event correlation, and workflow involving human interaction was also preferred. Ability to facilitate integration with back-end systems: The ability to integrate directly with Siebel and other back-end systems was a consideration. High performance/low latency: The ESB should have a minimal negative impact on overall performance and latency. Monitoring, managing, maintaining: Collectively, there were broad requirements for service level monitoring, collecting standard and custom metrics, fault detection, root cause analysis, reporting, and historical analysis. Automated operator alert and notification facilities were critical. Security: Integration with Tivoli Access Manager, LDAP, and other third-party security products was a requirement. Credential and key management capability, standards-based authentication, access-control, encryption/decryption, SSL acceleration, Sarbanes-Oxley (SOX) controls, and suitability for DMZ deployment were all considerations. SDLC: ABC uses Eclipse-based Rational Application Developer and Rational Software Architect. ESB development tools that fit well within their existing environment were preferred. Fast deployment: ABC had already invested considerably before choosing to refactor to include an ESB. Cost and speed of deployment were critical considerations. Reduced operational complexity: Reduction of risk and complexity was what drove ABC to refactor to an ESB-based architecture. ABC had a strong preference for a turnkey, low-complexity solution.
179
180
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Hotel Client
Hotel Client
Business Partner
XI50
XI50
Seibel
Untrusted
DMZ Trusted
DMZ
WSRR
The DataPower XI50 fulfills two roles in this architecture: Service gateway (in the DMZ) and general hardware ESB (in the trusted zone). Tasks that require a software ESB implementation (such as using a Siebel Adapter or complex error recovery with human interaction) are off-loaded to WebSphere Process Server includes as a core component WebSphere ESB. DataPower fulfills the majority of ESB traffic requests at ABC, enabling very high performance. WebSphere Process Server and WebSphere ESB augment DataPower to allow maximum flexibility in the architecture. IBM Tivoli Composite Application Management products enable monitoring and management of the ESB and components that interact with it. Information collected by monitoring agents can enable complex ESB enrichment and routing patterns, such as dynamic service selection (selecting a target service based on information collected by monitoring agents, such as hosting server load). WebSphere Service Registry and Repository enables full life-cycle governance of services and plays a role in enabling dynamic service selection in the ESB. As noted above, UDDI alone is inadequate for these tasks. This architecture is intended to strike a balance between performance and flexibility.
181
WebSphere MQ provides much of the intra-application and inter-application messaging backbone. There is a main data center connected to several satellite data centers and to third-party systems. XYZ decided to use a service-oriented architecture to build a new call center environment (CCE) and to build a new claims processing application (CPA). Many other applications and changes took place, but we focus on these two major systems. The overall project requirements that IBM and XYZ used to define the architecture included: Leverage traditional applications without requiring re-write of code. Leverage mainframe systems while creating new services on the platform of choice for that application. Support multiple communications protocols (SOAP/HTTM, WebSphere MQ, and so on). Securely support SOA interactions with outside organizations. Operate in an environment with several data centers, geographically dispersed. Provide the ability for real-time monitoring and routing of transactions based upon desired level of service. The ESB requirements are similar to the ABC case study, except that more complex mediations are required. Also, due to many regulations, security and auditability must be more robust than in the ABC case study.
182
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Hotel Client
Hotel Client
Message Broker / MQ
z/OS
Business Partner
XI50
XI50
Tivoli Monitoring Member Process Server / WESB Data Fabric Claims Provider
Untrusted
DMZ Trusted
WSRR
As in the ABC example, the DataPower XI50 plays two roles: Security firewall in the DMZ Hardware ESB in the trusted zone WebSphere Process Server/ESB is used to choreograph complex service interactions, taking data from the data fabric and combining it into more complex business service replies. WebSphere Message Broker is used to handling complex message transformation needed to interact with traditional systems. This example shows the value of using all three IBM ESB solutions in one design, as each is leveraged to take advantage of its most significant capabilities. IBM realizes that many organizations have similar complex needs to XYZ. These requirements will drive the use of several technologies in order to provide the most appropriate capabilities and meet availability, performance, and security requirements.
DMZ
183
in order to facilitate the production support process by providing visibility into complex integration points. In evaluating this situation, the IBM team determined that there were several crucial elements that they had to meet in order to make the company successful. First, they had to provide a unified security infrastructure so that the interactions with their business partners would secure private customer information as well as analytic information about the campaign that was proprietary to the company. Second, they needed to be able to assess the success of the campaign and the ability of their business partners to support the campaign. Also, they needed to be able to quickly identify and fix problems as they occurred. This meant that the company would need a unified logging and usage analysis solution. Finally, they needed to be able to view the information about use statistics and performance in a common dashboard to get a view of the current status of the campaign at a glance.
Detailed description
The company has made an architectural decision that WS-Security is to be a critical part of the enterprise security strategy. They see the need for digital signatures, message-level encryption, and exchange of identity credentials in a standard way to be important in meeting the needs for customer privacy and protection of their own proprietary data. All new internal services will be deployed with WS-Security, and all new internal clients will be WS-Security enabled also. They would like to enforce the WS-Security basic profile as a common standard for all business partners as well. However, not all of their business partners are yet able to fully take advantage of WS-Security. Existing services have often been deployed using channel-level encryption via HTTPs and using identity token exchange through HTTP BASIC-AUTH. Likewise, not all of their internal client programs have been brought up to speed on the newly adopted standards, either. Therefore, one need that the company has is to be able to bridge between channel-level encryption and credential exchange mechanisms and WS-Security. Figure 5-42 shows the architectural needs that this client has and how they will be implemented in their infrastructure.
logs
HTTP
HTTP
DMZ
184
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
185
We examine the first in detail, and the other two are derivative of the first case. We begin by examining the firewall processing policy definition for the first case, shown in Figure 5-43.
The highlighted rule (the rule for processing requests) has five steps, or actions: Action 1 is the match action. This allows the integration engineer to define the cases under which this processing policy will match requests that enter the XML firewall. The default case (which we have taken) is to match all URLs that arrive at this port. This allows this XML firewall to act as a proxy for multiple services represented by different URLs. Action 2 is the authenticate, authorize, and audit (AAA) rule. It is used by DataPower to handle cases where authentication, authorization, or credential mapping is needed. In our case, this action is set up to pull the user credentials off of the HTTP BASIC-AUTH headers, authenticate them against LDAP, and then map the credentials into a WS-Security UserName token for use by the server. Action 3 is the log action. It takes the current context (the message received) and logs it to a predefined destination. There are a number of different choices for log destinations, including common destinations like a UNIX syslogd, but also supporting destinations like the common event infrastructure. Action 4 is the encryption action. It can encrypt all or part of the message using basic XML Encryption or (as in our case) WS-Security encryption. Action 5 is the return action, which allows the processing policy to return the newly changed message to its destination. On the response side, there are only three actions: A match rule A decryption action (which decrypts the response message) A return rule to return the now decrypted response to the sending service requestor
186
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Detailed description
This brokerage firm has recently adopted Web services as a middleware standard for internal server-to-server communications, replacing an internally developed set of protocols. However, the adoption of Web services standards is proceeding slowly, and some aspects of the traditional architecture remain in the current architecture. In particular, this firm has the following problem. They have a set of services implemented on the mainframe as HTTP Web services. In order to take maximum advantage of their current hardware setup, they are split across multiple CICS regions. Thus, each Web service has been deployed on more than one CICS region. This means that, to take full advantage of the available hardware, requests to each Web service should be load balanced across the various regions. However, there are additional considerations. Due to the way that these services have been implemented internally, there is a need for client affinity to particular CICS regions hosting the services. Complicating this is that the set of regions is somewhat dynamic. It changes occasionally as additional regions are brought online in response to increasing demand. So, when a new client request in a session begins, the client is assigned to one of the existing regions in order to provide load balancing. But all requests from that client should then be directed to the same CICS region in order to allow that region to maximize its performance through caching of expensive configuration data. Likewise, there are additional complications in the routing of messages to these regions. The algorithm dictates these steps: 1. Look in the routing header on the SOAP message to determine whether the destination has already been determined (True if this is not the first message from this client). 2. Look at the system context. If the system is currently in alarm mode, then turn back certain messages of low priority. 3. Otherwise, either generate a destination for a new client, or route the message to the previously determined destination. The architectural elements of this problem are shown in Figure 5-44.
ESB Gateway
HTTP or MQ
HTTP or MQ
WS-I WS-I compliant WS-I compliant services compliant services on CICS services on CICS regions on CICS regions regions
187
188
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Another transformation (earlier in the flow) can determine whether the destination header is set (for example, whether it is the first time that we have received a request). If not, then it can pick a destination and add the new header to the context.
5.4.5 Resources
For further information see Enterprise Service Bus implementation patterns at: http://www.ibm.com/developerworks/websphere/library/techarticles/0712_grund/0712_ grund.html
189
190
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Chapter 6.
Configuration management
This chapter discusses several methods for managing the configuration of DataPower devices. We can leverage the way the system itself works to make it self-configuring. This allows for rapid swapping of boxes within a production environment, should the need arise. Topics include: DataPower File system directories and domains Devices, environments, and load balancers Configuration using the WebGUI, the command-line interface, and the XML Management Interface Package importing and exporting Using a repository Using IBM Tivoli Composite Application Manager System Edition (ITCAM SE), also known as ITCAM Systems Edition for DataPower
191
6.1 Introduction
Each DataPower device contains a configuration. The device is configured using objects that are hierarchically organized into services. It is the services that expose ports for the consumption of traffic over supporting protocols such as HTTP, FTP, MQ, JMS, and NFS. Services implement functionality such as authentication and authorization of Web services, acceleration of XSLT Transformations, and enterprise service bus protocol mediation.
192
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Each DataPower device may participate as a member of a peer group that provides services and shares management information with other members for the group. For the purpose of this document, a shared environment of devices refers to the group of devices servicing software life-cycle areas such as test, development, or production. Migrating configuration information to an environment refers to the entire group of devices. It is often the case that groups of devices, perhaps an entire environment, will reside behind a Load Balancer that acts as a faade exposing a single virtual IP address for request traffic. Common routing algorithms such as round robin and least frequently used are available. This topology has no effect on the configuration of the device. There will be no device affinity, as each transaction should be able to be processed by any of the devices in the load-balanced group. Service level data is shared by devices through peer group registration, and all transactions participate in service level monitoring. DataPower devices may also be deployed in an active/active or active/standby configuration whereby a virtual IP address is used to control multiple devices. In this configuration the standby device monitors the health of the active device, and assumes its IP address in the event that it becomes unavailable. In an active/active configuration, multiple standby configurations are employed. Each device acts as the standby for the other, and assumes its traffic in the event of failure, without the need to maintain one box offline.
193
rule simpleFirewall_Rule_0 action simpleFirewall_Rule_0_Action_0 exit matching matchAll urlmatch /* exit stylepolicy simpleFirewall match matchAll simpleFirewall_Rule_0 exit xmlfirewall simpleFirewall local-address 0.0.0.0 2092 summary an example XML Firewall Service query-param-namespace http://www.datapower.com/param/query remote-address 127.0.0.1 1001 stylesheet-policy simpleFirewall response-type unprocessed exit
194
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
provides an opportunity to discard changes. See the WebGUI Guide for your device for a complete description.
ssh DataPowerIP<<EOF admin passw0rd config copy -f https://HTTPServerIP/HRServiceExport.zip temporary:///Demo/HRServiceExport.zip passw0rd import-package HRServiceImport auto-execute off destination-domain Demo source-url temporary:HRServiceExport.zip exit import-execute HRServiceImport no import-package HRServiceImport write mem y exit exit EOF
Tasks executed in Web GUI require the user to remember what they performed, especially when they need to undo actions. Administrators can create an undo script to ensure that changes are undone. Many options exist for migrating changes from development to production. For example, using the Web GUI, administrators can create the domain configuration and store it on a Web server. The domain on the appliance can reference this configuration on startup. Another
195
option for importing shared objects into a domain is to use packages. The package contains the set of shared objects used by several domains. These methods can be used to migrate changes from development to production, but may not be preferred since they cannot be audited and the consistency in the files cannot be guaranteed.
<?xml version=1.0 encoding=UTF-8?> <env:Envelope xmlns:env=http://schemas.xmlsoap.org/soap/envelope/> <env:Body> <dp:request domain=testDomain xmlns:dp=http://www.datapower.com/schemas/management> <dp:set-config> <Matching name=matchAny xmlns:dp=http://www.datapower.com/schemas/management xmlns:env=http://www.w3.org/2003/05/soap-envelope> <MatchRules> <Type>url</Type>
1
http://www.redbooks.ibm.com/abstracts/redp4446.html?Open
196
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
<Url>.*</Url> </MatchRules> </Matching> </dp:set-config> </dp:request> </env:Body> </env:Envelope> WebSphere DataPower SOA Appliances contain a powerful management framework that is accessible through XML messages sent over HTTPs. These messages can be chained and scripted in order to perform automated configuration management and operations on the device. In order to perform configuration management through the XML Management Interface, the interface must first be enabled through the CLI or WebGUI. After this is done, the XML commands can be sent to the specified host/port/URL. In the following two examples, we perform a substitution on the file to create a new domain with its own user and group defined.
Example 6-4 Initial XML file
<?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"> <env:Body> <dp:request xmlns:dp="http://www.datapower.com/schemas/management"> <dp:set-config> <Domain name="%domainName%"> <UserSummary>%domainDesc%</UserSummary> <NeighborDomain class="Domain">%domainNeighbor%</NeighborDomain> </Domain> <UserGroup name="%groupName%"> <UserSummary>%groupDesc%</UserSummary> %groupPolicies% </UserGroup> <User name="%userName%"> <Password>%userPass%</Password> <GroupName>%groupName%</GroupName> <AccessLevel>%userAccess%</AccessLevel> <UserSummary>%userDesc%</UserSummary> </User> </dp:set-config> </dp:request> </env:Body> </env:Envelope> Example 6-5 is a shell script that can make the substitutions.
Example 6-5 IShell script file
#s!/bin/ksh domainName=${1:-testDomain} domainDesc=${2:-testDomain for applications} domainNeighbor=${3:-default} userName=${4:-testUser} userPass=${5:-passw0rd} userDesc=${6:-test user for this domain} 197
userAccess=${7:-group-defined} groupName=${8:-testGroup} groupDesc=${9:-testGroup for application domain} groupPolicy01=${10:-*/$domainNeighbour/*?Access=r} groupPolicy02=${11:-*/$domainName/*?Access=r+w+a+d+x} groupPolicies= <AccessPolicies>$groupPolicy01</AccessPolicies> <AccessPolicies>$groupPolicy02</AccessPolicies> sed -e s/%domainName%/$domainName/ \ -e s/%domainDesc%/$domainDesc/ \ -e s/%domainNeighbor%/$domainNeighbor/ \ -e s/%userName%/$userName/ \ -e s/%userName%/$userName/ \ -e s/%userDesc%/$userDesc/ \ -e s/%userAccess%/$userAccess/ \ -e s/%groupName%/$groupName/ \ -e s/%groupPolicies%/$grouppolicies/ \ -e s/%groupDesc%/$groupDesc/ sampleTemplate.xml > domain.xml This newly created file (domain.xml) can then be sent to the XML Management Interface using the curl utility: curl --data-binary @domain.xml https://<IP>:5550/service/mgmt/current -u admin:<pass> -k Where <IP> is the address of your DataPower device and <pass> is your admin password for this device.
198
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
configure terminal # This is the fixed component of the 'Default' Domain for DataPower device 192.168.0.52 interface "eth0" ip address 192.168.1.50/24 arp mtu 1500 ip default-gateway 192.168.0.1 mode 1000baseTx-FD exit interface "eth1" ip address 192.168.1.51/24 mtu 1500 ip default-gateway 192.168.0.1 arp mode 1000baseTx-FD exit system contact "[email protected]"
Chapter 6. Configuration management
199
name "DataPower" location "DataCentre" exit host-alias "authenticatedTraffic" reset ip-address 192.168.1.50 exit host-alias "boundryTraffic" reset ip-address 192.168.1.51 exit # Web and XML-MGMT Interfaces can be restricted to a INT, so put them in Fixed Config web-mgmt admin-state enabled local-address 0.0.0.0 9090 idle-timeout 6000 exit xml-mgmt admin-state enabled local-address 0.0.0.0 5550 mode any+soma+v2004+amp+slm exit # Now pull in the Variable part of the configuration, this is the same for all devices in this environment, i.e. Dev/Test/Prod exec http://9.33.97.230/dp/prod/defaultDomainVariable.cfg The defaultDomainVariable.cfg file can itself include other configuration files, in order to completely compartmentalize (separate) each application domain. An example defaultDomainVariable.cfg file is shown in Example 6-7.
Example 6-7 DefaultDomainVariable configuration file
# This is the variable component of the 'Default' Domain for all DataPower devices. It is "exec"ed into the device via the defaultDomainFixed.cfg configuration dns admin-state enabled search-domain "ibm.com" name-server 152.155.21.10 53 53 0 3 name-server 152.155.21.60 53 53 0 3 exit alias "reload" "flash;boot config autoconfig.cfg;shutdown reload" network admin-state enabled icmp-disable Timestamp-Reply exit ntp-service admin-state disabled remote-server 152.159.20.10 remote-server 152.159.20.60 exit timezone EST5EDT snmp admin-state enabled 200
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
ip-address 192.168.0.52 community "public" "default" "read-only" "0.0.0.0/0" exit ssh 0.0.0.0 22 save-config overwrite domain "prodDomain" reset base-dir local: base-dir prodDomain: config-file prodDomain.cfg visible-domain default url-permissions http+https+snmp+ftp+mailto+mq file-permissions CopyFrom+CopyTo+Delete+Display+Exec+Subdir config-mode import import-url "http://9.33.97.230/dp/prod/prodDomain.xcfg" import-format XML exit
201
202
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Appendix A.
203
The enterprise service bus (ESB) is a middleware infrastructure component that supports the implementation of SOA within an enterprise. Figure A-1 illustrates where the enterprise service bus fits in the SOA reference architecture.
Fundamentally, an enterprise service bus is a flexible connectivity infrastructure for integrating applications and services. An ESB performs the following between requestor and service: Converting transport protocols between requestor and service Handling business events from disparate sources Routing messages between services Transforming message formats between requestor and service The need for an ESB can be seen by considering how it supports the concepts of SOA implementation by: Decoupling the consumers view of a service from the actual implementation of the service Decoupling technical aspects of service interactions Integrating and managing services in the enterprise Decoupling the consumers view of a service from the actual implementation greatly increases the flexibility of the architecture. It allows the substitution of one service provider for another (for example, because another provider offers the same services for lower cost or with higher standards) without the consumer being aware of the change or without the need to alter the architecture to support the substitution. This decoupling is better achieved by having the consumers and providers interact via an intermediary. Intermediaries publish services to consumers. The consumer binds to the intermediary to access the service, with no direct coupling to the actual provider of the service. The intermediary maps the request to the location of the real service implementation. In an SOA, services are described as being loosely coupled. However, at implementation time, there is no way to loosely couple a service or any other interaction between systems.
204
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
The systems must have some common understanding to conduct an interaction. Instead, to achieve the benefits of loose coupling, consideration should be given to how to couple or decouple various aspects of service interactions, such as the platform and language in which services are implemented, the communication protocols used to invoke services, or the data formats used to exchange input and output data between service consumers and providers. Further decoupling can be achieved by handling some of the technical aspects of transactions outside of applications. This could apply to aspects of interactions such as: How service interactions are secured How the integrity of business transactions and data is maintained (for example, through reliable messaging, the use of transaction monitors, or compensation techniques) How the invocation of alternative service providers is handled in the event that the default provider is unavailable These aspects imply a need for middleware to support an SOA implementation. Some of the functions that might be provided by the middleware are: Map service requests from one protocol and address to another. Transform data formats. Support a variety of security and transactional models between service consumers and service providers and recognize that consumers and providers might support or require different models. Aggregate or disaggregate service requests and responses. Support communication protocols between multiple platforms with appropriate qualities of service. Provide messaging capabilities such as message correlation and publish/subscribe to support different messaging models such as events and asynchronous request/response. This middleware support is the role of an ESB.
205
monitoring, or systems management is implemented. This environment is difficult to manage or maintain and inhibits change. A common approach to reducing this complexity is to introduce a centralized point through which interactions are routed, as shown in Figure A-2.
A hub and spoke architecture is a common approach that is used in application integration architectures. In a hub, the distribution rules are separated from applications. The applications connect to the hub and not directly to any other application. This type of connection allows a single interaction from an application to be distributed to multiple target applications without the consumer being aware that multiple providers are involved in servicing the request. This connection can reduce the proliferation of point-to-point connections. Note that the benefit of reducing the number of connections only truly emerges if the application interfaces and connections are genuinely reusable. For example, consider the case where one application needs to send data to three other applications. If this is implemented in a hub, the sending application must define a link to the hub, and the hub must have links that are defined to the three receiving applications, giving a total of four interfaces that need to be defined. If the same scenario was implemented using multiple point-to-point links, the sending application would need to define links to each of the three receiving applications, giving a total of just three links. A hub only offers the benefit of reduced links if another application also needs to send data to the receiving applications and can make use of the same links as those that are already defined for the first application. In this scenario, the new application only needs to define a connection between itself and the hub, which can then send the data correctly formatted to the receiving applications. Hubs can be federated together to form what is logically a single entity that provides a single point of control but is actually a collection of physically distributed components. This is commonly termed a bus. A bus provides a consistent management and administration approach to a distributed integration infrastructure.
206
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
SOA applications are built from services. Typically, a business service relies on many other services in its implementation. The ESB is the component that provides access to the services and so enables the building of SOA applications.
Mediation support
The ESB is more than just a transport layer. It must provide mediation support to facilitate service interactions (for example, to find services that provide capabilities for which a consumer is asking or to take care of interface mismatches between consumers and providers that are compatible in terms of their capabilities). It must support a variety of ways to get on and off the bus, such as adapter support for existing applications or business connections, that enable external partners in business-to-business interaction scenarios. To support these different ways to get on and off the bus, it must support service interaction with a wide variety of service endpoints. It is likely that each endpoint will have its own integration techniques, protocols, security models, and so on. This level of complexity should be hidden from service consumers. They need to be offered a simpler model. In order to hide the complexity from the consumers, the ESB is required to mediate between the multiple interaction models that are understood by service providers and the simplified view that is provided to consumers.
207
Protocol independence
As shown in Figure 2-3 on page 15, services can be offered by a variety of sources. Without an ESB infrastructure, any service consumer that needs to invoke a service needs to connect directly to a service provider using the protocol, transport, and interaction pattern that is used by the provider. With an ESB, the infrastructure shields the consumer from the details of how to connect to the provider. In an ESB, there is no direct connection between the consumer and provider. Consumers access the ESB to invoke services, and the ESB acts as an intermediary by passing the request to the provider using the appropriate protocol, transport, and interaction pattern for the provider. This intermediary connection enables the ESB to shield the consumer from the infrastructure details of how to connect to the provider. The ESB should support several integration mechanisms, all of which can be described as invoking services through specific addresses and protocols, even if in some cases the address is the name of a CICS transaction and the protocol is a J2EE resource adapter integrating with the CICS Transaction Gateway. By using the ESB, the consumers are unaware of how the service is invoked on the provider. Because the ESB removes the direct connection between service consumer and providers, an ESB enables the substitution of one service implementation by another with no effect to the consumers of that service. Thus, an ESB allows the reach of an SOA to extend to non-SOA-enabled service providers. It can also be used to support migration of the non-SOA providers to using an SOA approach without impacting the consumers of the service.
208
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Appendix B.
XML security
209
XML threats
To truly harden a system using Web services, you need to perform several important security steps, including: Inspect messages for well-formedness. Validate schema. Verify digital signatures. Sign messages. Implement service virtualization to mask internal resources via XML transformation and routing. Encrypt data at the field level. An article by Bill Hines (http://www.ibm.com/developerworks/websphere/techjournal/0603_col_hines/0603_col_h ines.html) concludes with the following comments. We consider four broad classifications of XML threats: XML of Service (xDOS): Slowing down or disabling a Web Service so that valid service requests are hampered or denied. Unauthorized Access: Gaining unauthorized access to a Web Service or its data. Data Integrity/Confidentiality: Attacks that strike at data integrity of Web Service responses, requests or underlying databases: System Compromise: Corrupting the Web Service itself or the servers that host it. These threats may be facilitated by tricky/complex XML, virus-laden XML/SOAP attachments, and so on.
210
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Public key DoS: Utilizing the asymmetric nature of public key operations to force resource exhaustion on the recipient by transmitting a message with a large number of long-key-length, computationally expensive digital signatures
211
Malicious include: Causing a Web service to include invalid external data in output or return privileged files from the server file system. For example, using embedded file URLs to return UNIX password files or other privileged data to the attacker. Memory space breach: Accomplished via stack overflow, buffer overrun, or heap error, allows execution of arbitrary code supplied by the attacker with permissions of the host process. XML encapsulation: Embedding system command in the XML payload, such as through the CDATA tag. XML virus (X-Virus): Using SOAP with Attachments or other attachment mechanisms to transmit malicious executables such as viruses or worms.
You need to minimize message latency when adding an ESB layer. You are doing extensive XML processing combined with high-performance requirements. Your ESB must be in production very quickly. You want integration with other IBM WebSphere and Tivoli products (that is, ESB beyond limits). Note that: All XML interaction with third parties should go through DataPower XS40 for XML threat protection for the traffic. If your DataPower appliance has to do more than act as a security gateway (that is, protocol transformation, XML traffic acceleration, or account for ESB) use the Datapower XI50. DataPower appliances address XML threats by delivering a robust XML firewall for the enterprise. DataPower appliances introduce sophisticated checks on the incoming XML, as illustrated in Figure 3-1 on page 33. This includes the following: XML/SOAP firewall, filtering based on message content, headers, or other network variables Incoming/outgoing data validation Data schema validation (XML and binary) XML threat protection Single-message XML denial of service (XDoS) protection Multiple-message XML denial of service protection Message tampering protection Protocol threat protection XML virus protection Dictionary attack protection
References
For more information refer to the following resources: WebSphere Application Server http://www-306.ibm.com/software/websphere/ Java 2 Enterprise Edition (J2EE) http://java.sun.com/j2ee/ Enabling cryptographic hardware for the Secure Sockets Layer http://www-306.ibm.com/software/webservers/httpservers/doc/v2047/manual/ibm/en_ US/9aecdssl.htm WebSphere Web Services Gateway (WSGW) http://www-128.ibm.com/developerworks/websphere/techjournal/0408_alcott/0408_ alcott.html Extensible Markup Language (XML) http://www.w3.org/XML/
213
XML Path Language (XPath) http://www.w3.org/TR/xpath The Extensible Stylesheet Language Family (XSL) http://www.w3.org/Style/XSL Specification: Web Services Security (WS-Security) http://www-106.ibm.com/developerworks/webservices/library/ws-secure/ SOAP specifications http://www.w3.org/TR/soap/ Simple API for XML http://www.saxproject.org/ SOA http://www.ibm.com/soa/ WebSphere Enterprise Service Bus http://www-306.ibm.com/software/integration/wsesb// WebSphere Message Broker http://www-306.ibm.com/software/integration/wbimessagebroker/
214
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Glossary
A
Attribute. Characteristic of a subject, resource, action, or environment that may be referenced in a predicate or target (see also named attribute). Authorization decision. The result of evaluating applicable policy, returned by the PDP to the PEP. A function that evaluates to permit, deny, indeterminate, or NotApplicable, and (optionally) a set of obligations. Authorization decision. The result of evaluating applicable policy, returned by the PDP to the PEP. A function that typically evaluates to permit or deny. B Bag. An unordered collection of values, in which there may be duplicate values. C Condition. An expression of predicates. A function that evaluates to true, false, or indeterminate. Conjunctive sequence. A sequence of predicates combined using the logical AND operation. Context handler. The system entity that converts decision requests in the native request format to the XACML canonical form and converts authorization decisions in the XACML canonical form to the native response format Context. The canonical representation of a decision request and an authorization decision. D
Entitlement. A data structure that contains externalized security policy information. Entitlements contain policy data or capabilities that are formatted in a way that is understandable to a specific application. For example, an automotive price lookup service is required to return different pricing information based on the entitlements associated with user identity. Assume that there are three policies defined for accessing this service: {ReadMSRP, ReadDealerPrice, and ReadDistributorPrice}. Each policy evaluates to a Boolean value. An example of entitlement in this case could be expressed as the following set of name-value pairs: {ReadMSRP=true, ReadDealerPrice=true, ReadDistributorPrice=false}. Environment. The set of attributes that are relevant to an authorization decision and are independent of a particular subject, resource, or action. N Named attribute. A specific instance of an attribute, determined by the attribute name and type, the identity of the attribute holder (which may be of type subject, resource, action, or environment) and (optionally) the identity of the issuing authority. O Obligation. An operation specified in a policy or policy set that should be performed by the PEP in conjunction with the enforcement of an authorization decision. P
Decision request. The request by a PEP to a PDP to render an authorization decision. Decision. The result of evaluating a rule, policy, or policy set. E
Policy administration point (PAP). The system entity that creates a policy or policy set. Policy decision point (PDP). The system entity that evaluates applicable policy and renders an authorization decision. This term is defined in a joint effort by the IETF Policy Framework Working Group and the Distributed Management Task Force (DMTF)/Common Information Model (CIM) in [RFC3198]. This term corresponds to Access Decision Function (ADF) in [ISO10181-3].
215
Policy enforcement point (PEP). The system entity that performs access control, by making decision requests and enforcing authorization decisions. This term is defined in a joint effort by the IETF Policy Framework Working Group and the Distributed Management Task Force (DMTF)/Common Information Model (CIM) in [RFC3198]. This term corresponds to Access Enforcement Function (AEF) in [ISO10181-3]. Policy information point (PIP). The system entity that acts as a source of attribute values. Policy set. A set of policies, other policy sets, a policy-combining algorithm, and (optionally) a set of obligations. May be a component of another policy set. Policy. A set of rules, an identifier for the rule-combining algorithm, and (optionally) a set of obligations. May be a component of a policy set. Policy-combining algorithm. The procedure for combining the decision and obligations from multiple policies. Predicate. A statement about attributes whose truth can be evaluated. Resource manager. The system entity located between request initiator and target resource responsible for implementing the requested operation when authorization is granted. A component of the resource manager is a policy enforcer that directs the request to the authorization service for processing. Resource. Data, service, or system component. Rule. A target, an effect, and a condition. A component of a policy. Rule-combining algorithm. The procedure for combining decisions from multiple rules. Security context. Protected data structure attached to a message that contains security credentials associated with current request. Subject. An actor whose attributes may be referenced by a predicate. Target. The set of decision requests, identified by definitions for resource, subject, and action, that a rule, policy, or policy set is intended to evaluate.
216
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Related publications
The publications listed in this section are considered particularly suitable for a more detailed discussion of the topics covered in this book.
Other publications
These publications are also relevant as further information sources: DataPower WebGUI Guide, also available online with free registration http://www.ibm.com/support/docview.wss?rs=2362&uid=swg24014405
217
Online resources
These Web sites are also relevant as further information sources: Product information about IBM WebSphere DataPower SOA Appliances http://www-306.ibm.com/software/integration/datapower/index.html Integrating Web applications with the DataPower Web application firewall service, IBM Developer Works, Ozair Sheikh, 12 Dec 2007 http://www.ibm.com/developerworks/websphere/library/techarticles/0712_sheikh/07 12_sheikh.html IBM Web services http://www.ibm.com/webservices IBM on demand operating environment http://www-3.ibm.com/software/info/openenvironment/ IBM developerWorks: SOA and Web services zone http://www.ibm.com/developerworks/webservices First look at the WS-I Basic Profile1.0, 2002 http://www.ibm.com/developerworks/webservices/library/ws-basicprof.htm WC3, Web Services Addressing (WS-Addressing), 2004 http://www.w3.org/Submission/ws-addressing/ Web Services Security Policy Language (WS-SecurityPolicy)
http://download.boulder.ibm.com/ibmdl/pub/software/dw/specs/ws-secpol/ws-secpol.pdf
developerWorks, developerWorks Forum, 2007 http://www.ibm.com/developerworks/forums/thread.jspa?messageID=14056243 developerWorks, developerWorks Forum, 2007 http://www.ibm.com/developerworks/library/specification/ws-rm/ IBM, BEA, Microsoft, TIBCO, Web Services Reliable Messaging Protocol Specification, 2005 http://specs.xmlsoap.org/ws/2005/02/rm/ws-reliablemessaging.pdf Web Services Reliable Messaging http://www.ibm.com/developerworks/webservices/library/specification/ws-rm/ Web Services Policy Framework
http://www.ibm.com/developerworks/webservices/library/specification/ws-polfram/
Web Services Policy Framework (WS-Policy) http://specs.xmlsoap.org/ws/2004/09/policy/ws-policy.pdf Web Services Security Policy Language (WS-SecurityPolicy)
http://download.boulder.ibm.com/ibmdl/pub/software/dw/specs/ws-secpol/ws-secpol.pdf
218
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Web Services Reliable Messaging Protocol (WS-ReliableMessaging) http://download.boulder.ibm.com/ibmdl/pub/software/dw/specs/ws-rm/ws-reliable messaging200502.pdf Web Services Policy Attachment
http://www.ibm.com/developerworks/webservices/library/specification/ws-polatt/
Web Services Policy Attachment (WS-PolicyAttachment) http://download.boulder.ibm.com/ibmdl/pub/software/dw/specs/ws-polatt/ws-polat2006-03-01.pdf Using DataPower SOA Appliances to query WebSphere Service Registry and Repository http://www.ibm.com/developerworks/websphere/techjournal/0805_peterson/0805_ peterson.html The XACML specification: http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=xacml OASIS eXtensible Access Control Markup Language (XACML) Version 1.1 http://www.oasis-open.org/committees/download.php/2406/oasis-xacml-1.0.pdf Creating XACML Based Authorization using DataPower, Case Study by Karen Punwani XML schema and content validation using DataPower and DB2 pureXML http://www.ibm.com/developerworks/db2/library/techarticle/dm-0805malaika3/index .html?ca=drs-#resources Schematron Web site http://www.schematron.com/overview.html Generate Web services for DB2 9 pureXML http://www.ibm.com/developerworks/db2/library/techarticle/dm-0706bommireddipalli/ Get started with Industry Formats and Services with pureXML http://www.ibm.com/developerworks/db2/library/techarticle/dm-0705malaika/ Industry Formats and Services with pureXML http://www.alphaworks.ibm.com/tech/purexml Combining Service-Oriented Architecture and Event-Driven Architecture using an Enterprise Service Bus http://www.ibm.com/developerworks/library/ws-soa-eda-esb/ Enterprise Service Bus implementation patterns http://www.ibm.com/developerworks/websphere/library/techarticles/0712_grund/071 2_grund.html Security Patterns within a Service-Oriented Architecture http://www.ebizq.net/topics/soa/features/6554.html?&pp=1 Make SOA real with IBM WebSphere Enterprise Service Bus and IBM WebSphere DataPower SOA Appliance http://www.ibm.com/developerworks/webservices/library/ws-soa-real1/ BPEL or ESB: Which should you use? http://www.ibm.com/developerworks/websphere/library/techarticles/0803_fasbinder 2/0803_fasbinder2.html
Related publications
219
Exploring the Enterprise Service Bus, Part 2: Why the ESB is a fundamental part of SOA http://www.ibm.com/developerworks/library/ar-esbpat2/ Make SOA real with IBM WebSphere Enterprise Service Bus and IBM WebSphere DataPower SOA Appliances series http://www.ibm.com/developerworks/views/webservices/libraryview.jsp?search_by= Make+SOA+real+with+IBM+WebSphere+Enterprise+Service+Bus+and+IBM+WebSphere+Data Power+SOA+Appliances eWeb Services ArchitectureW3C Working Group Note 11 February 2004 http://www.w3.org/TR/ws-arch/#service_oriented_architecture Getting started with WebSphere Transformation Extender Design Studio on DataPower, developerWorks http://www.ibm.com/developerworks/websphere/library/techarticles/0712_vila/0712 _vila.html Information about WebSphere Transformation Extender http://www-306.ibm.com/software/integration/wdatastagetx/library/index.html WebSphere DataPower WebSphere MQ Interoperability Release 3.6.0.0, developerWorks http://www-1.ibm.com/support/docview.wss?uid=swg21255199 Integrating WebSphere DataPower SOA Appliances with WebSphere MQ, developerWorks http://www.ibm.com/developerworks/websphere/library/techarticles/0703_crocker/0 703_crocker.html?S_TACT=105AGX78&S_CMP=ART WebSphere MQ Product home http://www.ibm.com/software/integration/wmq/ Service-enable CICS and IMS traditional applications using the IBM WebSphere DataPower SOA Appliance http://www.ibm.com/developerworks/library/ar-datapow/ Integrating WebSphere DataPower SOA Appliances with WebSphere MQ http://www.ibm.com/developerworks/websphere/library/techarticles/0703_crocker/0 703_crocker.html?S_TACT=105AGX78&S_CMP=ART Integrating DataPower with WebSphere Message Broker using the Broker Explorer http://www.ibm.com/developerworks/websphere/library/techarticles/0707_storey/07 07_storey.html Enterprise Service Bus implementation patterns http://www.ibm.com/developerworks/websphere/library/techarticles/0712_grund/071 2_grund.html Configuration for high availability, configuration promotion, and control http://www.ibm.com/developerworks/websphere/library/techarticles/0801_rasmussen /0801_rasmussen.html
220
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Related publications
221
222
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
DataPower Architectural Design Patterns: Integrating and Securing
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
DataPower Architectural Design Patterns: Integrating and Securing Services Across Domains
Back cover
DataPower Architectural Design Patterns Integrating and Securing Services Across Domains
Introduction to DataPower Services Integration Services Security Services
IBM WebSphere DataPower SOA Appliances are purpose-built network devices that offer a wide variety of functionality such as the securing and management of SOA Applications, enterprise service bus integration, and high speed XSL execution. A hardened appliance, DataPower provides robust security features including tamper protection of the device itself. This IBM Redbooks publication was written for application architects and other consultants who want to include DataPower appliances in their solutions for reasons of speed, security, or ESB integration. The topics include DataPower services, Web services, security, and integration strategies.