Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Extending LDAP plugin

  • quasar_
  • quasar_'s Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 6 months ago - 2 years 6 months ago #228824 by quasar_
Extending LDAP plugin was created by quasar_
My LimeSurvey version: 5.3.15
Own server or LimeSurvey hosting: Own Server
==================
Hello,

I wanted to change a few things in the LDAP plugin, so I copied the core plugin from /application/core/plugins/AuthLDAP to the /plugins directory.
Then I renamed the directory, AuthLDAP.php, the class name and $name inside AuthLDAP.php all to the same new name. I also changed the config.xml metadata name.

Then I clicked "Scan files" under "Configuration" > "Plugins", chose my plugin and clicked on "Install".
Next I configured my plugin and set it up the same way I set up the core LDAP plugin.
I then activated my plugin and when I log in I get the error: "Incorrect username and/or password!"
The error message is probably a default one because username and password are definitely correct as they function correctly when using the ldap core plugin.

I also checked the table lime_plugins which says load_error NULL:
| id | name                                   | active | version | load_error | load_error_message | plugin_type | priority |
|  1 | Authdb                                 |      1 | 1.0.0   |          0 | NULL               | core        |        0 |
|  2 | AuditLog                              |      1 | 1.0.0   |          0 | NULL               | core        |        0 |
|  3 | Authwebserver                    |      0 | 1.0.0   |          0 | NULL               | core        |        0 |
|  4 | ExportR                               |      0 | 1.0.0   |          0 | NULL               | core        |        0 |
|  6 | oldUrlCompat                      |      0 | 1.0.1   |          0 | NULL               | core        |        0 |
|  8 | ExportSTATAxml                 |      0 | 1.0.0   |          0 | NULL               | core        |        0 |
| 16 | AuthLDAP                          |      0 | 1.0.0   |          0 |                         | core        |        0 |
| 17 | ComfortUpdateChecker     |      1 | 1.0.0   |          0 | NULL               | core        |        0 |
| 18 | PasswordRequirement      |      1 | 1.1.0   |          0 | NULL               | core        |        0 |
| 19 | expressionQuestionHelp   |      0 | 1.0.1   |          0 | NULL               | core        |        0 |
| 20 | expressionQuestionForAll |      0 | 1.0.1   |          0 | NULL               | core        |        0 |
| 21 | expressionFixedDbVar      |      0 | 1.0.2   |          0 | NULL               | core        |        0 |
| 22 | customToken                     |      0 | 1.0.1   |          0 | NULL               | core        |        0 |
| 23 | mailSenderToFrom           |      0 | 1.0.0   |          0 | NULL               | core        |        0 |
| 24 | MyAuthLDAP                    |      1 | 1.0.0   |       NULL | NULL           | user        |        0 |

As a last resort I could just modify the core plugin but do not want to change it everytime it gets updated.
Any help is appreciated.
Last edit: 2 years 6 months ago by quasar_. Reason: Change table format

Please Log in to join the conversation.

  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team & Official Partner
  • LimeSurvey Community Team & Official Partner
More
2 years 6 months ago #229063 by DenisChenu
Replied by DenisChenu on topic Extending LDAP plugin
Can you send your updated plugin ?

Can you check if you have plugin_settings for plugin id 24 here ?

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. - Professional support - Plugins, theme and development .
I don't answer to private message.

Please Log in to join the conversation.

  • quasar_
  • quasar_'s Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 6 months ago #229098 by quasar_
Replied by quasar_ on topic Extending LDAP plugin
Thank you for your reply.

Do you mean uploading it here? I can do that, but like I said I only changed the things mentioned above. Other than that it is the same code as the core one.

I checked plugin_settings and there are 21 entries for plugin id 24. Values are the same as core AuthLDAP.

Please Log in to join the conversation.

Moderators: holchtpartner

Lime-years ahead

Online-surveys for every purse and purpose