JAAS Implemented - PowerPoint PPT Presentation

About This Presentation
Title:

JAAS Implemented

Description:

Guest Presentation of Network Security – PowerPoint PPT presentation

Number of Views:81
Slides: 13
Provided by: Username withheld or not provided
Tags:

less

Transcript and Presenter's Notes

Title: JAAS Implemented


1
JAAS ImplementationSubmitted to Sir Inam Ul
HaqSubmitted by SharjeelBSIT-7th University
of Okara
2
Components
  • Login Context.
  • Configuration files.
  • Call Back Handlers.
  • Login Module.

3
LOGIN context
  • The login context is used to actually log in. The
    code performing the authentication instantiates a
    Login Context, which then uses a Configuration to
    determine which login modules to use to
    authenticate a subject. The code attempting to
    authenticate then calls login () on the Login
    Context.

4
LOGIN CONTEXT
5
Configuration files
  • Configuration is an abstract class that defines
    how a Login Context and Login modules should be
    used.
  • The main use of a configuration is to determine
    which login modules need to be called and states
    of the entire login process. There are four
    possibilities
  • O Required - must succeed for the entire login
    to succeed. Even fails, the other login modules
    are queried.
  • O Requisite - If fails, the login process is
    short-circuited and no more login modules are
    called.
  • O Sufficient - If this module succeeds and no
    required or requisite modules fail, the entire
    login succeeds.
  • O Optional - This modules' success doesn't
    impact on the remainder of the login process. If
    no sufficient, requisite, or required modules
    fail, the login succeeds, regardless of whether
    an optional module succeeds.

6
  • You can create configuration file just like any
    other ordinary file with the extension of
    .config.
  • The configuration file must be in the same
    directory as your project.
  • Test is the name of the configuration file
  • Jass.loginModule is the name of our login module
    class.

7
Call back handler
  • The CallbackHandler interface defines one method
    handle (Callback callbacks).This method
    iterates through the callbacks provided and adds
    the requested information to each one.

8
Call back handler
9
Login module
  • Login Module is an interface that must be
    implemented in order to provide authentication.
  • Multiple login modules can be used at a time, and
    JAAS will attempt to log in via each of them.
    JAAS can be configured to allow or deny logins
    based on which of those various attempts succeed.
  • Login module defines five methods, initialize ()
    , login(), commit () , abort ( ) , and logout (
    ), to implement a two-phase commit for
    authentication when using multiple authentication
    methods.

10
Login module
  • inltialize(Subject subject, CallbackHandler
    handler, Map sharedState, Map options)
  • This method sets up the LoginModule to be
    used to attempt a login.  
  • login()
  • This method checks the credentials of the
    subject passed in earlier. How this is done is
    implementation-dependent.  
  • commit()
  • If the necessary logins were successful, JAAS
    will call commit () on each login module.  
  • abort()
  • As the necessary login modules failed, the the
    abort () method is called. 
  • logout()
  • This method logs out a subject.

11
Login module
  • When the login module class is called it invoked
    it initialize().

12
Login module
  • All the authentication is done in the login()
    method.
Write a Comment
User Comments (0)
About PowerShow.com