Package org.apache.jetspeed.sso

Examples of org.apache.jetspeed.sso.SSOException


                // SSO API lookup
                SSOContext credentials = null;
                try
                {
                    if (sso == null)
                        throw new SSOException("SSO Not supported.");
                   
                    credentials = sso.getCredentials(getSubject(), ssoURL);
                }
                catch(SSOException ssoex)
                {
View Full Code Here


        }
        catch (Exception e)
        {
            String msg = "Unable to add SSO Site: " + ssoSite.getName();
            log.error(msg, e);
            throw new SSOException(msg, e);
        }               
    }
View Full Code Here

        }
        catch (Exception e)
        {
            String msg = "Unable to remove SSO Site: " + site.getName();
            log.error(msg, e);
            throw new SSOException(msg, e);
        }       
    }
View Full Code Here

        }
        catch (Exception e)
        {
            String msg = "Unable to remove SSO Site: " + site.getName();
            log.error(msg, e);
            throw new SSOException(msg, e);
        }       
    }
View Full Code Here

   
    protected Collection<SSOUser> getRemoteUsers(JetspeedPrincipal p) throws SSOException {
        try{
            return ssoUserManagerSPI.getUsers(p);  
        } catch (SecurityException secex){           
            throw new SSOException(secex);
        }
    }
View Full Code Here

                        if (!resultUsers.containsKey(user.getId())){
                            resultUsers.put(user.getId(), user);
                        }
                    }
                } catch (SSOException se){           
                    throw new SSOException(se);
                }
            }
        }
        return resultUsers.values();
    }
View Full Code Here

   
    public Collection<SSOUser> getRemoteUsers(SSOSite site, JetspeedPrincipal portalPrincipal) throws SSOException {
        try{
            return ssoUserManagerSPI.getUsers(portalPrincipal,site.getSecurityDomainId());  
        } catch (SecurityException secex){           
            throw new SSOException(secex);
        }
    }
View Full Code Here

      }
     
      try{
          ssoUserManagerSPI.storePasswordCredential(pwdCred);
      } catch (SecurityException sx){
        throw new SSOException(sx);
      }
    }
View Full Code Here

    }

    protected SSOSite addSite(Long ownerDomainId, SSOSite site) throws SSOException
    {     
      if (domainAccessManager.getDomainByName(site.getName()) != null){
        throw new SSOException(SSOException.SITE_ALREADY_EXISTS);
      }
     
    SecurityDomainImpl sd = new SecurityDomainImpl();
      sd.setName(site.getName());
      sd.setOwnerDomainId(ownerDomainId);
      sd.setEnabled(true);     
      sd.setRemote(true);
     
      try{
        domainStorageManager.addDomain(sd);
      } catch(SecurityException sx){
        log.error("Could not add remote security domain with name "+site.getName()+" for owner domain "+ownerDomainId);
        throw new SSOException(SSOException.SITE_COULD_NOT_BE_CREATED,sx);
      }
      SecurityDomain storedDomain = domainAccessManager.getDomainByName(site.getName());
      if (storedDomain == null || storedDomain.getDomainId() == null){
        throw new SSOException(SSOException.SITE_COULD_NOT_BE_CREATED);
      }
     
      site.setSecurityDomainId(storedDomain.getDomainId());
     
      try{
            return ssoSiteManagerSPI.add(site);
      } catch (SSOException se){
          // catch SSO Exception to remove already stored domain.
          try{
              domainStorageManager.removeDomain(storedDomain);
          } catch (SecurityException secex){     
             
          }
          // rethrow exception
          throw new SSOException(se);
      }
    }
View Full Code Here

    {
        try{
            return ssoUserManagerSPI.getPasswordCredential(user);
        } catch (SecurityException secex){
            // TODO provide meaningful message
            throw new SSOException(secex);
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.jetspeed.sso.SSOException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.