blob: 3496601037718bbe10f390971bea3e50a46ce53c [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (version 1.7.0_21) on Thu May 30 15:02:18 PDT 2013 -->
<meta http-equiv="Content-Type" content="text/html" charset="UTF-8">
<title>ActiveDirectoryRealm (Apache Shiro 1.2.2 API)</title>
<meta name="date" content="2013-05-30">
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="ActiveDirectoryRealm (Apache Shiro 1.2.2 API)";
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!-- -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/ActiveDirectoryRealm.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>Prev Class</li>
<li>Next Class</li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html" target="_top">Frames</a></li>
<li><a href="ActiveDirectoryRealm.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#fields_inherited_from_class_org.apache.shiro.realm.ldap.AbstractLdapRealm">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.apache.shiro.realm.activedirectory</div>
<h2 title="Class ActiveDirectoryRealm" class="title">Class ActiveDirectoryRealm</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
<li>
<ul class="inheritance">
<li><a href="../../../../../org/apache/shiro/realm/CachingRealm.html" title="class in org.apache.shiro.realm">org.apache.shiro.realm.CachingRealm</a></li>
<li>
<ul class="inheritance">
<li><a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html" title="class in org.apache.shiro.realm">org.apache.shiro.realm.AuthenticatingRealm</a></li>
<li>
<ul class="inheritance">
<li><a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html" title="class in org.apache.shiro.realm">org.apache.shiro.realm.AuthorizingRealm</a></li>
<li>
<ul class="inheritance">
<li><a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html" title="class in org.apache.shiro.realm.ldap">org.apache.shiro.realm.ldap.AbstractLdapRealm</a></li>
<li>
<ul class="inheritance">
<li>org.apache.shiro.realm.activedirectory.ActiveDirectoryRealm</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><a href="../../../../../org/apache/shiro/authc/LogoutAware.html" title="interface in org.apache.shiro.authc">LogoutAware</a>, <a href="../../../../../org/apache/shiro/authz/Authorizer.html" title="interface in org.apache.shiro.authz">Authorizer</a>, <a href="../../../../../org/apache/shiro/authz/permission/PermissionResolverAware.html" title="interface in org.apache.shiro.authz.permission">PermissionResolverAware</a>, <a href="../../../../../org/apache/shiro/authz/permission/RolePermissionResolverAware.html" title="interface in org.apache.shiro.authz.permission">RolePermissionResolverAware</a>, <a href="../../../../../org/apache/shiro/cache/CacheManagerAware.html" title="interface in org.apache.shiro.cache">CacheManagerAware</a>, <a href="../../../../../org/apache/shiro/realm/Realm.html" title="interface in org.apache.shiro.realm">Realm</a>, <a href="../../../../../org/apache/shiro/util/Initializable.html" title="interface in org.apache.shiro.util">Initializable</a>, <a href="../../../../../org/apache/shiro/util/Nameable.html" title="interface in org.apache.shiro.util">Nameable</a></dd>
</dl>
<hr>
<br>
<pre>public class <a href="../../../../../src-html/org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#line.53">ActiveDirectoryRealm</a>
extends <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html" title="class in org.apache.shiro.realm.ldap">AbstractLdapRealm</a></pre>
<div class="block">A <a href="../../../../../org/apache/shiro/realm/Realm.html" title="interface in org.apache.shiro.realm"><code>Realm</code></a> that authenticates with an active directory LDAP
server to determine the roles for a particular user. This implementation
queries for the user's groups and then maps the group names to roles using the
<a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#groupRolesMap"><code>groupRolesMap</code></a>.</div>
<dl><dt><span class="strong">Since:</span></dt>
<dd>0.1</dd></dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_summary">
<!-- -->
</a>
<h3>Field Summary</h3>
<ul class="blockList">
<li class="blockList"><a name="fields_inherited_from_class_org.apache.shiro.realm.ldap.AbstractLdapRealm">
<!-- -->
</a>
<h3>Fields inherited from class&nbsp;org.apache.shiro.realm.ldap.<a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html" title="class in org.apache.shiro.realm.ldap">AbstractLdapRealm</a></h3>
<code><a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#principalSuffix">principalSuffix</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#searchBase">searchBase</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#systemPassword">systemPassword</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#systemUsername">systemUsername</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#url">url</a></code></li>
</ul>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#ActiveDirectoryRealm()">ActiveDirectoryRealm</a></strong>()</code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected <a href="../../../../../org/apache/shiro/authc/AuthenticationInfo.html" title="interface in org.apache.shiro.authc">AuthenticationInfo</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#buildAuthenticationInfo(java.lang.String, char[])">buildAuthenticationInfo</a></strong>(<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;username,
char[]&nbsp;password)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected <a href="../../../../../org/apache/shiro/authz/AuthorizationInfo.html" title="interface in org.apache.shiro.authz">AuthorizationInfo</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#buildAuthorizationInfo(java.util.Set)">buildAuthorizationInfo</a></strong>(<a href="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</a>&lt;<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&gt;&nbsp;roleNames)</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected <a href="http://java.sun.com/javase/6/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a>&lt;<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&gt;</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#getRoleNamesForGroups(java.util.Collection)">getRoleNamesForGroups</a></strong>(<a href="http://java.sun.com/javase/6/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a>&lt;<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&gt;&nbsp;groupNames)</code>
<div class="block">This method is called by the default implementation to translate Active Directory group names
to role names.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected <a href="../../../../../org/apache/shiro/authc/AuthenticationInfo.html" title="interface in org.apache.shiro.authc">AuthenticationInfo</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#queryForAuthenticationInfo(org.apache.shiro.authc.AuthenticationToken, org.apache.shiro.realm.ldap.LdapContextFactory)">queryForAuthenticationInfo</a></strong>(<a href="../../../../../org/apache/shiro/authc/AuthenticationToken.html" title="interface in org.apache.shiro.authc">AuthenticationToken</a>&nbsp;token,
<a href="../../../../../org/apache/shiro/realm/ldap/LdapContextFactory.html" title="interface in org.apache.shiro.realm.ldap">LdapContextFactory</a>&nbsp;ldapContextFactory)</code>
<div class="block">Builds an <a href="../../../../../org/apache/shiro/authc/AuthenticationInfo.html" title="interface in org.apache.shiro.authc"><code>AuthenticationInfo</code></a> object by querying the active directory LDAP context for the
specified username.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected <a href="../../../../../org/apache/shiro/authz/AuthorizationInfo.html" title="interface in org.apache.shiro.authz">AuthorizationInfo</a></code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#queryForAuthorizationInfo(org.apache.shiro.subject.PrincipalCollection, org.apache.shiro.realm.ldap.LdapContextFactory)">queryForAuthorizationInfo</a></strong>(<a href="../../../../../org/apache/shiro/subject/PrincipalCollection.html" title="interface in org.apache.shiro.subject">PrincipalCollection</a>&nbsp;principals,
<a href="../../../../../org/apache/shiro/realm/ldap/LdapContextFactory.html" title="interface in org.apache.shiro.realm.ldap">LdapContextFactory</a>&nbsp;ldapContextFactory)</code>
<div class="block">Builds an <a href="../../../../../org/apache/shiro/authz/AuthorizationInfo.html" title="interface in org.apache.shiro.authz"><code>AuthorizationInfo</code></a> object by querying the active directory LDAP context for the
groups that a user is a member of.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#setGroupRolesMap(java.util.Map)">setGroupRolesMap</a></strong>(<a href="http://java.sun.com/javase/6/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&gt;&nbsp;groupRolesMap)</code>&nbsp;</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_org.apache.shiro.realm.ldap.AbstractLdapRealm">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;org.apache.shiro.realm.ldap.<a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html" title="class in org.apache.shiro.realm.ldap">AbstractLdapRealm</a></h3>
<code><a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#doGetAuthenticationInfo(org.apache.shiro.authc.AuthenticationToken)">doGetAuthenticationInfo</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#doGetAuthorizationInfo(org.apache.shiro.subject.PrincipalCollection)">doGetAuthorizationInfo</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#onInit()">onInit</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#setLdapContextFactory(org.apache.shiro.realm.ldap.LdapContextFactory)">setLdapContextFactory</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#setPrincipalSuffix(java.lang.String)">setPrincipalSuffix</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#setSearchBase(java.lang.String)">setSearchBase</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#setSystemPassword(java.lang.String)">setSystemPassword</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#setSystemUsername(java.lang.String)">setSystemUsername</a>, <a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#setUrl(java.lang.String)">setUrl</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_org.apache.shiro.realm.AuthorizingRealm">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;org.apache.shiro.realm.<a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html" title="class in org.apache.shiro.realm">AuthorizingRealm</a></h3>
<code><a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#afterCacheManagerSet()">afterCacheManagerSet</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkPermission(org.apache.shiro.authz.Permission, org.apache.shiro.authz.AuthorizationInfo)">checkPermission</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkPermission(org.apache.shiro.subject.PrincipalCollection, org.apache.shiro.authz.Permission)">checkPermission</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkPermission(org.apache.shiro.subject.PrincipalCollection, java.lang.String)">checkPermission</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkPermissions(java.util.Collection, org.apache.shiro.authz.AuthorizationInfo)">checkPermissions</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkPermissions(org.apache.shiro.subject.PrincipalCollection, java.util.Collection)">checkPermissions</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkPermissions(org.apache.shiro.subject.PrincipalCollection, java.lang.String...)">checkPermissions</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkRole(org.apache.shiro.subject.PrincipalCollection, java.lang.String)">checkRole</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkRole(java.lang.String, org.apache.shiro.authz.AuthorizationInfo)">checkRole</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkRoles(java.util.Collection, org.apache.shiro.authz.AuthorizationInfo)">checkRoles</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkRoles(org.apache.shiro.subject.PrincipalCollection, java.util.Collection)">checkRoles</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#checkRoles(org.apache.shiro.subject.PrincipalCollection, java.lang.String...)">checkRoles</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#clearCachedAuthorizationInfo(org.apache.shiro.subject.PrincipalCollection)">clearCachedAuthorizationInfo</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#doClearCache(org.apache.shiro.subject.PrincipalCollection)">doClearCache</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#getAuthorizationCache()">getAuthorizationCache</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#getAuthorizationCacheKey(org.apache.shiro.subject.PrincipalCollection)">getAuthorizationCacheKey</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#getAuthorizationCacheName()">getAuthorizationCacheName</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#getAuthorizationInfo(org.apache.shiro.subject.PrincipalCollection)">getAuthorizationInfo</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#getPermissionResolver()">getPermissionResolver</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#getRolePermissionResolver()">getRolePermissionResolver</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#hasAllRoles(org.apache.shiro.subject.PrincipalCollection, java.util.Collection)">hasAllRoles</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#hasRole(org.apache.shiro.subject.PrincipalCollection, java.lang.String)">hasRole</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#hasRole(java.lang.String, org.apache.shiro.authz.AuthorizationInfo)">hasRole</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#hasRoles(java.util.List, org.apache.shiro.authz.AuthorizationInfo)">hasRoles</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#hasRoles(org.apache.shiro.subject.PrincipalCollection, java.util.List)">hasRoles</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isAuthorizationCachingEnabled()">isAuthorizationCachingEnabled</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isPermitted(java.util.List, org.apache.shiro.authz.AuthorizationInfo)">isPermitted</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isPermitted(org.apache.shiro.subject.PrincipalCollection, java.util.List)">isPermitted</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isPermitted(org.apache.shiro.subject.PrincipalCollection, org.apache.shiro.authz.Permission)">isPermitted</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isPermitted(org.apache.shiro.subject.PrincipalCollection, java.lang.String...)">isPermitted</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isPermitted(org.apache.shiro.subject.PrincipalCollection, java.lang.String)">isPermitted</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isPermittedAll(java.util.Collection, org.apache.shiro.authz.AuthorizationInfo)">isPermittedAll</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isPermittedAll(org.apache.shiro.subject.PrincipalCollection, java.util.Collection)">isPermittedAll</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#isPermittedAll(org.apache.shiro.subject.PrincipalCollection, java.lang.String...)">isPermittedAll</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#setAuthorizationCache(org.apache.shiro.cache.Cache)">setAuthorizationCache</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#setAuthorizationCacheName(java.lang.String)">setAuthorizationCacheName</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#setAuthorizationCachingEnabled(boolean)">setAuthorizationCachingEnabled</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#setName(java.lang.String)">setName</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#setPermissionResolver(org.apache.shiro.authz.permission.PermissionResolver)">setPermissionResolver</a>, <a href="../../../../../org/apache/shiro/realm/AuthorizingRealm.html#setRolePermissionResolver(org.apache.shiro.authz.permission.RolePermissionResolver)">setRolePermissionResolver</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_org.apache.shiro.realm.AuthenticatingRealm">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;org.apache.shiro.realm.<a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html" title="class in org.apache.shiro.realm">AuthenticatingRealm</a></h3>
<code><a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#assertCredentialsMatch(org.apache.shiro.authc.AuthenticationToken, org.apache.shiro.authc.AuthenticationInfo)">assertCredentialsMatch</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#clearCachedAuthenticationInfo(org.apache.shiro.subject.PrincipalCollection)">clearCachedAuthenticationInfo</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#getAuthenticationCache()">getAuthenticationCache</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#getAuthenticationCacheKey(org.apache.shiro.authc.AuthenticationToken)">getAuthenticationCacheKey</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#getAuthenticationCacheKey(org.apache.shiro.subject.PrincipalCollection)">getAuthenticationCacheKey</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#getAuthenticationCacheName()">getAuthenticationCacheName</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#getAuthenticationInfo(org.apache.shiro.authc.AuthenticationToken)">getAuthenticationInfo</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#getAuthenticationTokenClass()">getAuthenticationTokenClass</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#getCredentialsMatcher()">getCredentialsMatcher</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#init()">init</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#isAuthenticationCachingEnabled()">isAuthenticationCachingEnabled</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#isAuthenticationCachingEnabled(org.apache.shiro.authc.AuthenticationToken, org.apache.shiro.authc.AuthenticationInfo)">isAuthenticationCachingEnabled</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#setAuthenticationCache(org.apache.shiro.cache.Cache)">setAuthenticationCache</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#setAuthenticationCacheName(java.lang.String)">setAuthenticationCacheName</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#setAuthenticationCachingEnabled(boolean)">setAuthenticationCachingEnabled</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#setAuthenticationTokenClass(java.lang.Class)">setAuthenticationTokenClass</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#setCredentialsMatcher(org.apache.shiro.authc.credential.CredentialsMatcher)">setCredentialsMatcher</a>, <a href="../../../../../org/apache/shiro/realm/AuthenticatingRealm.html#supports(org.apache.shiro.authc.AuthenticationToken)">supports</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_org.apache.shiro.realm.CachingRealm">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;org.apache.shiro.realm.<a href="../../../../../org/apache/shiro/realm/CachingRealm.html" title="class in org.apache.shiro.realm">CachingRealm</a></h3>
<code><a href="../../../../../org/apache/shiro/realm/CachingRealm.html#clearCache(org.apache.shiro.subject.PrincipalCollection)">clearCache</a>, <a href="../../../../../org/apache/shiro/realm/CachingRealm.html#getAvailablePrincipal(org.apache.shiro.subject.PrincipalCollection)">getAvailablePrincipal</a>, <a href="../../../../../org/apache/shiro/realm/CachingRealm.html#getCacheManager()">getCacheManager</a>, <a href="../../../../../org/apache/shiro/realm/CachingRealm.html#getName()">getName</a>, <a href="../../../../../org/apache/shiro/realm/CachingRealm.html#isCachingEnabled()">isCachingEnabled</a>, <a href="../../../../../org/apache/shiro/realm/CachingRealm.html#onLogout(org.apache.shiro.subject.PrincipalCollection)">onLogout</a>, <a href="../../../../../org/apache/shiro/realm/CachingRealm.html#setCacheManager(org.apache.shiro.cache.CacheManager)">setCacheManager</a>, <a href="../../../../../org/apache/shiro/realm/CachingRealm.html#setCachingEnabled(boolean)">setCachingEnabled</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.<a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
<code><a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</a>, <a href="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_org.apache.shiro.util.Initializable">
<!-- -->
</a>
<h3>Methods inherited from interface&nbsp;org.apache.shiro.util.<a href="../../../../../org/apache/shiro/util/Initializable.html" title="interface in org.apache.shiro.util">Initializable</a></h3>
<code><a href="../../../../../org/apache/shiro/util/Initializable.html#init()">init</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a name="ActiveDirectoryRealm()">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>ActiveDirectoryRealm</h4>
<pre>public&nbsp;<a href="../../../../../src-html/org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#line.53">ActiveDirectoryRealm</a>()</pre>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="setGroupRolesMap(java.util.Map)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setGroupRolesMap</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../src-html/org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#line.80">setGroupRolesMap</a>(<a href="http://java.sun.com/javase/6/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&gt;&nbsp;groupRolesMap)</pre>
</li>
</ul>
<a name="queryForAuthenticationInfo(org.apache.shiro.authc.AuthenticationToken, org.apache.shiro.realm.ldap.LdapContextFactory)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>queryForAuthenticationInfo</h4>
<pre>protected&nbsp;<a href="../../../../../org/apache/shiro/authc/AuthenticationInfo.html" title="interface in org.apache.shiro.authc">AuthenticationInfo</a>&nbsp;<a href="../../../../../src-html/org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#line.101">queryForAuthenticationInfo</a>(<a href="../../../../../org/apache/shiro/authc/AuthenticationToken.html" title="interface in org.apache.shiro.authc">AuthenticationToken</a>&nbsp;token,
<a href="../../../../../org/apache/shiro/realm/ldap/LdapContextFactory.html" title="interface in org.apache.shiro.realm.ldap">LdapContextFactory</a>&nbsp;ldapContextFactory)
throws <a href="http://java.sun.com/javase/6/docs/api/javax/naming/NamingException.html?is-external=true" title="class or interface in javax.naming">NamingException</a></pre>
<div class="block">Builds an <a href="../../../../../org/apache/shiro/authc/AuthenticationInfo.html" title="interface in org.apache.shiro.authc"><code>AuthenticationInfo</code></a> object by querying the active directory LDAP context for the
specified username. This method binds to the LDAP server using the provided username and password -
which if successful, indicates that the password is correct.
<p/>
This method can be overridden by subclasses to query the LDAP server in a more complex way.</div>
<dl>
<dt><strong>Specified by:</strong></dt>
<dd><code><a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#queryForAuthenticationInfo(org.apache.shiro.authc.AuthenticationToken, org.apache.shiro.realm.ldap.LdapContextFactory)">queryForAuthenticationInfo</a></code>&nbsp;in class&nbsp;<code><a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html" title="class in org.apache.shiro.realm.ldap">AbstractLdapRealm</a></code></dd>
<dt><span class="strong">Parameters:</span></dt><dd><code>token</code> - the authentication token provided by the user.</dd><dd><code>ldapContextFactory</code> - the factory used to build connections to the LDAP server.</dd>
<dt><span class="strong">Returns:</span></dt><dd>an <a href="../../../../../org/apache/shiro/authc/AuthenticationInfo.html" title="interface in org.apache.shiro.authc"><code>AuthenticationInfo</code></a> instance containing information retrieved from LDAP.</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code><a href="http://java.sun.com/javase/6/docs/api/javax/naming/NamingException.html?is-external=true" title="class or interface in javax.naming">NamingException</a></code> - if any LDAP errors occur during the search.</dd></dl>
</li>
</ul>
<a name="buildAuthenticationInfo(java.lang.String, char[])">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>buildAuthenticationInfo</h4>
<pre>protected&nbsp;<a href="../../../../../org/apache/shiro/authc/AuthenticationInfo.html" title="interface in org.apache.shiro.authc">AuthenticationInfo</a>&nbsp;<a href="../../../../../src-html/org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#line.116">buildAuthenticationInfo</a>(<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;username,
char[]&nbsp;password)</pre>
</li>
</ul>
<a name="queryForAuthorizationInfo(org.apache.shiro.subject.PrincipalCollection, org.apache.shiro.realm.ldap.LdapContextFactory)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>queryForAuthorizationInfo</h4>
<pre>protected&nbsp;<a href="../../../../../org/apache/shiro/authz/AuthorizationInfo.html" title="interface in org.apache.shiro.authz">AuthorizationInfo</a>&nbsp;<a href="../../../../../src-html/org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#line.136">queryForAuthorizationInfo</a>(<a href="../../../../../org/apache/shiro/subject/PrincipalCollection.html" title="interface in org.apache.shiro.subject">PrincipalCollection</a>&nbsp;principals,
<a href="../../../../../org/apache/shiro/realm/ldap/LdapContextFactory.html" title="interface in org.apache.shiro.realm.ldap">LdapContextFactory</a>&nbsp;ldapContextFactory)
throws <a href="http://java.sun.com/javase/6/docs/api/javax/naming/NamingException.html?is-external=true" title="class or interface in javax.naming">NamingException</a></pre>
<div class="block">Builds an <a href="../../../../../org/apache/shiro/authz/AuthorizationInfo.html" title="interface in org.apache.shiro.authz"><code>AuthorizationInfo</code></a> object by querying the active directory LDAP context for the
groups that a user is a member of. The groups are then translated to role names by using the
configured <a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#groupRolesMap"><code>groupRolesMap</code></a>.
<p/>
This implementation expects the <tt>principal</tt> argument to be a String username.
<p/>
Subclasses can override this method to determine authorization data (roles, permissions, etc) in a more
complex way. Note that this default implementation does not support permissions, only roles.</div>
<dl>
<dt><strong>Specified by:</strong></dt>
<dd><code><a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html#queryForAuthorizationInfo(org.apache.shiro.subject.PrincipalCollection, org.apache.shiro.realm.ldap.LdapContextFactory)">queryForAuthorizationInfo</a></code>&nbsp;in class&nbsp;<code><a href="../../../../../org/apache/shiro/realm/ldap/AbstractLdapRealm.html" title="class in org.apache.shiro.realm.ldap">AbstractLdapRealm</a></code></dd>
<dt><span class="strong">Parameters:</span></dt><dd><code>principals</code> - the principal of the Subject whose account is being retrieved.</dd><dd><code>ldapContextFactory</code> - the factory used to create LDAP connections.</dd>
<dt><span class="strong">Returns:</span></dt><dd>the AuthorizationInfo for the given Subject principal.</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code><a href="http://java.sun.com/javase/6/docs/api/javax/naming/NamingException.html?is-external=true" title="class or interface in javax.naming">NamingException</a></code> - if an error occurs when searching the LDAP server.</dd></dl>
</li>
</ul>
<a name="buildAuthorizationInfo(java.util.Set)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>buildAuthorizationInfo</h4>
<pre>protected&nbsp;<a href="../../../../../org/apache/shiro/authz/AuthorizationInfo.html" title="interface in org.apache.shiro.authz">AuthorizationInfo</a>&nbsp;<a href="../../../../../src-html/org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#line.154">buildAuthorizationInfo</a>(<a href="http://java.sun.com/javase/6/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</a>&lt;<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&gt;&nbsp;roleNames)</pre>
</li>
</ul>
<a name="getRoleNamesForGroups(java.util.Collection)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getRoleNamesForGroups</h4>
<pre>protected&nbsp;<a href="http://java.sun.com/javase/6/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a>&lt;<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&gt;&nbsp;<a href="../../../../../src-html/org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#line.214">getRoleNamesForGroups</a>(<a href="http://java.sun.com/javase/6/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</a>&lt;<a href="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&gt;&nbsp;groupNames)</pre>
<div class="block">This method is called by the default implementation to translate Active Directory group names
to role names. This implementation uses the <a href="../../../../../org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html#groupRolesMap"><code>groupRolesMap</code></a> to map group names to role names.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>groupNames</code> - the group names that apply to the current user.</dd>
<dt><span class="strong">Returns:</span></dt><dd>a collection of roles that are implied by the given role names.</dd></dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!-- -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/ActiveDirectoryRealm.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>Prev Class</li>
<li>Next Class</li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?org/apache/shiro/realm/activedirectory/ActiveDirectoryRealm.html" target="_top">Frames</a></li>
<li><a href="ActiveDirectoryRealm.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#fields_inherited_from_class_org.apache.shiro.realm.ldap.AbstractLdapRealm">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright &#169; 2004-2013 <a href="http://www.apache.org/">The Apache Software Foundation</a>. All Rights Reserved.</small></p>
</body>
</html>