org.apache.jetspeed.sso
Interface SSOProvider


public interface SSOProvider

Utility component to handle SSO requests

Author:
Roger Ruttimann

Method Summary
 void addCredentialsForSite(String fullPath, String remoteUser, String site, String pwd)
          addCredentialsForSite()
 void addCredentialsForSite(Subject subject, String remoteUser, String site, String pwd)
           
 void addSite(String siteName, String siteUrl)
           
 void addSiteChallengeResponse(String siteName, String siteUrl, String realm)
          Add a new site that uses Challenge / Response Authentication
 void addSiteFormAuthenticated(String siteName, String siteUrl, String realm, String userField, String pwdField)
          Add a new site that uses Form Authentication
 Collection getCookiesForUser(String fullPath)
          Retrive cookies for an user by User full path
 Collection getCookiesForUser(Subject user)
          Retrive Cookies by Subject
 SSOContext getCredentials(Subject subject, String site)
           
 List getPrincipalsForSite(SSOSite site)
          return a list of SSOContext objects containing both the portal principal, remote principal, and credentials
 String getRealmForSite(String site)
           
 SSOSite getSite(String siteUrl)
           
 String getSiteName(String site)
           
 Iterator getSites(String filter)
           
 Collection getSitesForPrincipal(String userId)
          Get all SSOSites that the principal has access to
 String getSiteURL(String site)
           
 boolean hasSSOCredentials(Subject subject, String site)
          Public API's for SSO functinality
 void init()
          Init Called from the Spring Framework to initialize SSO Provider component
 void removeCredentialsForSite(String fullPath, String site)
          removeCredentialsForSite()
 void removeCredentialsForSite(Subject subject, String site)
           
 void removeSite(SSOSite site)
           
 void setRealmForSite(String site, String realm)
           
 void updateCredentialsForSite(Subject subject, String remoteUser, String site, String pwd)
           
 void updateSite(SSOSite site)
           
 String useSSO(Subject subject, String url, boolean bRefresh)
          Same as the method above except that the user will be authenticated against all SSOSites defined for the user before going to the destination site.
 String useSSO(Subject subject, String url, String SSOSite, boolean bRefresh)
          This method first authenticates the the SSOSite and then forwards the request to the destination URL.
 

Method Detail

init

void init()
          throws Exception
Init Called from the Spring Framework to initialize SSO Provider component

Throws:
Exception

useSSO

String useSSO(Subject subject,
              String url,
              String SSOSite,
              boolean bRefresh)
              throws SSOException
This method first authenticates the the SSOSite and then forwards the request to the destination URL. The content will be returned as a string. If the SSOSite and the url match only one call will be executed since the authentication will be done while getting the result page.

Parameters:
userID -
url -
SSOSite -
bRefresh - if true it refreshes the proxy connection if false a cached proxy will be used
Returns:
Throws:
SSOException

useSSO

String useSSO(Subject subject,
              String url,
              boolean bRefresh)
              throws SSOException
Same as the method above except that the user will be authenticated against all SSOSites defined for the user before going to the destination site.

Parameters:
userID -
url -
bRefresh - if true it refreshes the proxy connection if false a cached proxy will be used
Returns:
Throws:
SSOException

getCookiesForUser

Collection getCookiesForUser(String fullPath)
Retrive cookies for an user by User full path

Parameters:
fullPath -
Returns:

getCookiesForUser

Collection getCookiesForUser(Subject user)
Retrive Cookies by Subject

Parameters:
user -
Returns:

hasSSOCredentials

boolean hasSSOCredentials(Subject subject,
                          String site)
Public API's for SSO functinality

Returns:

getCredentials

SSOContext getCredentials(Subject subject,
                          String site)
                          throws SSOException
Throws:
SSOException

addCredentialsForSite

void addCredentialsForSite(Subject subject,
                           String remoteUser,
                           String site,
                           String pwd)
                           throws SSOException
Throws:
SSOException

updateCredentialsForSite

void updateCredentialsForSite(Subject subject,
                              String remoteUser,
                              String site,
                              String pwd)
                              throws SSOException
Throws:
SSOException

removeCredentialsForSite

void removeCredentialsForSite(Subject subject,
                              String site)
                              throws SSOException
Throws:
SSOException

getPrincipalsForSite

List getPrincipalsForSite(SSOSite site)
return a list of SSOContext objects containing both the portal principal, remote principal, and credentials

Parameters:
site -
Returns:
list SSOContext objects

getSites

Iterator getSites(String filter)

getSite

SSOSite getSite(String siteUrl)

updateSite

void updateSite(SSOSite site)
                throws SSOException
Throws:
SSOException

addSite

void addSite(String siteName,
             String siteUrl)
             throws SSOException
Throws:
SSOException

removeSite

void removeSite(SSOSite site)
                throws SSOException
Throws:
SSOException

addCredentialsForSite

void addCredentialsForSite(String fullPath,
                           String remoteUser,
                           String site,
                           String pwd)
                           throws SSOException
addCredentialsForSite()

Parameters:
fullPath -
remoteUser -
site -
pwd -
Throws:
SSOException

removeCredentialsForSite

void removeCredentialsForSite(String fullPath,
                              String site)
                              throws SSOException
removeCredentialsForSite()

Parameters:
fullPath -
site -
Throws:
SSOException

getSiteURL

String getSiteURL(String site)

getSiteName

String getSiteName(String site)

setRealmForSite

void setRealmForSite(String site,
                     String realm)
                     throws SSOException
Throws:
SSOException

getRealmForSite

String getRealmForSite(String site)
                       throws SSOException
Throws:
SSOException

getSitesForPrincipal

Collection getSitesForPrincipal(String userId)
Get all SSOSites that the principal has access to

Parameters:
userId -
Returns:

addSiteChallengeResponse

void addSiteChallengeResponse(String siteName,
                              String siteUrl,
                              String realm)
                              throws SSOException
Add a new site that uses Challenge / Response Authentication

Parameters:
siteName -
siteUrl -
realm -
Throws:
SSOException

addSiteFormAuthenticated

void addSiteFormAuthenticated(String siteName,
                              String siteUrl,
                              String realm,
                              String userField,
                              String pwdField)
                              throws SSOException
Add a new site that uses Form Authentication

Parameters:
siteName -
siteUrl -
realm -
userField -
pwdField -
Throws:
SSOException


Copyright © 1999-2007 Apache Software Foundation. All Rights Reserved.