Java Security Web Services Security (Overview) Lecture 9



Similar documents
This Working Paper provides an introduction to the web services security standards.

XML Signatures in an Enterprise Service Bus Environment

Securing Web Services From Encryption to a Web Service Security Infrastructure

Copyright 2012, Oracle and/or its affiliates. All rights reserved.

Angel Dichev RIG, SAP Labs

Securing Web Services with WS-Security

Contents at a Glance. 1 Introduction Basic Principles of IT Security Authentication and Authorization in

Network Security. Chapter 10. Application Layer Security: Web Services. Part I: Introduction to Web Services

Digital Signature Web Service Interface

17 March 2013 NIEM Web Services API Version 1.0 URI:

Web Services Security Using SOAP, WSDL and UDDI

Web Services Security: What s Required To Secure A Service-Oriented Architecture. An Oracle White Paper January 2008

<Insert Picture Here> Oracle Security Developer Tools (OSDT) August 2008

CICS Web Service Security. Anthony Papageorgiou IBM CICS Development March 13, 2012 Session: 10282

A Signing Proxy for Web Services Security. Dr. Ingo Melzer RIC/ED

Internationalization and Web Services

Service-Oriented Architectures

Server based signature service. Overview

ITS. Java WebService. ITS Data-Solutions Pvt Ltd BENEFITS OF ATTENDANCE:

Web Services Trust and XML Security Standards

Technik und Informatik. SOAP Security. Prof. Dr. Eric Dubuis Berner Fachhochschule Biel. Version April 11, 2012

Trusting XBRL: Using the Liberty Web Services Framework to Secure and Authenticate XBRL Documents

Enabling SSL and Client Certificates on the SAP J2EE Engine

WEB SERVICES SECURITY

NIST s Guide to Secure Web Services

DocuSign Information Guide. Single Sign On Functionality. Overview. Table of Contents

Secure Authentication and Session. State Management for Web Services

Java Web Services Training

CS 356 Lecture 28 Internet Authentication. Spring 2013

Developing Java Web Services

AquaLogic Service Bus

Representation of E-documents in AIDA Project

JVA-561. Developing SOAP Web Services in Java

JVA-122. Secure Java Web Development

02267: Software Development of Web Services

Szolgáltatásorientált rendszerintegráció. WS-* standards

Digital Signing Specification

Web Services Advanced Topics

Biometric Single Sign-on using SAML

Principles and Foundations of Web Services: An Holistic View (Technologies, Business Drivers, Models, Architectures and Standards)

WebService Security. A guide to set up highly secured client-server communications using WS-Security extensions to the SOAP protocol

Using mobile phones to access Web Services in a secure way. Dan Marinescu

The Global Justice Reference Architecture (JRA) Web Services Service Interaction Profile

WEB SERVICES. Revised 9/29/2015

Enterprise Access Control Patterns For REST and Web APIs

Improving performance for security enabled web services. - Dr. Colm Ó héigeartaigh

Introduction to Service-Oriented Architecture for Business Analysts

Apigee Gateway Specifications

Securing Web Services With SAML

Increasing IT flexibility with IBM WebSphere ESB software.

An Oracle White Paper Dec Oracle Access Management Security Token Service

Interoperable Provisioning in a Distributed World

Secure Identity Propagation Using WS- Trust, SAML2, and WS-Security 12 Apr 2011 IBM Impact

Software Requirement Specification Web Services Security

SAML and OAUTH comparison

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

Oracle Application Server 10g Web Services Frequently Asked Questions Oct, 2006

Service Virtualization: Managing Change in a Service-Oriented Architecture

Creating Web Services in NetBeans

Creating a Secure Web Service In Informatica Data Services

Accelerate your SOA Projects through Service Simulation

EUR-Lex 2012 Data Extraction using Web Services

Introduction into Web Services (WS)

OIO Web SSO Profile V2.0.5

Web Service Testing. SOAP-based Web Services. Software Quality Assurance Telerik Software Academy

Q Lately I've been hearing a lot about WS-Security. What is it, and how is it different from other security standards?

Web Services Security: OpenSSO and Access Management for SOA. Sang Shin Java Technology Evangelist Sun Microsystems, Inc. javapassion.

igovt logon service Context Mapping Service (icms) Messaging Specification Release 9.6

STUDY ON IMPROVING WEB SECURITY USING SAML TOKEN

Integration of Hotel Property Management Systems (HPMS) with Global Internet Reservation Systems

PARTNER INTEGRATION GUIDE. Edition 1.0

OpenLDAP Oracle Enterprise Gateway Integration Guide

Web services can convert your existing applications into web applications.

What is a Web service?

Easy CramBible Lab DEMO ONLY VERSION Test284,IBM WbS.DataPower SOA Appliances, Firmware V3.6.0

Introduction to Service Oriented Architectures (SOA)

WebSphere DataPower Release FIPS and NIST SP a support.

BUSINESS PROCESS AND EBXML - WEB SERVICES INTEGRATION PLATFORM, REQUIREMENTS, ARCHITECTURES, SECURITY

JavaPolis 2004 Middleware and Web Services Security

Run-time Service Oriented Architecture (SOA) V 0.1

Secure web transactions system

CA SOA Security Manager

SAML Implementation Guidelines

Web Security Considerations

OpenID Connect 1.0 for Enterprise

Web Services and Service Oriented Architectures. Thomas Soddemann, RZG

Transcription:

Java Security Web Services Security (Overview) Lecture 9

Java 2 Cryptography Java provides API + SPI for crypto functions Java Cryptography Architecture Security related core classes Access control and cryptography Java Cryptography Extension Other core classes Message digest, digital signatures, certificate management Key exchange, MAC

JCA + JCE Engine Abstract cryptographic service: E.g., message digest, digital signatures To provide cryptographic operations To generate or supply the crypto material To generate and manage data objects (certificates or keys keystores) Use instances of engine class for crypto operations Algorithm Implementation of an engine: Eg. MD5 for MessageDigest Provider (set of) packages that supply concrete implementation of a subset of the cryptographic services (DS, MD, etc.)

JCA + JCE Principles Provider based architecture Vendors can register implementations of algorithms Providers can be configured declaratively so the application code does not need to change Allows different implementations to be found at runtime Engine Class SPI class Implementations expose the same API Implementation independence Algorithm Independence

JCA + JCE Principles New algorithms can be easily plugged in Has to be compliant with the MessageDigest API Various implementation can work with one another Use one another s keys Verify one another s messages Implementation interoperability Algorithm Extensibility

Providers SPI is Key to pluggability, extensibility and module independence It is a set of Java-language interfaces and abstract classes for cryptographic services A Provider is a pluggable modules Provides concrete implementations of some SPI methods java.security and javax.crypto and their subpackages contain many SPI interfaces that JCA and JCE providers can implement

Providers

Engine and SPI Engine classes are the interfaces between the user code and the implementations Implementations are found at runtime

Engine and SPI The engine class calls the SPI class methods SPI class method names begins with engine Implementation of abstract SPI done by providers

Enterprise Security for Web Services XML Simplicity and flexibility Facilitates B2B messaging Security is a big concern Structured semantics and schema-driven nature XML security technologies are available Encryption Elements, sections Digital signatures All or parts by one or more entities Access control

Web Service Web service Is a an interface that describes a collection of network-accessible operations based on open internet standards Potential to enable application integration at a higher level of the protocol stack based on Web Services standards XML Simple Object Access Protocol Web Services Description Lanaguage (WSDL) Unversal Description, Discovery and Itnegration

SOAP Simple, lightweight and extensible XMLbased mechanism for exchanging structured data between network applications Consists of: An envelop What is in the message and who should deal with it A set of coding rules Serialization mechanism that be used to exchange instance of application defined data types

SOAP It supports modular architecture Allows defining the following in separate documents WS Addressing Specification (WS-Addressing) WS Security Specification (WS-Security) A SOAP envelope is defined in Envelope XML element Consists of two parts: Header: adds features to the messages Meta information can be added to the message E.g., transaction IDs, message routing information, message security Body: mechanism for exchanging information

Security Technologies XML Signature Validation of the messages and non-repudiation SAML AuthM + Security Srvices ML Authentication + Authorization profile information Common language for sharing of security services between companies for B2B/B2C transacrtions XML Encryption Encrypting of XML fragments WS-Security Set of SOAP extensions that can be used when building WS to implement integrity and confidentiality

XML Signature IETF and W3C standard for digitally signing all or some part of the XML document XML Signature Is itself a piece of XML defined by a schema Contain references URIs to what is being signed URIs within the document or external to it A singled XML document may have multiple signatures

XML Signature Structure XML Signature contains four major items: A set of pointers (references) to things to be signed The actual signature (Optional) The key (or a way to look up the key) for verifying the signature (Optional) An Object tag that can contain miscellaneous items not included in the first three items <Signature ID?> <SignedInfo> (CanonicalizationMethod) (SignatureMethod) (<Reference (URI=)? > (Transforms)? (DigestMethod) (DigestValue) </Reference>)+ </SignedInfo> (SignatureValue) (KeyInfo)? (Object ID?)* </Signature> <Signature xmlns="http://www.w3.org/2000/09/xmldsig#"> <SignedInfo> <Reference URI="http://www.foo.com/secureDocument.html" /> </SignedInfo> <SignatureValue>...</SignatureValue> <KeyInfo>... </KeyInfo> </Signature>

XML Signature: Enveloping Signature <Signature xmlns="http://www.w3.org/2000/09/xmldsig#"> <SignedInfo> <Reference URI="#111" /> </SignedInfo> <SignatureValue>...</SignatureValue> <KeyInfo>...</KeyInfo> <Object> <SignedItem id="111">stuff to be signed</signeditem> </Object> </Signature>

XML Signature: Enveloped Signature <PurchaseOrder id="po1"> <SKU>125356</SKU> <Quantity>17</Quantity> <Signature xmlns="http://www.w3.org/2000/09/xmldsig#"> <SignedInfo> <Reference URI="#po1" /> </SignedInfo> <SignatureValue>...</SignatureValue> <KeyInfo>...</KeyInfo> </Signature> </PurchaseOrder> Parent element

XML Signature: Detached Signature <PurchaseOrderDocument> <PurchaseOrder id="po1"> <SKU>12366</SKU> <Quantity>17</Quantity> </PurchaseOrder> <Signature xmlns= "http://www.w3.org/2000/09/xmldsig#"> <SignedInfo> <Reference URI="#po1" /> </SignedInfo> <SignatureValue>...</SignatureValue> <KeyInfo>...</KeyInfo> </Signature> </PurchaseOrderDocument>

XML Signature: Detached Signature Can also reference external source <Signature xmlns= "http://www.w3.org/2000/09/xmldsig#"> <SignedInfo> <Reference URI= "http://www.foo.com/picture.jpg" /> </SignedInfo> <SignatureValue>...</SignatureValue> <KeyInfo>...</KeyInfo> </Signature>

XML Encryption Structure <EncryptedData Id? Type? MimeType? Encoding?> <EncryptionMethod/>? <ds:keyinfo> <EncryptedKey>? <AgreementMethod>? <ds:keyname>? <ds:retrievalmethod>? <ds:*>? </ds:keyinfo>? <CipherData> <CipherValue>? <CipherReference URI?>? </CipherData> <EncryptionProperties>? </EncryptedData> - Could encompass an entire document of other XML structure (similar to Enveloping structure - Could contain a pointer to a detached resource

XML Encryption: Example <Employee> <Name>Dave Remy</Name> <SocialSecurityNumber> <EncryptedData Type= "http://www.w3.org/2000/09/xmldsig#content"> <EncryptionMethod Algorithm="..."> <CipherData><CipherValue>...</CipherValue> </CipherData> </EncryptedData> </SocialSecurityNumber> <Salary> <EncryptedData Type= "http://www.w3.org/2000/09/xmldsig#content"> <EncryptionMethod Algorithm="..."> <CipherData><CipherValue>...</CipherValue> </CipherData> </EncryptedData> </Salary> </Employee>

XML Encryption: Example <Employee> <Name>Dave Remy</Name> <SocialSecurityNumber> <EncryptedData id="socsecnum" Type="http://www.w3.org/2000/09/ xmldsig#content"> <EncryptionMethod Algorithm="..." /> <CipherData><CipherValue>...</CipherValue></CipherData> </EncryptedData> </SocialSecurityNumber> <Salary> <EncryptedData id="salary" Type="http://www.w3.org/2000/09/ xmldsig#content"> <EncryptionMethod Algorithm="..."> <CipherData><CipherValue>...</CipherValue></CipherData> </EncryptedData> </Salary> <EncryptedKey> <EncryptionMethod Algorithm="..." /> <CipherData> <CipherValue>...</CipherValue> </CipherData> <ReferenceList> <DataReference URI="#socsecnum" /> <DataReference URI="#salary" /> </ReferenceList> </EncryptedKey> </Employee>

SAML Enables portable identities and the assertions that these identities want to make Assertion: authentication; authorization SAML is important for WS is a standard XML format all normal XML tools apply to SAML Includes a standard message exchange protocol Specifies the rules for how it is transported making interoperability explicit at the specification level Expression of security in the form of assertions about subjects (different from Certification authority based approach) facilitated Single-Sign ON

SAML - scenario Federated identity

SAML Defines three types of assertions Authentication States that a particular auth. authority has authenticated the subject Using a particular process At a particular time (+ validity) Authorization States that a particular authority has granted/denied permissions on particular resource (+time) Attributes Provides qualifying information about either an authentication or authorization assertion

SAML how it works Three XML based mechanisms and their relationship XML schema + definition Rules on using assertions

SAML Example <saml:assertion> MajorVersion="1" MinorVersion="0" AssertionID="192.168.0.1.12345" Issuer="Company.com" IssueInstant="2004-01-21T10:02:00Z"> <saml:conditions> NotBefore="2004-01-21T10:02:00Z" NotAfter="2004-01-21T10:09:00Z" /> <saml:authenticationstatement> AuthenticationMethod="password" AuthenticationInstant="2004-01-21T10:02:00Z"> <saml:subject> <saml:nameidentifier SecurityDomain="Company.com" Name="jothy" /> </saml:subject> </saml:authenticationstatement> </saml:assertion>

SAML protocol SAML assertions are sent to the authentication and authorization authorities

SAML Authorization/Attribute Assertions <saml:assertion...> <saml:attributestatement> <saml:subject>...</saml:subject> <saml:attribute AttributeName="PaidStatus" AttributeNamespace="http://smithco.com"> <saml:attributevalue> PaidUp </saml:attributevalue> </saml:attribute> <saml:attribute AttributeName="CreditLimit" AttributeNamespace="http://smithco.com"> <saml:attributevalue xsi:type="my:type"> <my:amount currency="usd">500.00 </my:amount> </saml:attributevalue> </saml:attribute> </saml:attributestatement> </saml:assertion> <saml:assertion...> <saml:authorizationstatement Decision="Permit" Resource="http://jonesco.com/doit.cgi"> <saml:subject>...</saml:subject> <saml:action Namespace= "urn:oasis:names:tc:saml:1.0:action:rwedc">execute </saml:action> </saml:authorizationstatement> </saml:assertion>

SAML Architecture

SAML Binding Requires SOAP over HTTP as one binding SOAP Binding SAML information is contained inside the SOAP SAML Profile Describes how SAML assertions are embedded into and extracted from a framework/protocol Browser profile of SAML SAML profile SOAP WS-Security

WS-Security Focuses on applying on applying existing security technologies to SOAP message X.509 certificates SAML assertions XML Signatures XML Encryption GOAL: Secure the SOAP No matter where it goes No matter how long it lives

HTTP Transport Security Versus Message Security HTTP Transport Security Authentication at the time secure pipe is created Confidentiality/Integrity in the pipe only

HTTP-TS Pros and Cons Pros Mature: Tried and true Support: Supported by most servers and clients Understood: Understood by most system administrators Simpler: Generally simpler than message-level security alternatives Cons Point to Point: Messages are in the clear after reaching SSL endpoint Waypoint visibility: Cannot have partial visibility into the message Granularity: Cannot have different security for messages in and messages out Transport dependent: Applies only to HTTP

Message Security Pros and Cons Pros Persistent: Allows the message to be selfprotecting Selective: Portions of the message can be secured to different parties Flexible: Different security policy can be applied to request and response - Transport independent Cons Immature: standard, tools Complex: encompasses many other standards including XML Encryption, XML Signature, X.509 certificates, and many more

Web Services Security Stack