PPF Home
Plugins
Developers
   Font size:      

LDAPQuery (v1.0)

PDF
PDF

Description

Perform searches towards any LDAP version 3 compliant servers

Using javax.naming.directory.DirContext scopes and filters to search LDAP servers.

Configuration

The configuration file for this plugin is system/LDAPQuery/LDAPQueryConfig.xml

ldap

First of all you need to specify which LDAP server to connect to using a hostname, a port number and a username (bindDN) and a password. Please note that at the moment it's only supported to connect to non-SSL LDAP servers.


  <ldap>    
	<hostname>localhost</hostname>
	<port>389</port>
	<bindDN>cn=orcladmin,cn=Users,dc=develix,dc=net</bindDN>
	<password>password</password>
  </ldap>

    

commandShowTriggers

A command to show which LDAP searches are in the current configuration. The output attribute isn't actually used for this command. It is just provided for compatibility, so don't mess with it. The result is allways returned as DCC chat.

  • authLevel - ANY, ADMIN, MASTER, TRUSTED, NONE
  • output - PM

      <commandShowTriggers authLevel="none" output="pm">ldap</commandShowTriggers>

    

paramSeparator

A character or a series of characters to use as separator when using parameters in a trigger, for example in !show a#b#3 the # character is the paramSeparator. Default is a space.


      <paramSeparator> </paramSeparator>

    

search

Create a trigger (new command) that the bot will respond to. The plugin will perform the LDAP search associated with the trigger. The result is always shown in the channel.

  • trigger - The command which executes the LDAP search
  • baseDN - A tree node from where the search will be performed
  • scope - How to perform the search (base, one, sub)
  • filter - What do actually search for

    <search trigger="!getadminuser" baseDN="cn=Users,dc=develix,dc=net">
    	<param scope="sub" /> 
    	<param filter="(uid=orcladmin)" />
    </search>

    

Commands

Show all SELECT statements

Command: ldap
Description: Shows you a list of LDAP searches in the current configuration.
Auth Level: none
Where to give command: pm
Outputs to: DCC chat
Example(s):

  • /MSG Bot ldap

!getadminuser

Command: !getadminuser
Description: This is an example command on how you can utilize this plugin.
Auth Level: none
Where to give command: channel
Outputs to: channel
Example(s):

  • !!getadminuser

Change History

v1.0 First Version by far2fish