[Xerte] Re: LDAP givenName & sn

Davies, Dale Dale.Davies at liv-coll.ac.uk
Thu Jul 28 11:16:14 BST 2011


Yes, the first line it the fix for my actual problem.  The second is
another I found along the way, not sure what you mean by "dollared"
though unfortunately.

 

Seems the workspaceproperties entry is not added to the .htaccess file
by default, so when clicking on the "Properties" button to edit
workspace properties a URL is opened like "/workspaceproperties" in a
new window, however this is not rewritten to "workspaceproperties.php"
so a 404 is returned.

 

Adding that line to .htaccess file fixes the issue so the URL is
actually rewritten.

 

 

Dale Davies - VLE / E-Learning Developer

Liverpool Community College, CIS Dept, Bankfield Road, Liverpool, L13
0BQ.

Web: www.liv-coll.ac.uk <http://www.liv-coll.ac.uk> 

Tel: 0151 252 3238

 

From: xerte-bounces at lists.nottingham.ac.uk
[mailto:xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Pat Lockley
Sent: 28 July 2011 10:52
To: Xerte discussion list
Subject: [Xerte] Re: LDAP givenName & sn

 

the top line is the fix (thank you).

 

Not sure the .htaccess change shouldn't be "dollared" - the install mods
the default htaccess so don't add that line in by default

On Thu, Jul 28, 2011 at 10:38 AM, Davies, Dale
<Dale.Davies at liv-coll.ac.uk> wrote:

Hi Julian,

 

Two things I have found so far.  The first fixes a bug where the users
first name and surname were not being saved into the database when
logging in.  The second fixes a bug where trying to update workspace
properties returned a 404.

 

In login_library.php at about line 537 change....

 

*         $ldap_hosts = mysql_query("select * from ldap");

 

To...

 

*         $ldap_hosts = mysql_query("select * from " .
$xerte_toolkits_site->database_table_prefix . "ldap"); 

 

 

In the .htaccess file I added the following line...

 

*         rewriteRule ^workspaceproperties/?$
/xerte/workspaceproperties.php

 

 

Hope this helps J 

 

 

Dale Davies - VLE / E-Learning Developer

Liverpool Community College, CIS Dept, Bankfield Road, Liverpool, L13
0BQ.

Web: www.liv-coll.ac.uk <http://www.liv-coll.ac.uk> 

Tel: 0151 252 3238

 

From: xerte-bounces at lists.nottingham.ac.uk
[mailto:xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Julian Tenney
Sent: 28 July 2011 09:31


To: Xerte discussion list
Subject: [Xerte] Re: LDAP givenName & sn

 

What exactly do I need to do?

 

You can commit a change...?

 

From: xerte-bounces at lists.nottingham.ac.uk
[mailto:xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Pat Lockley
Sent: 27 July 2011 17:08
To: Xerte discussion list
Subject: [Xerte] Re: LDAP givenName & sn

 

Ah crap.

 

Julian can you paste in the table prefix php into that line?

On Wed, Jul 27, 2011 at 4:31 PM, Davies, Dale
<Dale.Davies at liv-coll.ac.uk> wrote:

I read about the password thing elsewhere on the mailing list, I seem to
get the behaviour one would expect.  As in, the only way anyone can log
in is by using only the correct username and correct password, a blank
or incorrect password will not allow a login.

 

I've made some progress on my problem, it seems that around line 537 of
login_library.php the following mysql query does not use the user
defined table name prefix...

 

$ldap_hosts = mysql_query("select * from ldap");

 

Adding my table name prefix almost fixes things, now the given name and
sn are pulled in, doing a var_dump on $login_check shows this, but only
the sn is saved in the database.

 

I'm guessing the solution must be some other query also not using the
table prefix.

 

Anyways, I'm off home for the day.  This can wait until the morning ;-)

 

 

Thanks again,

 

Dale Davies - VLE / E-Learning Developer

Liverpool Community College, CIS Dept, Bankfield Road, Liverpool, L13
0BQ.

Web: www.liv-coll.ac.uk <http://www.liv-coll.ac.uk> 

Tel: 0151 252 3238

 

From: xerte-bounces at lists.nottingham.ac.uk
[mailto:xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Pat Lockley
Sent: 27 July 2011 14:55
To: Xerte discussion list
Subject: [Xerte] Re: LDAP givenName & sn

 

No, just in login_library and index.php (when it comes to account
creation).

 

Silly question - try entering the wrong password - see what happens.

On Wed, Jul 27, 2011 at 2:07 PM, Davies, Dale
<Dale.Davies at liv-coll.ac.uk> wrote:

Hi,

 

I've updated "givenname" to "givenName" in the following functions
(within login_library.php)...

 

*         get_ldap_array()

*         get_user_ldap()

*         authenticate_to_host()

 

The "givenName" and "sn" attributes definitely exists in the Active
Directory and I am able to access them via my own PHP applications, but
for some reason Xerte seems to be ignoring them.  No errors shown in the
Xerte logs or the apache error log.

 

Another thing I have tried after changing these is to remove the user
account from the Xerte database and try logging in again, but to no
avail.  The user account can log in, but no other data is saved in the
row, just the user id.

 

Am I looking in the right place (login_library.php) or are there other
places within the Xerte code base that also check LDAP?

 

Thanks again,

 

Dale Davies - VLE / E-Learning Developer

Liverpool Community College, CIS Dept, Bankfield Road, Liverpool, L13
0BQ.

Web: www.liv-coll.ac.uk <http://www.liv-coll.ac.uk> 

Tel: 0151 252 3238

 

From: xerte-bounces at lists.nottingham.ac.uk
[mailto:xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Pat Lockley
Sent: 27 July 2011 12:18
To: Xerte discussion list
Subject: [Xerte] Re: LDAP givenName & sn

 

Hello,

 

>From recollection the code does two LDAP checks. Maybe the second one
fails?

 

I would be surprised givenname isn't in the database in sitedetails or
ldap?

 

Pat

On Wed, Jul 27, 2011 at 11:45 AM, Davies, Dale
<Dale.Davies at liv-coll.ac.uk> wrote:

Hi,

 

I've set Xerte up on a Linux web server, everything works perfectly
apart from one aspect.  When a user logs in their name is not pulled
into the Xerte users database via LDAP.  

 

I have checked through the code and found login_library.php to contain
"givenname", so I changed this to "givenName".  However this still does
not pull in the name.  We definitely have values stores in those
attributes within the Active Directory.

 

Am I missing something?  I can't find any solution unfortunately, I
realise this isn't a huge problem as Xerte still works regardless, but
users are unable to search for each other and share/hand over projects.

 

Any help/advice is much appreciated.  Many thanks.

 

 

Dale Davies - VLE / E-Learning Developer

Liverpool Community College, CIS Dept, Bankfield Road, Liverpool, L13
0BQ.

Web: www.liv-coll.ac.uk <http://www.liv-coll.ac.uk> 

Tel: 0151 252 3238

 

 

________________________________


Please consider the environment before printing this email.

________________________________


This email and any attachments are confidential and intended solely for
the use of the individual to whom it is addressed. Any views or opinions
presented are solely those of the author and do not necessarily
represent those of Liverpool Community College or associated companies.
You must not, directly or indirectly, use, disclose, distribute, print,
or copy any part of this message if you are not the intended recipient. 

The message content of in-coming emails is automatically scanned to
identify Spam and viruses otherwise Liverpool Community College does not
actively monitor content. However, sometimes it will be necessary for
Liverpool Community College to access business communications during
staff absence. 

Liverpool Community College has taken steps to ensure that this email
and any attachments are virus free. However, it is the responsibility of
the recipient to ensure that it is virus free and no responsibility is
accepted by Liverpool Community College for any loss or damage arising
in any way from its use. 

Error! Filename not specified.

________________________________

 

This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please send it back to me, and immediately delete it.
Please do not use, copy or disclose the information contained in this
message or in any attachment. Any views or opinions expressed by the
author of this email do not necessarily reflect the views of the
University of Nottingham. 

This message has been checked for viruses but the contents of an
attachment may still contain software viruses which could damage your
computer system: you are advised to perform your own checks. Email
communications with the University of Nottingham may be monitored as
permitted by UK legislation. 


_______________________________________________
Xerte mailing list
Xerte at lists.nottingham.ac.uk
http://lists.nottingham.ac.uk/mailman/listinfo/xerte

This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please send it back to me, and immediately delete it.
Please do not use, copy or disclose the information contained in this
message or in any attachment.  Any views or opinions expressed by the
author of this email do not necessarily reflect the views of the
University of Nottingham.

This message has been checked for viruses but the contents of an
attachment
may still contain software viruses which could damage your computer
system:
you are advised to perform your own checks. Email communications with
the
University of Nottingham may be monitored as permitted by UK
legislation.

 

 

________________________________


Please consider the environment before printing this email.

________________________________


This email and any attachments are confidential and intended solely for
the use of the individual to whom it is addressed. Any views or opinions
presented are solely those of the author and do not necessarily
represent those of Liverpool Community College or associated companies.
You must not, directly or indirectly, use, disclose, distribute, print,
or copy any part of this message if you are not the intended recipient. 

The message content of in-coming emails is automatically scanned to
identify Spam and viruses otherwise Liverpool Community College does not
actively monitor content. However, sometimes it will be necessary for
Liverpool Community College to access business communications during
staff absence. 

Liverpool Community College has taken steps to ensure that this email
and any attachments are virus free. However, it is the responsibility of
the recipient to ensure that it is virus free and no responsibility is
accepted by Liverpool Community College for any loss or damage arising
in any way from its use. 
Error! Filename not specified.

________________________________

 


_______________________________________________
Xerte mailing list
Xerte at lists.nottingham.ac.uk
http://lists.nottingham.ac.uk/mailman/listinfo/xerte

This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please send it back to me, and immediately delete it.
Please do not use, copy or disclose the information contained in this
message or in any attachment.  Any views or opinions expressed by the
author of this email do not necessarily reflect the views of the
University of Nottingham.

This message has been checked for viruses but the contents of an
attachment
may still contain software viruses which could damage your computer
system:
you are advised to perform your own checks. Email communications with
the
University of Nottingham may be monitored as permitted by UK
legislation.

 

 

________________________________


Please consider the environment before printing this email.

________________________________


This email and any attachments are confidential and intended solely for
the use of the individual to whom it is addressed. Any views or opinions
presented are solely those of the author and do not necessarily
represent those of Liverpool Community College or associated companies.
You must not, directly or indirectly, use, disclose, distribute, print,
or copy any part of this message if you are not the intended recipient. 

The message content of in-coming emails is automatically scanned to
identify Spam and viruses otherwise Liverpool Community College does not
actively monitor content. However, sometimes it will be necessary for
Liverpool Community College to access business communications during
staff absence. 

Liverpool Community College has taken steps to ensure that this email
and any attachments are virus free. However, it is the responsibility of
the recipient to ensure that it is virus free and no responsibility is
accepted by Liverpool Community College for any loss or damage arising
in any way from its use. 
Error! Filename not specified.

________________________________

 


_______________________________________________
Xerte mailing list
Xerte at lists.nottingham.ac.uk
http://lists.nottingham.ac.uk/mailman/listinfo/xerte

This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please send it back to me, and immediately delete it.
Please do not use, copy or disclose the information contained in this
message or in any attachment.  Any views or opinions expressed by the
author of this email do not necessarily reflect the views of the
University of Nottingham.

This message has been checked for viruses but the contents of an
attachment
may still contain software viruses which could damage your computer
system:
you are advised to perform your own checks. Email communications with
the
University of Nottingham may be monitored as permitted by UK
legislation.

 

 

________________________________


Please consider the environment before printing this email.

________________________________


This email and any attachments are confidential and intended solely for
the use of the individual to whom it is addressed. Any views or opinions
presented are solely those of the author and do not necessarily
represent those of Liverpool Community College or associated companies.
You must not, directly or indirectly, use, disclose, distribute, print,
or copy any part of this message if you are not the intended recipient. 

The message content of in-coming emails is automatically scanned to
identify Spam and viruses otherwise Liverpool Community College does not
actively monitor content. However, sometimes it will be necessary for
Liverpool Community College to access business communications during
staff absence. 

Liverpool Community College has taken steps to ensure that this email
and any attachments are virus free. However, it is the responsibility of
the recipient to ensure that it is virus free and no responsibility is
accepted by Liverpool Community College for any loss or damage arising
in any way from its use. 
Error! Filename not specified.

________________________________

 


_______________________________________________
Xerte mailing list
Xerte at lists.nottingham.ac.uk
http://lists.nottingham.ac.uk/mailman/listinfo/xerte

This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please send it back to me, and immediately delete it.
Please do not use, copy or disclose the information contained in this
message or in any attachment.  Any views or opinions expressed by the
author of this email do not necessarily reflect the views of the
University of Nottingham.

This message has been checked for viruses but the contents of an
attachment
may still contain software viruses which could damage your computer
system:
you are advised to perform your own checks. Email communications with
the
University of Nottingham may be monitored as permitted by UK
legislation.



 


---------------------------------------------------------------------------------------

Please consider the environment before printing this email.

---------------------------------------------------------------------------------------

This email and any attachments are confidential and intended solely for the use of the individual to whom it is addressed.  Any views or opinions presented are solely those of the author and do not necessarily represent those of Liverpool Community College or associated companies.  You must not, directly or indirectly, use, disclose, distribute, print, or copy any part of this message if you are not the intended recipient.



The message content of in-coming emails is automatically scanned to identify Spam and viruses otherwise Liverpool Community College does not actively monitor content.  However, sometimes it will be necessary for Liverpool Community College to access business communications during staff absence.



Liverpool Community College has taken steps to ensure that this email and any attachments are virus free.  However, it is the responsibility of the recipient to ensure that it is virus free and no responsibility is accepted by Liverpool Community College for any loss or damage arising in any way from its use.

---------------------------------------------------------------------------------------









-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.nottingham.ac.uk/pipermail/xerte/attachments/20110728/9bd4bbf8/attachment-0001.html>


More information about the Xerte mailing list