Real Single Sign-on for web applications Holger Zobel JavaZone 2005.

Slides:



Advertisements
Similar presentations
4 Copyright © 2005, Oracle. All rights reserved. Creating the Web Tier: Servlets.
Advertisements

Windows 2000 Security --Kerberos COSC513 Project Sihua Xu June 13, 2014.
Citrix Secure Gateway v1.1 Technical Presentation August 2002 Technical Presentation August 2002.
Servlets, JSP and JavaBeans Joshua Scotton.  Getting Started  Servlets  JSP  JavaBeans  MVC  Conclusion.
JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.
Cookie in a servlet. Cookies are small bits of textual information that a Web server sends to a browser and that the browser returns unchanged when visiting.
Forms Authentication, Users, Roles, Membership Ventsislav Popov Crossroad Ltd.
1 Servlets Based on Notes by Dave Hollinger & Ethan Cerami Also, the Online Java Tutorial by Sun.
Java Server Pages (JSP)
 2002 Prentice Hall. All rights reserved. Chapter 9: Servlets Outline 9.1 Introduction 9.2 Servlet Overview and Architecture Interface Servlet and.
Liang, Introduction to Java Programming, Sixth Edition, (c) 2005 Pearson Education, Inc. All rights reserved Chapter 34 Servlets.
Using Internet Information Server And Microsoft ® Internet Explorer To Implement Security On The Intranet HTTP.
Blackboard Building Blocks Authentication Overview Tuesday, June 30, 2015 Tom Joyce, Product Manager, Platform Architecture & Database.
Introduction to Servlet & JSP
Chapter 4 Servlets Concept of Servlets (What, Why, and How) Servlet API Third-party tools to run servlets Examples of Using Servlets HTML tag with GET.
Servlets Compiled by Dr. Billy B. L. Lim. Servlets Servlets are Java programs which are invoked to service client requests on a Web server. Servlets extend.
Gayle J Yaverbaum, PhD Professor of Information Systems Penn State Harrisburg.
Internet Information Server 6.0. Overview  What’s New in IIS 6.0?  Built-in Accounts and IIS 6.0  IIS Pass-Through Authentication  Securing Web Traffic.
Edwin Sarmiento Microsoft MVP – Windows Server System Senior Systems Engineer/Database Administrator Fujitsu Asia Pte Ltd
Ins and Outs of Authenticating Users Requests to IIS 6.0 and ASP.NET Chris Adams Program Manager IIS Product Unit Microsoft Corporation.
Understanding Integrated Authentication in IIS Chris Adams IIS Supportability Lead Microsoft Corp.
Guide to Operating System Security Chapter 9 Web, Remote Access, and VPN Security.
Web technologies and programming cse hypermedia and multimedia technology Fanis Tsandilas April 3, 2007.
Configuring a Web Server. Overview Overview of IIS Preparing for an IIS Installation Installing IIS Configuring a Web Site Administering IIS Troubleshooting.
Session 11: Security with ASP.NET
MCSE Guide to Microsoft Exchange Server 2003 Administration Chapter Four Configuring Outlook and Outlook Web Access.
Copyright 2000 eMation SECURITY - Controlling Data Access with
Enterprise Identity Steve Plank – Microsoft Ivor Bright – Charteris Dave Nesbitt – Oxford Computer Group.
SUSE Linux Enterprise Desktop Administration Chapter 12 Administer Printing.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 Securing a Microsoft ASP.NET Web Application.
Web Server Programming 1. Nuts and Bolts. Premises of Course Provides general introduction, no in-depth training Assumes some HTML knowledge Assumes some.
8.1 © 2004 Pearson Education, Inc. Exam Designing a Microsoft ® Windows ® Server 2003 Active Directory and Network Infrastructure Lesson 8: Planning.
Module 5 Configuring Authentication. Module Overview Lesson 1: Understanding Classic SharePoint Authentication Providers Lesson 2: Understanding Federated.
Presentation: SOAP/WS in a distributed object framework, Application Servers & AXIS SOAP.
Presentation: SOAP/WS in a distributed object framework, Application Servers & AXIS SOAP.
Module 11: Securing a Microsoft ASP.NET Web Application.
Ins and Outs of Authenticating Users Requests to IIS 6.0 and ASP.NET Chris Adams Program Manager IIS Product Unit Microsoft Corporation.
Jaas Introduction. Outline l General overview of Java security Java 2 security model How is security maintained by Java and JVM? How can a programmer.
Your friend, Bluestem. What is Bluestem? “Bluestem is a software system which enables one or more high-security SSL HTTP servers in a domain (entrusted.
CSI 3125, Preliminaries, page 1 SERVLET. CSI 3125, Preliminaries, page 2 SERVLET A servlet is a server-side software program, Responds oriented other.
1 Introduction to Servlets. Topics Web Applications and the Java Server. HTTP protocol. Servlets 2.
©SoftMoore ConsultingSlide 1 Filters. Filters can be used in a web application to intercept, examine, and possibly transform requests or responses associated.
CSI 3125, Preliminaries, page 1 SERVLET. CSI 3125, Preliminaries, page 2 SERVLET A servlet is a server-side software program, written in Java code, that.
Web Services Security Patterns Alex Mackman CM Group Ltd
HTTP protocol Java Servlets. HTTP protocol Web system communicates with end-user via HTTP protocol HTTP protocol methods: GET, POST, HEAD, PUT, OPTIONS,
Active Directory. Computers in organizations Computers are linked together for communication and sharing of resources There is always a need to administer.
LM/NTLMv1 Retirement Hosted by LSP Services.
Unlocking the Secrets of Alfresco Authentication Mehdi BELMEKKI, Consultancy Team Alfresco.
CS 562 Advanced Java and Internet Application Computer Warehouse Web Application By Team Alpha :-  Puja Mehta (102163)  Mona Nagpure (102147)
Daniel Doubrovkine (dblock[at]dblock[dot]org) Single Sign-On w/ Tomcat & WAFFLE 6/8/2010 Tomcat -> Waffle ->
Alain Bethuyne Web Security Architect BNPParibas Fortis
Introduction to Servlets
Ask the Experts – Building Login-Based Sites in AEM
Agenda Introduction Security flow for a request Authentication
Servlet Fudamentals.
Java Servlets By: Tejashri Udavant..
Outline SOAP and Web Services in relation to Distributed Objects
Creating Novell Portal Services Gadgets: An Architectural Overview
IBM Certified WAS 8.5 Administrator
Sessions.
Server-to-Client Remote Access and DirectAccess
Chapter 26 Servlets.
الخطوات المطلوب القيام بها قبل انشاء الموقع
CS320 Web and Internet Programming Cookies and Session Tracking
Servlet APIs Every servlet must implement javax.servlet.Servlet interface Most servlets implement the interface by extending one of these classes javax.servlet.GenericServlet.
CS3220 Web and Internet Programming Cookies and Session Tracking
CS3220 Web and Internet Programming Cookies and Session Tracking
Introduction to Java Servlets
CS122B: Projects in Databases and Web Applications Winter 2019
Java Chapter 7 (Estifanos Tilahun Mihret--Tech with Estif)
Presentation transcript:

Real Single Sign-on for web applications Holger Zobel JavaZone 2005

Agenda 1.Background –Description of client environment –What’s Single sign-on? –Java Authentication and Authorization Service (JAAS) –The NTLM authentication protocol 2.Implementation –Using jCIFS for Single Sign-on –Making WebSphere trust our NTLM-implementation 3.Other application servers 4.Questions

The client Large government agency Lots of mainframe application, but is getting more and more web based applications 8000 employees with 450 remote offices Low computer skills Windows NT workstations Project to make a web based child support management system running on WebSphere

What is Single Sign- on? KonseptBeskrivelseLeverandør Ticket-basertBruker autentiseres av en sentral server, som utsteder adgangsbilletter til alle tjenester som er en del av det aktuelle sikkerhetsdomene  IBM  Microsoft  CA  Sun  BMC  Novell PassordsynkroniseringBruker benytter samme passord mot hver server, applikasjon og nettverksressurs. Synkronisering skjer mha. av synkroniseringsserver til deltakende systemer. Passord lagres lokalt på klienten  IBM  Microsoft  CA  Sun  BMC  Novell Proxy-basert Agent-basert Bruker kan ha forskjellige passord for hver server, applikasjon og nettverksressurs. Passord lagres sentralt (eller lokalt via agent). Ved autentisering mot SSO-klienten gjøres databasen tilgjengelig  IBM  Microsoft  CA  Sun  BMC  Novell PassordserverPassordserver er et derivat av proxy-basert; forskjellen ligger i at passordet blir sendt tilbake til bruker, og derfra videre til aktuelt system (i motsetning til proxy, som sender direkte til systemet på vegne av systemet)  IBM  Microsoft  CA  Sun  BMC  Novell

JAAS Java Authentication and Authorization Service JAAS is a set of APIs that enable services to authenticate and enforce access controls upon users. Example JAAS login: lc = new LoginContext(“myConfiguration”); lc.login(); Works well for Java Client Applications and username/password web authentication

JAAS authentication LoginContext ConfigurationLoginModule new(String name CallbackHandler callback) getConfiguration() initializeSubject()

NTLM NTLM - “Windows NT LAN Manager” The authentication protocol used by Windows NT for file server authentication Also supported by several other protocols including MS-extended HTTP Client support: Internet Explorer, Mozilla/Firefox, Sun Java on Windows Not secure enough for non-SSL on internet, but should be acceptable on intranets Windows 2000 uses Kerberos by default (optionally NTLM) which is more secure

How NTLM over HTTP works HTTP RequestHTTP Response GET /index.html HTTP/1.1HTTP/ Unauthorized WWW-Authenticate: NTLM Connection: close GET /index.html HTTP/1.1 Authorization: NTLM TlRMTVNTU.... HTTP/ Unauthorized WWW-Authenticate: NTLM TlRMTVNTU.... GET /index.html HTTP/1.1 Authorization: NTLM TlRMTVNTUA... HTTP/ OK NTLM uses three messages to authenticate: Type 1: Negotiation Type 2: Challenge Type 3: Authentication

jCIFS CIFS – Common Internet File System (Microsoft file sharing protocol) Reimplementation of Samba using Java Open Source (LGPL) Also implements NTLM over HTTP See: jcifs.samba.org

Solution overview WebSphere Active Directory

Implementing SSO with jCIFS public class SSOLogin extends NtlmServlet implements Servlet { public void init(ServletConfig c) throws ServletException { jcifs.Config.setProperty("jcifs.smb.client.domain", “ "); jcifs.Config.setProperty("jcifs.http.domainController", “ "); } public void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { // Get username from session String username =(String) req.getSession().getAttribute("ntlmuser"); }

Integration with WebSphere Want to use WebSphere’s access control for access to web pages Need to convince WebSphere that we have logged on a user! Can use WebSphere “TrustInterceptor”. Normally used to let a another web server authenticate our users.

Our TrustInterceptor class package no.clientname.framework.sso; import com.ibm.websphere.security.*; public class CustomTrustInterceptor extends WebSphereBaseTrustAssociationInterceptor implements TrustAssociationInterceptor { /** return true if this is the target interceptor, else return false. */ public boolean isTargetInterceptor(HttpServletRequest req) throws WebTrustAssociationException { String ntlmuser = (String)req.getSession().getAttribute("ntlmuser"); if(ntlmuser != null) return true; else return false; } /** Get the user name from the request and if the user is entitled to the requested resource return the user*/ public String getAuthenticatedUsername(HttpServletRequest req) throws WebTrustAssociationUserException { String ntlmuser = (String)req.getSession().getAttribute("ntlmuser"); if(ntlmuser != null) { return ntlmuser; } throw new WebTrustAssociationUserException(); }

WebSphere configuration Steps to enable our SSO implementation in WAS: 1.Add wssec.jar and CustomTrustInjector.class to ws.ext.dirs class path 2.Turn on Global Security 3.Select “LTPA (Light weight Third party authentication)” as Active Authentication Mechanism 4.Under Authentication Mechanisms select LTPA, Trust Association, Interceptors and add the CustomTrustInjector class.

Some bugs.. Everything seemed to work fine at first, but... HTTP POST did not work in IE Solution Reply with an error code on the last NTLM response and keep username on session The client is authenticated using NTLM, but IE thinks the server does not support NTLM, and stops trying to re-authenticate on HTTP POST Add this code to the authentication servlet: response.setStatus(HttpServletResponse.SC_UNAUTHORIZED);

Using Other Application Servers Some untested ideas for using jCIFS on other application servers: -TrustInterceptor-like capabilities(For example “AuthFilter” in BEA WebLogic) -Custom Security -Security-filter -JAAS Module

Questions? No frequently asked questions or tips regarding JAAS on Sun’s pages...