BEA AquaLogic Service Bus behind the Firewall in Service-Oriented Architecture



Similar documents
Oracle Service Bus Behind the Firewall in a Service-Oriented Architecture. An Oracle White Paper Updated October 2008

BEA AquaLogic Service Bus and WebSphere MQ in Service-Oriented Architectures

CHAPTER 7 SSL CONFIGURATION AND TESTING

Overview of CSS SSL. SSL Cryptography Overview CHAPTER

F-Secure Messaging Security Gateway. Deployment Guide

Enabling SSL and Client Certificates on the SAP J2EE Engine

Overview. SSL Cryptography Overview CHAPTER 1

BEA AquaLogic Integrator Agile integration for the Enterprise Build, Connect, Re-use

BEAWebLogic. Portal. WebLogic Portlets for SAP Installation Guide

BlackBerry Enterprise Service 10. Secure Work Space for ios and Android Version: Security Note

Unifying Information Security. Implementing TLS on the CLEARSWIFT SECURE Gateway

BlackBerry Enterprise Service 10. Version: Configuration Guide

Configuration Guide. BlackBerry Enterprise Service 12. Version 12.0

Introduction to the EIS Guide

SSL Configuration on Weblogic Oracle FLEXCUBE Universal Banking Release [August] [2014]

A host-based firewall can be used in addition to a network-based firewall to provide multiple layers of protection.

Setup Guide Access Manager Appliance 3.2 SP3

Configuration Guide BES12. Version 12.1

CA Performance Center

Configuration Guide BES12. Version 12.2

Integrated SSL Scanning

Decryption. Palo Alto Networks. PAN-OS Administrator s Guide Version 6.0. Copyright Palo Alto Networks

Configuring Secure Socket Layer and Client-Certificate Authentication on SAS 9.3 Enterprise BI Server Systems That Use Oracle WebLogic 10.

Introduction to Mobile Access Gateway Installation

IONA Security Platform

Secure Web Service - Hybrid. Policy Server Setup. Release Manual Version 1.01

Setup Guide Access Manager 3.2 SP3

Cornerstones of Security

Angel Dichev RIG, SAP Labs

Data Collection and Analysis: Get End-to-End Security with Cisco Connected Analytics for Network Deployment

Installation and configuration guide

Unified Communications in RealPresence Access Director System Environments

Chapter 2 TOPOLOGY SELECTION. SYS-ED/ Computer Education Techniques, Inc.

The HTTP Plug-in. Table of contents

GlobalSCAPE DMZ Gateway, v1. User Guide

Installation and configuration guide

Implementing PCoIP Proxy as a Security Server/Access Point Alternative

Oracle Exam 1z0-102 Oracle Weblogic Server 11g: System Administration I Version: 9.0 [ Total Questions: 111 ]

Polycom RealPresence Resource Manager System Getting Started Guide

SolarWinds Technical Reference

Chapter 17. Transport-Level Security

Configuration Guide BES12. Version 12.3

M86 Web Filter USER GUIDE for M86 Mobile Security Client. Software Version: Document Version:

IBM Security QRadar Vulnerability Manager Version User Guide

NSi Mobile Installation Guide. Version 6.2

Installing and Configuring vcloud Connector

ISA Server Plugins Setup Guide

Architecture and Data Flow Overview. BlackBerry Enterprise Service Version: Quick Reference

Oracle Managed File Getting Started - Transfer FTP Server to File Table of Contents

CTS2134 Introduction to Networking. Module Network Security

Cisco AnyConnect Secure Mobility Solution Guide

SSL CONFIGURATION GUIDE

Deployment Guide Microsoft IIS 7.0

A BEA Enterprise Architecture Guide

BEAWebLogic. Server. Configuring and Managing WebLogic Server

IBM SPSS Collaboration and Deployment Services Version 6 Release 0. Single Sign-On Services Developer's Guide

Configuring Single Sign-On for Documentum Applications with RSA Access Manager Product Suite. Abstract

Deploying EMC Documentum WDK Applications with IBM WebSEAL as a Reverse Proxy

Novell Access Manager

HTTP Reverse Proxy Scenarios

(n)code Solutions CA A DIVISION OF GUJARAT NARMADA VALLEY FERTILIZERS COMPANY LIMITED P ROCEDURE F OR D OWNLOADING

Network-Enabled Devices, AOS v.5.x.x. Content and Purpose of This Guide...1 User Management...2 Types of user accounts2

Websense Content Gateway HTTPS Configuration

GRAVITYZONE HERE. Deployment Guide VLE Environment

Security Guide Release 7.3

A Guide to New Features in Propalms OneGate 4.0

CS 356 Lecture 27 Internet Security Protocols. Spring 2013

NEFSIS DEDICATED SERVER

Oracle Communications WebRTC Session Controller: Basic Admin. Student Guide

Crawl Proxy Installation and Configuration Guide

Customer Tips. Xerox Network Scanning HTTP/HTTPS Configuration using Microsoft IIS. for the user. Purpose. Background

Certificate Management. PAN-OS Administrator s Guide. Version 7.0

Securing SAS Web Applications with SiteMinder

WHITE PAPER Citrix Secure Gateway Startup Guide

Securing Networks with PIX and ASA

Clearswift Information Governance

Configuration Guide. BES12 Cloud

PowerChute TM Network Shutdown Security Features & Deployment

NATIONAL SECURITY AGENCY Ft. George G. Meade, MD

LifeSize Transit Deployment Guide June 2011

Configuring IBM WebSphere Application Server 7 for Secure Sockets Layer and Client-Certificate Authentication on SAS 9.3 Enterprise BI Server Web


An Oracle White Paper September Oracle WebLogic Server 12c on Microsoft Windows Azure

SOA Software: Troubleshooting Guide for Agents

CHAPTER 1 - JAVA EE OVERVIEW FOR ADMINISTRATORS

Entrust Managed Services PKI. Getting started with digital certificates and Entrust Managed Services PKI. Document issue: 1.0

Release Notes for Version

Lotus Sametime. FIPS Support for IBM Lotus Sametime 8.0. Version 8.0 SC

How To Understand And Understand The Security Of A Key Infrastructure

Integrated SSL Scanning

Cox Managed CPE Services. RADIUS Authentication for AnyConnect VPN Version 1.3 [Draft]

Installation and Configuration Guide

INTEGRATE SALESFORCE.COM SINGLE SIGN-ON WITH THIRD-PARTY SINGLE SIGN-ON USING SENTRY A GUIDE TO SUCCESSFUL USE CASE

Integrated Citrix Servers

EMC Data Protection Search

Transcription:

BEA White Paper BEA AquaLogic Service Bus behind the Firewall in Service-Oriented Architecture Using BEA AquaLogic Service Bus in Service-Oriented Architecture with Firewalls, Demilitarized Zone, and Two-Way Inbound and Outbound SSL Authentication

Copyright Copyright 1995-2006 BEA Systems, Inc. All Rights Reserved. Restricted Rights Legend This software is protected by copyright, and may be protected by patent laws. No copying or other use of this software is permitted unless you have entered into a license agreement with BEA authorizing such use. This document is protected by copyright and may not be copied photocopied, reproduced, translated, or reduced to any electronic medium or machine readable form, in whole or in part, without prior consent, in writing, from BEA Systems, Inc. Information in this document is subject to change without notice and does not represent a commitment on the part of BEA Systems. THE DOCUMENTATION IS PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. FURTHER, BEA SYSTEMS DOES NOT WARRANT, GUARANTEE, OR MAKE ANY REPRESENTATIONS REGARDING THE USE, OR THE RESULTS OF THE USE, OF THE DOCUMENT IN TERMS OF CORRECTNESS, ACCURACY, RELIABILITY, OR OTHERWISE. Trademarks and Service Marks Copyright 1995-2006 BEA Systems, Inc. All Rights Reserved. BEA, BEA JRockit, BEA WebLogic Portal, BEA WebLogic Server, BEA WebLogic Workshop, Built on BEA, Jolt, JoltBeans, SteelThread, Top End, Tuxedo, and WebLogic are registered trademarks of BEA Systems, Inc. BEA AquaLogic, BEA AquaLogic Data Services Platform, BEA AquaLogic Enterprise Security, BEA AquaLogic Service Bus, BEA AquaLogic Service Registry, BEA Builder, BEA Campaign Manager for WebLogic, BEA elink, BEA Liquid Data for WebLogic, BEA Manager, BEA MessageQ, BEA WebLogic Commerce Server, BEA WebLogic Communications Platform, BEA WebLogic Enterprise, BEA WebLogic Enterprise Platform, BEA WebLogic Enterprise Security, BEA WebLogic Express, BEA WebLogic Integration, BEA WebLogic Java Adapter for Mainframe, BEA WebLogic JDriver, BEA WebLogic Log Central, BEA WebLogic Network Gatekeeper, BEA WebLogic Personalization Server, BEA WebLogic Personal Messaging API, BEA WebLogic Platform, BEA WebLogic Portlets for Groupware Integration, BEA WebLogic Server Process Edition, BEA WebLogic SIP Server, BEA WebLogic WorkGroup Edition, Dev2Dev, Liquid Computing, and Think Liquid are trademarks of BEA Systems, Inc. BEA Mission Critical Support, BEA Mission Critical Support Continuum, and BEA SOA Self Assessment are service marks of BEA Systems, Inc. All other names and marks are property of their respective owners. CWP1441Ex0906-1A

Contents 1. Abstract............................................................................1 1.1. AquaLogic Service Bus Domain behind the firewall........................................1 2. Background.........................................................................2 2.1. Definitions of terms, acronyms, and abbreviations.........................................2 2.2. BEA WebLogic Server support of one-way and two-way SSL...............................3 2.3. References and related documents....................................................6 3. Problem definition: How to establish two-way inbound and two-way outbound SSL authentication between client, BEA AquaLogic Service Bus, and business service separated by firewalls.....................7 4. Deployment architecture, set-up, and configuration...........................................7 4.1. Deployment architecture example.....................................................8 4.2. Inbound and outbound two-way SSL authentication configuration...........................10 4.2.1. Two-way SSL authentication....................................................10 4.2.2. BEA WebLogic Server configuration of one-way and two-way SSL.......................10 4.2.3. About PKI credential mappers...................................................11 4.2.4. Configuration steps...........................................................12 5. Testing............................................................................13 5.1. Business service.................................................................13 5.2. Proxy service....................................................................17 5.3. Client..........................................................................17 6. Conclusion.........................................................................24 7. About BEA.........................................................................24 8. Join the BEA community...............................................................24

1. Abstract 1.1. BEA AquaLogic Service Bus domain behind the firewall As organizations move to Service-Oriented Architecture (SOA), security becomes one of the key concerns impacting deployment. A company s sensitive information is accessed by services deployed on the distributed components in a SOA. Therefore, security concerns have become part of the enterprise decision-making process relating to the adoption of an SOA. Typically, a company sends request messages from BEA AquaLogic Service Bus behind its internal firewall to business services hosted outside its firewall. In such a scenario, BEA AquaLogic Service Bus acts as a forward proxy. The company receives response messages from business services through the demilitarized zone (DMZ) into BEA AquaLogic Service Bus, which is deployed behind the company firewall. In this case, BEA AquaLogic Service Bus would act as a reverse proxy. This paper discusses the security set-up and configuration for clients, BEA AquaLogic Service Bus (version 2.1, 2.5, and 2.6) proxy services, and business services. The set-up assumes that a client Web application sends an HTTPS request message from outside a company s firewall to the BEA AquaLogic Service Bus server located behind its firewall (the inbound request ). BEA AquaLogic Service Bus then routes the HTTPS request message to a business service hosted outside its firewall (the outbound request ). The business service sends the response message through BEA AquaLogic Service Bus to the client. This set-up involves an inbound one- or two-way and an outbound one- or two-way SSL authentication. It capitalizes on BEA WebLogic Server and BEA AquaLogic Service Bus security. The paper provides an example of how to configure the inbound two-way and outbound two-way SSL authentication from the command line, the BEA WebLogic Server Administration Console, and the BEA AquaLogic Service Bus Console. The example includes a description of the deployment architecture and how to test the system with request/response messaging. 1

2. Background 2.1. Definitions of terms, acronyms, and abbreviations Firewall A firewall limits traffic between two networks. Firewalls can be a combination of software and hardware, including routers and dedicated gateway machines. They employ filters that allow or disallow traffic to pass based on the transport protocol, the service requested, routing information, and the origin and destination hosts or networks. They may also allow access for authenticated users. Figure 2.1 illustrates a typical set-up with a firewall that filters the traffic destined for a BEA WebLogic Server cluster. Demilitarized zone (DMZ) A demilitarized zone is a network area that sits between an organization s internal network and an external network, usually the Internet. The typical approach is to create a DMZ between two firewalls. The network DMZ must be monitored carefully, because sensitive objects are exposed to higher risk than services behind the firewall. It is important to carefully control administrative access to services on the DMZ. Most likely, access should be allowed only from the internal network, and preferably over a cryptographically protected connection, such as SSH. A DMZ is an example of our general philosophy of defense in depth: Multiple layers of security provide a better shield than a simple firewall. If an attacker penetrates the first firewall, he or she gains access to the DMZ, but not necessarily to the internal network. (See a description of DMZs in Firewalls and Internet Security: Repelling the Wily Hacker, by William R. Cheswick, Steven M. Bellovin, and Aviel D. Rubin, listed in Chapter 2.3: References and related documents.) Figure 2.1 Typical firewall set-up. External Client Firewall BEA WebLogic Server Cluster Internal Client Network A Network A 2

Secure Sockets Layer (SSL) SSL enables secure communication between applications connected through the Web. For a discussion of the components of SSL communication and why each component is necessary, see OpenSSL Documents and SSL and TLS: Designing and Building Secure Systems by Eric Rescorla, Addison-Wesley, 2001 in Chapter 2.3: References and related documents. BEA WebLogic Server uses the Certicom SSLPlus Java version 4.0 SSL implementation. The RSA Cert-J and Crypto-J have been upgraded to Cert-J version 2.1.1 and Crypto-J version 3.5. Network interface card (NIC) A network interface card (also called a network adapter or network card) is a piece of computer hardware designed to allow computers to communicate over a computer network. (Wikipedia, http://en.wikipedia.org/wiki/network_card) 2.2. BEA WebLogic Server support of one-way and two-way SSL SSL features BEA WebLogic Server provides a pure-java implementation of SSL. Generally, SSL provides the following: A mechanism that the communicating applications can use to authenticate each other s identity Encryption of the data exchanged by the applications. When SSL is used, the target (the server) always authenticates itself to the initiator (the client). Optionally, if the target requests it, the initiator can authenticate itself to the target. Encryption makes data transmitted over the network intelligible only to the intended recipient. An SSL connection begins with a handshake during which the applications exchange digital certificates, agree on the encryption algorithms to be used, and generate the encryption keys to be used for the remainder of the session. SSL provides the following security features: Server authentication-bea WebLogic Server uses its digital certificate, issued by a trusted certificate authority, to authenticate to clients. SSL minimally requires the server to authenticate to the client using its digital certificate. If the client is not required to present a digital certificate, the connection type is called oneway SSL authentication. Client identity verification-optionally, clients can be required to present their digital certificates to BEA WebLogic Server, which then verifies that the digital certificate was issued by a trusted certificate authority and establishes the SSL connection. An SSL connection is not established if the digital certificate is not presented and verified. This type of connection is called two-way SSL authentication, a form of mutual authentication. Confidentiality-All client requests and server responses are encrypted to maintain the confidentiality of data exchanged over the network. Data integrity-each SSL message contains a message digest computed from the original data. On the receiving end, a new digest is computed from the decrypted data and then compared with the digest that came with the message. If the data has been altered, the digests don t match and tampering is detected. 3

Data that flows between a client and BEA WebLogic Server is protected from tampering by a third-party validation of user identities. If you are using a Web browser to communicate with BEA WebLogic Server, you can use the Hyper-Text Transfer Protocol with SSL (HTTPS) to secure network communications. SSL tunneling BEA WebLogic Server supports tunneling with HTTP, T3, and IIOP protocols over SSL. SSL can be used by Web browsers and Java clients as follows: A Web browser makes an SSL connection to a server over HTTPS. The browser then sends HTTP requests and receives HTTP responses over this SSL connection. For example: https://myserver.com/mypage.html BEA WebLogic Server supports SSL versioning. This means it can communicate with any client, including Web browsers that use SSL v2, SSL v3, and TLS v1. Java clients using HTTP/T3 protocols can tunnel over SSL. For example: t3s://myserver.com:7002/mypage.html Java clients running in BEA WebLogic Server can establish either T3S connections to other instances of BEA WebLogic Server, or HTTPS connections to other servers that support SSL, such as Web servers or secure proxy servers. BEA WebLogic Server support for one-way and two-way SSL authentication BEA WebLogic Server supports both one-way and two-way SSL authentication. With one-way SSL authentication, the target (the server) is required to present a digital certificate to the initiator (the client) to prove its identity. The client performs two checks to validate the digital certificate: The client verifies that the certificate is trusted (meaning it was issued by the client s trusted Certificate Authority), is valid (not expired), and satisfies other certificate constraints. The client checks that the certificate subject s common name (CN) field value matches the host name of the server to which the client is trying to connect. This is called host-name verification. Advanced options include inbound or/and outbound certificate lookup and validation (CLV). This feature provides additional protection by validating the certificate against the list of certificate authorities compiled by the server administrator. The BEA WebLogic security service provides the CLV API that finds and validates X509 certificate chains. A CertPath is a JDK class that stores a certificate chain in memory. The term CertPath is also used to refer to the JDK architecture and framework that is used to locate and validate certificate chains. The CLV framework extends and completes the JDK CertPath functionality. CertPath providers rely on a tightly coupled integration of BEA WebLogic and JDK interfaces. Your application code can use the default CertPath providers provided by BEA WebLogic Server to build and validate certificate chains, or use any custom CertPath provider. If all of the above checks return true, the SSL connection is established. With two-way SSL authentication, both the client and the server must present digital certificates before the SSL connection is enabled between the two. Thus, in this case, BEA WebLogic Server not only authenticates itself to the client (which is the minimum requirement for certificate authentication), but also requires authentication from the requesting client. 4

Two-way SSL authentication is useful when you must restrict access to trusted clients only. BEA WebLogic Server SSL connections support one-way SSL, two-way SSL, or both. The Web browser client, Web server, fat client, Web services client, and SSL server connections can be configured for either one-way or two-way SSL. BEA WebLogic Server determines whether an SSL connection is configured for one-way or two-way authentication, and SSL is configured using the Administration Console. Host-name verification Host-name verification is the process of verifying that the name of the host to which an SSL connection is made is the intended or authorized party. Host-name verification prevents man-in-the-middle attacks in which a client requests an SSL connection to a remote application server. By default, the SSL client, as a function of the SSL handshake, compares the common name in the SubjectDN of the SSL server s digital certificate with the host name of the SSL server to which it is trying to connect. If these names do not match, the SSL connection is dropped. Trust managers The trust manager provides a way to override the default SSL trust validation rules. It allows the server to decide whether or not it trusts the client that is contacting it. Using a trust manager, you can perform custom checks before continuing an SSL connection. For example, you can use the trust manager to specify that only users from specific localities, such as towns, states, or countries, or users with other special attributes, can gain access via the SSL connection. BEA WebLogic Server provides the weblogic.security.ssl.trustmanager interface. This interface allows custom trust-manager implementations to be called during the SSL handshake. The custom implementation can override the handshake error detected by the SSL implementation validation check or indicate an error based on its own certification rules. BEA WebLogic Server also provides the weblogic.security.ssl.certpath.trustmanager interface, which applications and custom code can use to control outbound SSL uses certificate lookup and validation. Note: The weblogic.security.ssl.certpath.trustmanager interface replaces the weblogic.security.ssl.trustmanagerjsse interface, which is superseded in the BEA WebLogic Server 9.1 release. Asymmetric key algorithms Asymmetric key (also referred to as public key) algorithms are implemented through a pair of different but mathematically related keys: a public key and a private key. The public key (which is distributed widely) is used for verifying a digital signature or transforming data into a seemingly unintelligible form. The private key (which is always kept secret) is used for creating a digital signature or returning the data to its original form. The Public Key Infrastructure (PKI) in BEA WebLogic Server also supports digital signature algorithms. Digital signature algorithms are simply public-key algorithms used to generate digital signatures. BEA WebLogic Server supports the Rivest, Shamir, and Adelman (RSA) algorithm. 5

2.3. References and related documents 2.3.1. Security for BEA WebLogic Server 9.1 http://e-docs.bea.com/wls/docs91/security.html 2.3.2. Understanding BEA WebLogic Security: Security Fundamentals http://e-docs.bea.com/wls/docs92/secintro/concepts.html 2.3.3. BEA AquaLogic Service Bus 2.1 and 2.5 Documentation: Security Configuration http://e-docs.bea.com/alsb/docs21/consolehelp/securityconfiguration.html http://e-docs.bea.com/alsb/docs25/consolehelp/securityconfiguration.html 2.3.4. BEA AquaLogic Service Bus 2.1 User Guide: Securing Inbound and Outbound Messages http://e-docs.bea.com/alsb/docs21/userguide/security.html BEA AquaLogic Service Bus 2.5 Security Guide http://e-docs.bea.com/alsb/docs25/security/ 2.3.5. BEA Dev2Dev Code-Sample ID S183: Outbound Transport Security Sample https://codesamples.projects.dev2dev.bea.com/servlets/scarab/remcurreport/true/template/viewissue.vm/id/s 183/nbrresults/184 2.3.6. Programming BEA WebLogic Security: Using SSL Authentication in Java Clients http://e-docs.bea.com/wls/docs91/security/ssl_client.html http://e-docs.bea.com/wls/docs92/security/ssl_client.html For information on how to configure BEA WebLogic Server for two-way SSL authentication, see the Configuring SSL section in Securing WebLogic Server. Follow the links to the sections that describe the different ways two-way SSL authentication can be implemented in BEAWebLogic Server. Two-Way SSL Authentication with JNDI Using Two-Way SSL Authentication Between BEA WebLogic Server Instances Using Two-Way SSL Authentication with Servlets 2.3.7. OpenSSL Documents http://www.openssl.org/docs/ 2.3.8. Grinder Framework http://sourceforge.net/projects/grinder/ 2.3.9. Firewall Overview http://www.seifried.org/security/network/firewall/20011025-firewall-overview.html 6

2.3.10. SSL and TLS: Designing and Building Secure Systems, by Eric Rescorla, Addison-Wesley, 2001 http://www.rtfm.com/sslbook/ 2.3.11. Setting up a test network http://www.networkworld.com/columnists/2004/0712nutter.html 2.3.12. Firewalls and Internet Security: Repelling the Wily Hacker, Second Edition; William R. Cheswick, Steven M. Bellovin, and Aviel D. Rubin http://www.wilyhacker.com/ 3. Problem definition: How to establish two-way inbound and two-way outbound SSL authentication between client, BEA AquaLogic Service Bus, and business service separated by firewalls The goal is to establish inbound two-way and outbound two-way SSL authentication, each through the firewall, for the scenario in which: A client sends an HTTPS request to a BEA AquaLogic Service Bus proxy service. A BEA AquaLogic Service Bus proxy service routes the request to a BEA WebLogic Server 9.x-hosted business service over HTTPS. A business service receives a request and sends an HTTPS response to the client via the BEA AquaLogic Service Bus proxy service. 4. Deployment architecture, set-up, and configuration In general, the details of the installation and configuration depend on the operating system, the number of machines, and the desired cluster sizes of BEA WebLogic Server domains. Typically in a production environment, the client, the BEA AquaLogic Service Bus proxy service, and the business service are hosted on separate machines. In addition, each BEA WebLogic Server cluster node is hosted on a separate hardware system. The following section describes a simplified example of how to set up and configure request/response messaging between a client, a BEA AquaLogic Service Bus proxy service, and a business service for testing. The example uses minimum hardware consisting of two systems, each running a Microsoft Windows operating system. The first machine hosts the client and business service. The second machine hosts the BEA AquaLogic Service Bus proxy service. The first and second machines are separated by two firewalls, with a lab network between firewalls. The lab network simulates a public network like the Internet. This is a simplification of a typical set-up in which each 7

company hosting the client, the BEA AquaLogic Service Bus proxy service, or the business service has two firewalls with a DMZ in between. The example outlines common configuration steps, which can be extrapolated to suit production requirements. 4.1. Deployment architecture example Figure 4.1.1 Client, BEA AquaLogic Service Bus proxy service, and business service deployment configuration. The DMZ is not shown. Server 1 Client Domain Client Application NIC 1 (internal) https://<client internal IP>:7002 NIC 2 (external) https://<client external IP>:7002 Firewall Lab Network Firewall Server 2 AquaLogic Service Bus Server Domain Proxy Service Endpoint NIC 1 (internal) https://<aqualogic Service Bus internal IP>:7002 NIC 2 (external) https://<aqualogic Service Bus external IP>:7002 Firewall Lab Network Firewall Server 3 BEA WebLogic Server Business Service Domain Business Application NIC 1 (internal) https://< Business Service internal IP>:7002 NIC 2 (external) https://< Business Service external IP>:7002 8

Figure 4.1.2 shows the network set-up for a firewall/dmz BEA AquaLogic Service Bus test. The following characteristics describe the set-up: The firewall between FW-B and WLI Lab Network is a hardware firewall: Cisco PIX 506. The firewall between FW-E and WLI Lab Network is a software firewall: Checkpoint Firewall/1. Solid lines represent the paths followed by the messages that are sent from FW-B. Dotted lines represent the paths followed by the messages sent from FW-E. Ports 7001 and 7002 are opened on the external IPs for the internal boxes. The client and BEA WebLogic Server business service domain are hosted on FW-B. The BEA AquaLogic Service Bus domain is hosted on FW-B. Figure 4.1.2 BEA AquaLogic Service Bus DMZ/firewall test hardware network set-up. Lab Network xxx.xx.x.x (Simulating Internet) Cisco PIX 506 NIC 2 (external) IP: xxx.xx.x.xxx NIC 1 (internal) IP: xx.x.x.x < CheckPoint host machine name> Firewall: CheckPoint FW/1 NIC 2 (external) IP: xxx.xx.x.xxx NIC 1 (internal) IP:xx.x.x.x 5 Port Switch for xx.x.x.x/xx 5 Port Switch for xx.x.x.x/xx <host machine name 'fw-b'> NIC 2 (external) IP: xxx.xx.x.xxx NIC 1 (internal) IP: xx.x.x.x Ports 7001, 7002, 5900 open <host machine name 'fw-e'> NIC 2 (external) IP: xxx.xx.x.xxx NIC 1 (internal) IP: xx.x.x.x Ports 7001, 7002, 5900 open HTTPS Client Business Service BEA AquaLogic Service Bus Proxy Service 9

A typical set-up includes two firewalls (Figure 4.1.3), one in front of the public servers, and one between the public servers and the internal LAN. This set-up is typically referred to as the DMZ, because the zone between the two firewalls is un-trusted and heavily restricted. Additionally you can set up application proxies (such as www and FTP proxies), then block outbound access from the internal LAN on the exterior firewall and force all clients to go through your application proxies (which can have anti-virus capabilities, for example). The DMZ should be a quiet zone; that is, any hostile packets trying to enter it (from the Internet, or the internal LAN) should be blocked at either firewall, increasing the effectiveness of any intrusion-detection systems. (This results in fewer false positives.) (Firewall overview by Kurt Seifried, http://www.macrollc.com/faqs/faq-firewall_overview_seifried.htm.) 4.2. Inbound and outbound two-way SSL authentication configuration 4.2.1. Two-way SSL authentication In this scenario, two-way SSL certificate authentication is used between the client, the proxy service, and the business service. Each of them can be deployed on its own BEA WebLogic Server. If this is the case, each BEA WebLogic Server sends a digital certificate to the requesting client. The client examines the digital certificate to ensure that it is authentic, has not expired, and matches the BEA WebLogic Server instance that presented it. The requesting client also presents a digital certificate to BEA WebLogic Server. Requesting clients must present digital certificates from a specified set of certificate authorities. BEA WebLogic Server accepts only digital certificates that have root certificates from the specified trusted certificate authorities. 4.2.2. BEA WebLogic Server configuration of one-way and two-way SSL By default, BEA WebLogic Server is configured for one-way SSL authentication; however, the SSL port is disabled. You can enable an SSL port using the BEA WebLogic Server Administration Console. To use two-way SSL between a client and a server: Enable the SSL port on the server. Configure identity for the server and trust for the client. Figure 4.1.3 LAN set-up. Firewall Internal LAN Internet Firewall Public Server 10 Firewall Internet

Enable two-way SSL on the server. Configure trust for the server and identity for the server. The peer certificate chain needs to contain a certificate from the Certificate Authority (CA) that issued the peer s identity certificate. This CA certificate does not need to be the root CA certificate. To acquire a digital certificate for your server, you generate a public key, a private key, and a Certificate Signature Request (CSR), which contains your public key. You send the CSR to a Certificate Authority and follow their procedures for obtaining a signed digital certificate. When you have your private keys, digital certificates, and the additional trusted CA certificates that you need, you must store them so that BEA WebLogic Server can use them to verify identity. Store private keys and certificates in keystores. Note: For purposes of backwards compatibility, you may also store your private keys and certificates in files. For more information about private key, public key, and certificate requirements and procedures, see the Configuring SSL and BEA Securing WebLogic Server section in Security for BEA WebLogic Server 9.1, Chapter 2.3: References and related documents. To use SSL when connecting to a BEA WebLogic Server application with your browser, you simply specify HTTPS and the secure port (say, port number 7002) in the URL. For example: https://<hostname>:7002/exampleswebapp/snoopservlet.jsp where <hostname> is the name of the system hosting the Web application. 4.2.3. About PKI credential mappers A PKI credential mapper maps key pairs (a public key and a private key) to an alias. The BEA WebLogic Server PKICredentialMapper stores the key alias and key password (for key pairs) in the embedded LDAP. Key passwords are encrypted before they are stored on LDAP. The PKICredentialMapper does not store the keys; they are stored in a keystore. The PKICredentialMapper is configured with the location of the keystore and the keystore password. Note: The target BEA WebLogic Server not only requires a trusted and valid certificate, but allows the SSL connection only if it can authenticate a user ID stored somewhere in the x500 Distinguished Name in the client certificate. For additional information see: Securing BEA WebLogic Server by Configuring SSL: http://e-docs.bea.com/wls/docs91/secmanage/ssl.html#configuressl Administration Console Online Help: Configure Two-Way SSL http://e-docs.bea.com/wls/docs91/consolehelp/taskhelp/security/configuretwowayssl.html Configure Keystores http://e-docs.bea.com/wls/docs91/consolehelp/taskhelp/security/configurekeystoresandssl.html Configuring Identity and Trust http://e-docs.bea.com/wls/docs91/secmanage/identity_trust.html 11

4.2.4. Configuration steps Complete the following steps to configure your system: 1. Install BEA WebLogic Server on each of the participating machines. Optionally, configure server domains in production mode connected to an Oracle database. 2. Configure keystores for all participating domains using the BEA WebLogic Server Administration Console. 3. Populate the keystores with server keys and certificates using command line tools. 4. Import each server s certificate as a trusted certificate into the other server s keystore using command line tools. 5. Configure the BEA WebLogic Server that hosts the BEA AquaLogic Service Bus proxy service to support two-way SSL using the BEA WebLogic Server Administration Console. 6. Configure the BEA WebLogic Server that hosts business services to support two-way SSL using the BEA WebLogic Server Administration Console. 7. Add the user ID from the BEA AquaLogic Service Bus server certificate to the business service server LDAP for business service using the BEA WebLogic Server Administration Console. 8. Add the user ID from the client (or client server) certificate to the BEA AquaLogic Service Bus server LDAP system for BEA AquaLogic Service Bus using the BEA WebLogic Server Administration Console. 9. Configure a PKI credential mapper for BEA AquaLogic Service Bus using the BEA WebLogic Server Administration Console. 10. Configure a proxy service provider using the BEA AquaLogic Service Bus Console. 11. Associate PKI credentials (SSL client key-pair) with the proxy service provider using the Credentials section of the Security Configuration module using the BEA AquaLogic Service Bus Console. 12. Register a business service definition, which uses the HTTPS transport protocol with client certificate authentication in BEA AquaLogic Service Bus using the BEA AquaLogic Service Bus Console. 13. Configure a proxy service to route a message to the business service using the BEA AquaLogic Service Bus Console. 12

5. Testing 5.1. Business service A business service can be implemented as a servlet like EchoServlet.java shown in the following listing. To compile the code, the weblogic.jar and xbean.jar from the server library must be on your classpath. EchoServlet.java source: import com.bea.xbean.common.ioutil; import javax.servlet.http.httpservletrequest; import javax.servlet.http.httpservlet; import javax.servlet.http.httpservletresponse; import javax.servlet.servletexception; import javax.servlet.servletoutputstream; import javax.servlet.servletinputstream; import java.io.ioexception; import java.io.bytearrayoutputstream; import java.util.enumeration; /** * Created by IntelliJ IDEA. * Author: Gregory Haardt * Date: Jun 1, 2004 * Time: 4:08:06 PM * To change this template use Options File Templates. */ public class EchoServlet extends HttpServlet { public static final long serialversionuid = 1L; public void service(httpservletrequest httpservletrequest, HttpServletResponse httpservletresponse) { throws IOException, ServletException System.out.println( Entered the echo servlet ); System.out.println( EchoServlet: Content-Type = + httpservletrequest.getcontenttype()); /** optionally wait for the specified time interval */ 13

String waittime = httpservletrequest.getparameter( wait ); if (waittime!= null && waittime.length() > 0) { try { Thread.sleep(Integer.parseInt(waitTime) * 1000); } catch (Exception e) { e.printstacktrace(); } } String tothrow = httpservletrequest.getparameter( throw ); if (tothrow!= null && tothrow.length() > 0) { throw new ServletException( Throwing exception for testing purposes ); } // Copy all request headers to response (although some may not be relevant!) Enumeration headers = httpservletrequest.getheadernames(); while (headers.hasmoreelements()) { String o = (String) headers.nextelement(); httpservletresponse.addheader(o, httpservletrequest.getheader(o)); } ServletInputStream inputstream = httpservletrequest.getinputstream(); ServletOutputStream outputstream = httpservletresponse.getoutputstream(); boolean usestreaming = true; if (usestreaming) { System.out.print( EchoServlet: message = ); byte[] buf = new byte[1024]; int totalcount = 0; while (true) { int bytecount = inputstream.read(buf, 0, buf.length); if (bytecount == -1) break; System.out.print(new String(buf, 0, bytecount)); 14

outputstream.write(buf, 0, bytecount); totalcount += bytecount; } httpservletresponse.setcontentlength(totalcount); System.out.println(); } else { // Read entire InputStream into byte array ByteArrayOutputStream out = new ByteArrayOutputStream(1024); IOUtil.copyCompletely(inputStream, out); // Dump message to be echoed to console System.out.println( EchoServlet: message = + out); // Set content-length and dump response httpservletresponse.setcontentlength(out.size()); out.writeto(outputstream); } String tothrow2 = httpservletrequest.getparameter( throw2 ); if (tothrow2!= null && tothrow2.length() > 0) { throw new ServletException( Throwing exception for testing purposes ); } httpservletresponse.setstatus(httpservletresponse.sc_ok); } } Code developed by senior software engineer Gregory Haardt To deploy EchoServlet on BEA WebLogic Server, you must have a Web deployment descriptor web.xml and a BEA WebLogic deployment descriptor weblogic.xml. Web.xml source code: <?xml version= 1.0?> <!DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd > <web-app> <servlet> <servlet-name> EchoServlet </servlet-name> 15

<display-name> EchoServlet </display-name> <servlet-class> EchoServlet </servlet-class> </servlet> <servlet-mapping> <servlet-name>echoservlet</servlet-name> <url-pattern>/echo</url-pattern> </servlet-mapping> <security-constraint> <web-resource-collection> <web-resource-name>allendpoints</web-resource-name> <url-pattern>/*</url-pattern> </web-resource-collection> <auth-constraint> <description> These are the roles who have access to inbound HTTPs endpoints </description> <role-name> Admin </role-name> </auth-constraint> <user-data-constraint> <description>ssl required</description> <transport-guarantee>confidential</transport-guarantee> </user-data-constraint> </security-constraint> <login-config> <auth-method>client-cert</auth-method> </login-config> <security-role> <description> An administrator </description> <role-name> Admin </role-name> </security-role> </web-app> 16

weblogic.xml source code : <?xml version= 1.0 encoding= UTF-8?> <!DOCTYPE weblogic-web-app PUBLIC -//BEA Systems, Inc.//DTD Web Application 8.1//EN http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd > <weblogic-web-app> <security-role-assignment> <role-name>admin</role-name> <externally-defined/> </security-role-assignment> </weblogic-web-app> Create a WAR file ExternalServiceClientCert.war using the JAR tool, using the following command: jar c[v0m]f jarfile [-C dir] inputfiles [-Joption] For example: <your directory>jar cvf ExternalServiceClientCert.war * After starting BEA WebLogic Server, choose the Deployments option from the main menu and deploy the ExternalServiceClientCert.war. 5.2. Proxy service Configure the proxy and business services using BEA AquaLogic Service Bus Console. The proxy service definition relies on configuration of a proxy service provider. You must associate PKI credentials (SSL client keypair) with the proxy service provider using the Credentials section of the Security Configuration module. After you registered a business service definition, which uses the HTTPS transport protocol with client certificate authentication, configure a proxy service to route a message to the business service. 5.3. Client For testing this scenario, the Grinder open-source development test framework was used. It is available for download at the following URL: http://sourceforge.net/projects/grinder/ 1. Download the grinder-3.0-beta27.zip or later release. 2. To run the Grinder client you need three files: grinder.properties, https-clientcert.py, and an input XML file. 17

The following listing is an example of a grinder.properties file: # Example grinder.properties # grinder.jvm.arguments=-dpython.home=d:/jython/jython-2.1 grinder.processes=1 grinder.threads=1 grinder.runs=1 grinder.useconsole=false grinder.logdirectory=log grinder.numberofoldlogs=1 #grinder.initialsleeptime=500 #grinder.sleeptimefactor=0.01 #grinder.sleeptimevariation=0.005 grinder.script=https-clientcert.py The following listing is an example of an https-clientcert.py file: # A simple example using the HTTP plug-in that shows the retrieval of a # single page via HTTP. The resulting page is written to a file. # More complex HTTP scripts are best created with the TCPProxy. from net.grinder.script.grinder import grinder from net.grinder.script import Test from net.grinder.plugin.http import HTTPRequest from HTTPClient import HTTPResponse from HTTPClient import HTTPConnection from HTTPClient import NVPair from net.grinder.plugin.http import HTTPPluginControl import jarray test1 = Test(1, Request resource ) request1 = test1.wrap(httprequest()) class TestRunner: def call (self): 18

#Set the client cert to be send grinder.sslcontrol.setkeystorefile( TestClientKeystore.jks, password ) file = open(./inputs/sslinputstring.xml, r ) contents = file.read() print ---------request--------------- print contents print ------------------------ file.close() request1.addheader( Content-type, text/xml ) result = request1.post( https://172.16.1.225:7002/clientcertps,contents) print ---------response--------------- print result.gettext() print ------------------------ The third file is an input XML file. It must be located in the INPUTS directory. The following listing is an example of an input XML file in the INPUTS directory (/INPUTS/sslInputString.xml): <?xml version= 1.0 encoding= utf-8?> <soap:envelope xmlns:soap= http://schemas.xmlsoap.org/soap/envelope/ xmlns:xsi= http://www.w3.org/2001/xmlschema-instance > <soap:body> <Result xmlns= urn:acme-org:results > <Job> <contacts> <contact>j Doe</contact> <contact>j Q Public</contact> </contacts> </Job> </Result> </soap:body> </soap:envelope> 19

Set up the classpath in a process environment by executing a script like setenvbea.cmd in the cmd shell: @echo off set BEA_HOME=D:\wlw\src_15004jr\bea set DOMAIN_HOME=D:\wlw\src_15004jr\domains\alsb_client_domain set WEBLOGIC_HOME=%BEA_HOME%\weblogic90 set BEA_JDK=D:\wlw\dev\src\build\jrockit-jdk1.5.0_04 set OLDPATH=%PATH% set PATH=%WEBLOGIC_HOME%\server\bin set PATH=%PATH%;%BEA_JDK%\bin set PATH=%PATH%;%OLDPATH% set CLASSPATH=.;%WEBLOGIC_HOME%\server\lib\weblogic.jar set WL_HOME= set ANT_HOME= set JAVA_HOME= set ANT_ARGS= 3. Start the Grinder client from the directory hosting your scripts: C:\bea\user_projects\domains\alsb_services_domain\ClientCert>java net.grinder.grinder The output is displayed in the shell window. It is similar to the following listing: 12/16/05 2:51:22 PM (agent): The Grinder 3.0-beta27 12/16/05 2:51:22 PM (agent): Worker process command line: java -classpath E:\Grinder3\grinder-3.0-beta27\lib\grinder.jar;.;E:\Grinder3\grinder-3.0- beta27\lib\jython.jar;c:\bea\jrockit90_150_04\lib\tools.jar;c:\bea\jrockit90_150_04\jre\lib\rt.jar; net.grinder.engine.process.grinderprocess 12/16/05 2:51:23 PM (agent): process fw-b-0 started 20

12/16/05 2:51:26 PM (process fw-b-0): starting threads ---------request--------------- <?xml version= 1.0 encoding= utf-8?> <soap:envelope xmlns:soap= http://schemas.xmlsoap.org/soap/envelope/ xmlns:xsi= http://www.w3.org/2001/xmlschema-instance > <soap:body> <Result xmlns= urn:acme-org:results > <Job> <contacts> <contact>j Doe</contact> <contact>j Q Public</contact> </contacts> </Job> </Result> </soap:body> </soap:envelope> ------------------------ ---------response--------------- <?xml version= 1.0 encoding= utf-8?> <soapenv:envelope xmlns:soapenv= http://schemas.xmlsoap.org/soap/envelope/ > <soapenv:header/> <soap:body xmlns:xsi= http://www.w3.org/2001/xmlschema-instance xmlns:soap= http://schemas.xmlsoap.org/soap/envelope/ > <Result xmlns= urn:acme-org:results > <Job> <contacts> <contact>j Doe</contact> <contact>j Q Public</contact> </contacts> </Job> </Result> </soap:body> </soapenv:envelope> ------------------------ 12/16/05 2:51:27 PM (process fw-b-0): finished 12/16/05 2:51:28 PM (agent): finished 21

4. Include the following setting in the setdomainenv.cmd (or setdomainenv.sh) to receive the full SSL debug stack: set EXTRA_JAVA_PROPERTIES=%EXTRA_JAVA_PROPERTIES% -Dssl.debug=true -Dweblogic.StdoutDebugEnabled=true -Dweblogic.security.SSL.verbose=true The inbound request is sent through the firewall using the reverse proxy service from the DMZ to the LAN/WAN behind the firewall. Specifically, the Grinder HTTPS client sends the request from the outside the firewall to the BEA AquaLogic Service Bus proxy service behind the firewall. The BEA AquaLogic Service Bus proxy service routes the request to the business service located outside the firewall. The conversation between BEA AquaLogic Service Bus and a server hosting the business services should complete successfully. Recall that we use inbound and outbound two-way SSL transport security. To validate the SSL handshake, examine the console windows of both the BEA AquaLogic Service Bus server and the BEA WebLogic Server that hosts the business services. Look for <HANDSHAKEMESSAGE: > entries to see how the SSL handshake was executed. Note that the BEA AquaLogic Service Bus server console window shows the business-services server certificate when it is received, and the business services console shows the client s certificate. In both console windows you will see alerts and exceptions that indicate the SSL connection was closed. These can be ignored if they are of Type: 0. The certificate record in the business services console log is similar to the following listing: <Dec 16, 2005 2:49:29 PM PST> <Debug> <SecuritySSL> <000000> <8025904 received HANDSHAKE> <Dec 16, 2005 2:49:29 PM PST> <Debug> <SecuritySSL> <000000> <HANDSHAKEMESSAGE:Certificate> <Dec 16, 2005 2:49:29 PM PST> <Debug> <SecuritySSL> <000000> <validationcallback: validateerr = 0> <Dec 16, 2005 2:49:29 PM PST> <Debug> <SecuritySSL> <000000> < cert[0] = Serial number: 116908534863041204781210221131467927454 Issuer:C=US, L=San Jose, O=BEA Systems, Inc., OU=DEV, CN=QuickSilver-TEST-CA Subject:C=US, L=San Jose, O=BEA Systems, Inc., OU=DEV, CN=QS-SERVER-TEST Not Valid Before:Sun Jul 18 00:00:00 PDT 2004 Not Valid After:Thu Oct 18 00:00:00 PDT 2007 Signature Algorithm:SHA1withRSA> <Dec 16, 2005 2:49:29 PM PST> <Debug> <SecuritySSL> <000000> < cert[1] = Serial number: 0 22

Issuer:C=US, L=San Jose, O=BEA Systems, Inc., OU=DEV, CN=QuickSilver-TEST-CA Subject:C=US, L=San Jose, O=BEA Systems, Inc., OU=DEV, CN=QuickSilver-TEST-CA Not Valid Before:Sat Jul 17 00:00:00 PDT 2004 Not Valid After:Tue Oct 17 00:00:00 PDT 2006 Signature Algorithm:SHA1withRSA> <Dec 16, 2005 2:49:29 PM PST> <Debug> <SecuritySSL> <000000> <weblogic user specified trustmanager validation status 0> The certificate record in the BEA AquaLogic Service Bus Console log looks similar to this: <Dec 16, 2005 2:44:11 PM PST> <Debug> <SecuritySSL> <000000> <17480322 received HANDSHAKE> <Dec 16, 2005 2:44:11 PM PST> <Debug> <SecuritySSL> <000000> <HANDSHAKEMESSAGE:Certificate> <Dec 16, 2005 2:44:11 PM PST> <Debug> <SecuritySSL> <000000> <validationcallback: validateerr = 0> <Dec 16, 2005 2:44:11 PM PST> <Debug> <SecuritySSL> <000000> < cert[0] = Serial number: 116908534863041204781210221131467927454 Issuer:C=US, L=San Jose, O=BEA Systems, Inc., OU=DEV, CN=QuickSilver-TEST-CA Subject:C=US, L=San Jose, O=BEA Systems, Inc., OU=DEV, CN=QS-SERVER-TEST Not Valid Before:Sun Jul 18 00:00:00 PDT 2004 Not Valid After:Thu Oct 18 00:00:00 PDT 2007 Signature Algorithm:SHA1withRSA> <Dec 16, 2005 2:44:11 PM PST> <Debug> <SecuritySSL> <000000> < cert[1] = Serial number: 0 Issuer:C=US, L=San Jose, O=BEA Systems, Inc., OU=DEV, CN=QuickSilver-TEST-CA Subject:C=US, L=San Jose, O=BEA Systems, Inc., OU=DEV, CN=QuickSilver-TEST-CA Not Valid Before:Sat Jul 17 00:00:00 PDT 2004 Not Valid After:Tue Oct 17 00:00:00 PDT 2006 Signature Algorithm:SHA1withRSA> <Dec 16, 2005 2:44:11 PM PST> <Debug> <SecuritySSL> <000000> <weblogic user specified trustmanager validation status 0> 23

6. Conclusion This white paper describes an example of the configuration of a client, a proxy service, and a business service communicating over firewalls and a DMZ, using inbound and outbound two-way SSL authentication. Specifically, a client generates inbound traffic to a BEA AquaLogic Service Bus proxy service over a secure transport-level connection using two-way SSL. The BEA AquaLogic Service Bus proxy service generates outbound traffic to business services over a secure transport-level connection using two-way SSL. It is presumed that the proxy and business services are hosted on BEA WebLogic Server 9.1 or 9.2. This is an example of how to configure such a system. The author would appreciate it if field engineers can send their descriptions of real-life use cases so that they can be reproduced and contribute to further understanding of these types of scenarios. If those configurations are significantly different from the one described in this paper, additional information can be appended to the paper. Please send your comments to alsb-wp@bea.com. 7. About BEA BEA Systems, Inc. (NASDAQ: BEAS) is a world leader in enterprise infrastructure software, delivering unified SOA platforms for business transformation and optimization. Customers depend on BEA Tuxedo, WebLogic, and AquaLogic product lines to help reduce IT complexity and leverage existing resources-for achieving a state of Business LiquidITy where enterprise assets are freed up to deliver maximum business value and grow new revenue streams. Find out more at bea.com. 8. Join the BEA community At BEA, we understand that developers need different kinds of resources than IT managers. And that architects face different challenges than executives. That s why we ve created four unique communities that give you exclusive access to a formidable group of your peers, to a world of shared thinking, and to the kind of meaningful information that can make you more effective and more competitive. To join one or more of the BEA communities, simply register online at bea.com/register. 24

BEA Systems, Inc. 2315 North First Street San Jose, CA 95131 +1.800.817.4232 +1.408.570.8000 bea.com CWP1441E0906-1A