IN PROGRESS - issue LDAP-36: Ldap Person example using OpenLDAP

http://opensource.atlassian.com/projects/spring/browse/LDAP-36
This commit is contained in:
Ulrik Sandberg
2007-01-17 23:21:42 +00:00
parent 63d9948bcf
commit 2bad16d6d8
5 changed files with 11 additions and 7 deletions

View File

@@ -72,7 +72,7 @@
<!-- =================================================================================== -->
<bean id="contextFactory" class="org.acegisecurity.ldap.DefaultInitialDirContextFactory">
<constructor-arg value="ldap://localhost:389/dc=jayway,dc=se" />
<constructor-arg value="${url}/${base}" />
</bean>
<bean id="ldapUserSearch" class="org.acegisecurity.ldap.search.FilterBasedLdapUserSearch">

View File

@@ -13,7 +13,7 @@
<!-- Authenticate using a fixed user -->
<!--
<bean id="contextSource" class="org.springframework.ldap.core.support.LdapContextSource" >
<property name="urls" value="${urls}" />
<property name="url" value="${url}" />
<property name="base" value="${base}" />
<property name="userDn" value="${userDn}" />
<property name="password" value="${password}" />
@@ -23,7 +23,7 @@
<!-- Authenticate using the currently logged in user, retrieved by Acegi Security -->
<bean id="contextSource" class="org.springframework.ldap.core.support.LdapContextSource" >
<property name="urls" value="${urls}" />
<property name="url" value="${url}" />
<property name="base" value="${base}" />
<property name="authenticationSource" ref="acegiAuthenticationSource" />
<property name="dirObjectFactory" value="org.springframework.ldap.core.DefaultDirObjectFactory" />
@@ -50,8 +50,8 @@
<bean id="traditionalPersonDao"
class="org.springframework.ldap.samples.person.dao.TraditionalPersonDaoImpl">
<property name="url" value="ldap://localhost:389" />
<property name="base" value="dc=jayway,dc=se" />
<property name="url" value="${url}" />
<property name="base" value="${base}" />
</bean>
<bean id="dummyPersonDao"

View File

@@ -1,3 +1,6 @@
<br/>
<a href="<c:url value="logoff.jsp"/>">Logoff</a> user <authz:authentication operation="username"/>
<div id="copyright">
<p>&copy; Copyright 2002-2006, <a href="http://www.springframework.org">www.springframework.org</a>, under the terms of the Apache 2.0 software license.</p>
</div>

View File

@@ -4,6 +4,7 @@
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="authz" uri="http://acegisecurity.org/authz" %>
<html>
<head>

View File

@@ -1,4 +1,4 @@
urls=ldap://127.0.0.1
userDn=uid=admin,ou=system
url=ldap://127.0.0.1
userDn=cn=Manager,dc=jayway,dc=se
password=secret
base=dc=jayway,dc=se