提交 c99fc315 编写于 作者: K Kohsuke Kawaguchi

[FIXED JENKINS-8152]

Formatting error in the rootDN inference code. It shouldn't include
attribute name.
上级 d7659971
......@@ -65,6 +65,9 @@ Upcoming changes</a>
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-12529">issue 12529</a>)
<li class=ref>
Matrix job now allows delete whole matrix, including sub-jobs.
<li class=bug>
Fixed a bug in LDAP default root DN inference.
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-8152">issue 8152</a>)
</ul>
</div><!--=TRUNK-END=-->
......
......@@ -325,8 +325,8 @@ public class LDAPSecurityRealm extends AbstractPasswordBasedSecurityRealm {
DirContext ctx = new InitialDirContext(props);
Attributes atts = ctx.getAttributes("");
Attribute a = atts.get("defaultNamingContext");
if(a!=null) // this entry is available on Active Directory. See http://msdn2.microsoft.com/en-us/library/ms684291(VS.85).aspx
return a.toString();
if(a!=null && a.get()!=null) // this entry is available on Active Directory. See http://msdn2.microsoft.com/en-us/library/ms684291(VS.85).aspx
return a.get().toString();
a = atts.get("namingcontexts");
if(a==null) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册