
Hi all, I have successfully made the customers to be authenticated via LDAP. Now I would like to have the Agent authentication also to be done through the LDAP. My Config.pm looks like this . Cold some one point how I can start doing the Agent authentication also through my LDAP. PD ********************* Begin Congig.pm********************************** package Kernel::Config; # -- sub Load { my $Self = shift; $Self->{DatabaseHost} = 'localhost'; # Database # (The database name.) $Self->{Database} = 'otrs'; # DatabaseUser # (The database user.) $Self->{DatabaseUser} = 'otrs'; # DatabasePw # (The password of database user. You also can use bin/CryptPassword.pl # for crypted passwords.) $Self->{DatabasePw} = '************'; # DatabaseDSN # (The database DSN for MySQL ==> more: "man DBD::mysql") $Self->{DatabaseDSN} = "DBI:mysql:database=$Self->{Database};host=$Self->{DatabaseHost};"; $Self->{Home} = '/usr/share/otrs'; $Self->{CustomerUser} = { Name => 'COMAT LDAP', Module => 'Kernel::System::CustomerUser::LDAP', Params => { # ldap host Host => '192.168.100.160', # ldap base dn BaseDN => 'ou=people,dc=comat,dc=com', # search scope (one|sub) SSCOPE => 'sub', AlwaysFilter => '', # if your frontend is e. g. iso-8859-1 and the charset of your # ldap server is utf-8, use this options (if not, ignore it) # SourceCharset => ?utf-8?, # DestCharset => ?iso-8859-1?, # Net::LDAP new params (if needed - for more info see perldoc Net::LDAP) Params => { port => 389, timeout => 120, async => 0, version => 3, }, }, CustomerKey => 'uid', # customer # CustomerID => 'uid', CustomerUserListFields => ['cn', 'mail'], CustomerUserSearchFields => ['uid', 'cn', 'mail'], CustomerUserSearchPrefix => '', CustomerUserSearchSuffix => '*', CustomerUserSearchListLimit => 1000, CustomerUserPostMasterSearchFields => ['mail'], CustomerUserNameFields => ['givenname', 'sn'], # show now own tickets in customer panel, CompanyTickets CustomerUserExcludePrimaryCustomerID => 0, # add a ldap filter for valid users (expert setting) # CustomerUserValidFilter => ?(!(description=gesperrt))?, # admin can?t change customer preferences AdminSetPreferences => 0, Map => [ # note: Login, Email and CustomerID needed! # var, frontend, storage, shown (1=always,2=lite), required, storage-type, http-[ ?UserSalutation?, ?Title?, ?title?, 1, 0, ?var?, ?, 0 ], [ 'UserFirstname', 'Firstname', 'givenname', 1, 1, 'var', '', 0 ], [ 'UserLastname', 'Lastname', 'sn', 1, 1, 'var', '', 0 ], [ 'UserLogin', 'Username', 'uid', 1, 1, 'var', '', 0 ], [ 'UserEmail', 'Email', 'mail', 1, 1, 'var', '', 0 ], [ 'UserCustomerID', 'CustomerID', 'uid', 0, 1, 'var', '', 0 ], # [ ?UserCustomerIDs?, ?CustomerIDs?, ?second_customer_ids?, 1, 0, ?var?, ?, 0 ], [ 'UserPhone', 'Phone', 'telephonenumber', 1, 0, 'var', '', 0 ], [ 'UserAddress', 'Address', 'postalAddress', 1, 0, 'var', '', 0 ], [ 'UserComment', 'Comment', 'description', 1, 0, 'var', '', 0 ], ], }; $Self->{'AuthModule'} = 'Kernel::System::Auth::LDAP'; $Self->{'AuthModule::LDAP::Host'} = '192.168.100.160'; $Self->{'AuthModule::LDAP::BaseDN'} = 'ou=people,dc=comat,dc=com'; $Self->{'AuthModule::LDAP::UID'} = 'uid'; # for ldap posixGroups objectclass (just uid) $Self->{'AuthModule::LDAP::UserAttr'} = 'uid'; # This is an example configuration for an LDAP auth. backend. # (take care that Net::LDAP is installed!) $Self->{'Agent::AuthModule'} = 'Kernel::System::Auth::LDAP'; $Self->{'Agent::AuthModule::LDAP::Host'} = '192.168.100.160'; $Self->{'Agent::AuthModule::LDAP::BaseDN'} = 'ou=people,dc=comat,dc=com'; $Self->{'Agent::AuthModule::LDAP::UID'} = 'uid'; # for ldap posixGroups objectclass (just uid) $Self->{'Agent::AuthModule::LDAP::UserAttr'} = 'uid'; # Customer Authentication $Self->{'Customer::AuthModule'} = 'Kernel::System::CustomerAuth::LDAP'; $Self->{'Customer::AuthModule::LDAP::Host'} = '192.168.100.160'; $Self->{'Customer::AuthModule::LDAP::BaseDN'} = 'ou=people,dc=comat,dc=com'; $Self->{'Customer::AuthModule::LDAP::UID'} = 'uid'; # $Self->{'Customer::AuthModule::LDAP::SearchUserDN'} = ''; # $Self->{'Customer::AuthModule::LDAP::SearchUserPw'} = ''; # $Self->{'Customer::AuthModule::LDAP::GroupDN'} = 'cn=otrsCustomer'; # $Self->{'Customer::AuthModule::LDAP::AccessAttr'} = 'member'; $Self->{'Customer::AuthModule::LDAP::UserAttr'} = 'uid'; # ---------------------------------------------------- # } # ---------------------------------------------------- # # needed system stuff (don't edit this) # # ---------------------------------------------------- # use strict; use vars qw(@ISA $VERSION); use Kernel::Config::Defaults; push (@ISA, 'Kernel::Config::Defaults'); $VERSION = '$Revision: 1.16 $'; $VERSION =~ s/^\$.*:\W(.*)\W.+?$/$1/; # -----------------------------------------------------# 1; *******************End Cofig.pm*****************************************
participants (1)
-
Priyadarsan Roy