LDAP Backend - No Customer ID in emailed ticket

Moderator: crythias

Locked
robmen
Znuny newbie
Posts: 7
Joined: 06 Jun 2016, 19:37
Znuny Version: OTRS5
Real Name: Rob Mendes
Company: Moseley Wireless Solutions Group

LDAP Backend - No Customer ID in emailed ticket

Post by robmen »

We have an OTRS v5 site running that uses a LDAP backend. Customers can authenticate against LDAP using the customer web login. The site is running fine other than our inbound email tickets don't have the Customer info filled in on customer - email-external tickets field within the Agent Web interface. The Customer info is filled in okay when tickets are submitted via the Customer Web interface. Also, an agent can select People->Customer via the Agent Web interface and change the Customer user. The Customer user is then successfully looked up in LDAP via that Change Customer Of Ticket panel. Also the emailed ticket is listed in the Customer Web interface submitted after the Change Of Customer is done.

What is required to pass the Customer's email address into OTRS when tickets are submitted via email? It appears that the emailed tickets are being received as our helpdesk@domainname and the customer's original address is not available to OTRS to associate the ticket to a Customer in the Agent web interface.

Thank You for any insights,
rob
Eggllo
Znuny newbie
Posts: 79
Joined: 09 Jun 2016, 14:27
Znuny Version: 5.0.10

Re: LDAP Backend - No Customer ID in emailed ticket

Post by Eggllo »

Does the customerID attribute for each customer match their email? Our system uses LDAP and it associates new email tickets with users based on a match between the customerID and the email the ticket was sent from.

Take UserCustomerID (test@example.com) from customer source backend based on (test@example.com).

This is the message that shows in the system log when a ticket is associated with a specific customer.

Once the link is made, all of the info should be filled out automatically.
OTRS v5.0.10 with ITSM extension.
MySQL database
Ubuntu 16.04 LTS
robmen
Znuny newbie
Posts: 7
Joined: 06 Jun 2016, 19:37
Znuny Version: OTRS5
Real Name: Rob Mendes
Company: Moseley Wireless Solutions Group

Re: LDAP Backend - No Customer ID in emailed ticket

Post by robmen »

Yes we use 'mail' as the CustomerID and Customer key. A part of the config file below.

Thanks,
rob


CustomerKey => 'mail',
CustomerID => 'mail',
CustomerUserListFields => ['userPrincipalName', 'sAMAccountName', 'cn', 'mail'],
CustomerUserSearchFields => ['userPrincipalName', 'sAMAccountName', 'cn', 'givenname', 'mail'],
CustomerUserSearchPrefix => '',
CustomerUserSearchSuffix => '*',
CustomerUserSearchListLimit => 1000,
CustomerUserPostMasterSearchFields => ['mail'],
CustomerUserNameFields => ['givenname', 'sn'],
Map => [
[ 'UserFirstname', 'Firstname', 'givenname', 1, 1, 'var' ],
[ 'UserLastname', 'Lastname', 'sn', 1, 1, 'var' ],
[ 'UserName', 'Username', 'sAMAccountName', 1, 1, 'var' ],
[ 'UserLogin', 'Login', 'mail', 1, 1, 'var' ],
[ 'UserEmail', 'Email', 'mail', 1, 1, 'var' ],
[ 'UserCustomerID', 'CustomerID', 'mail', 0, 1, 'var' ],
[ 'UserPhone', 'Phone', 'telephonenumber', 1, 0, 'var' ],
],
};
Eggllo
Znuny newbie
Posts: 79
Joined: 09 Jun 2016, 14:27
Znuny Version: 5.0.10

Re: LDAP Backend - No Customer ID in emailed ticket

Post by Eggllo »

Hmmm, not too sure what the issue would be then. The only thing I notice is that I have a few extra attributes in my working config file, but I don't think they would make much of a difference.

Here it is just in case it helps:

Code: Select all

CustomerKey => 'sAMAccountName',
        # customer #
        CustomerID => 'mail',
        CustomerUserListFields => ['cn', 'mail'],
        CustomerUserSearchFields => ['sAMAccountName', 'cn', 'mail'],
        CustomerUserSearchPrefix => '',
        CustomerUserSearchSuffix => '*',
        CustomerUserSearchListLimit => 250,
        CustomerUserPostMasterSearchFields => ['mail'],
        CustomerUserNameFields => ['givenname', 'sn'],
        # show now own tickets in customer panel, CompanyTickets
        CustomerUserExcludePrimaryCustomerID => 0,
        # admin can't change customer preferences
        AdminSetPreferences => 0,
        # cache time to live in sec. - cache any ldap queries
        CacheTTL => 0,
        Map => [
            # note: Login, Email and CustomerID needed!
            # var, frontend, storage, shown (1=always,2=lite), required, storage-type, http-link, readonly
            ['UserTitle',     'Title',     'title',         1,0,'var','',0],
            ['UserFirstname', 'Firstname', 'givenname',     1,1,'var','',0],
            ['UserLastname',  'Lastname',  'sn',            1,1,'var','',0],
            ['UserLogin',     'Username',  'sAMAccountName',1,1,'var','',0],
            ['UserEmail',     'Email',     'mail',          1,1,'var','',0],
            ['UserCustomerID','CustomerID','mail',          0,1,'var','',0],
        ],
    };
If you go into SysConfig -> Framework -> Core::Log and switch your MinimumLogLevel to debug, what does your log show when you send in a new email ticket?
OTRS v5.0.10 with ITSM extension.
MySQL database
Ubuntu 16.04 LTS
robmen
Znuny newbie
Posts: 7
Joined: 06 Jun 2016, 19:37
Znuny Version: OTRS5
Real Name: Rob Mendes
Company: Moseley Wireless Solutions Group

Re: LDAP Backend - No Customer ID in emailed ticket

Post by robmen »

Yes, I agree that this config should be working.

Here is the log debug output.

Many thanks,
rob


[Thu Jun 9 13:50:08 2016][Info][Kernel::System::Ticket::TicketCreate] New Ticket [2016060901000101/testing] created (TicketID=146,Queue=Raw,Priority=3 normal,State=new)
[Thu Jun 9 13:50:09 2016][Info][Kernel::System::Ticket::Article::SendAutoResponse] No auto response addresses for Ticket [2016060901000101] (TicketID=146).
[Thu Jun 9 13:50:09 2016][Notice][Kernel::System::MailAccount::IMAP::_Fetch] IMAP: Fetched 1 email(s) from helpdesk/10.71.217.28.
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: LDAP Backend - No Customer ID in emailed ticket

Post by crythias »

There's more to this ...
First, make sure that the sender email address is visible (check?)
Then make sure that the sender email address matches a value in the customer information center/customer user

If the customerid is an email address, it's because the exact email address of sender (case insensitive) doesn't match the value of a real user's email address. Check for .local or subdomain.
It could, also, be that there is no customer_id that is sourced from ldap. It's blank or email or attempted to be filled from customer company but customer company is not relevant.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
robmen
Znuny newbie
Posts: 7
Joined: 06 Jun 2016, 19:37
Znuny Version: OTRS5
Real Name: Rob Mendes
Company: Moseley Wireless Solutions Group

Re: LDAP Backend - No Customer ID in emailed ticket

Post by robmen »

I'm not clear on your suggestions.
What do you mean check to see if the sender email address is visible?

Also, where does customer_id come into play in a LDAP backend?

Thanks for you time,
rob
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: LDAP Backend - No Customer ID in emailed ticket

Post by crythias »

Basically, confirm otrs sees the from address.

Where does customer_id come into play in a ldap backend?

It's the reason you're not seeing it ... an LDAP attribute must have a designated value of the customer_id for ldap and the customer_id map must exist.

Either the customer_id is 'mail' or the customer_id is some other attribute that holds a value you're using.

Every ticket requires a customer_user_id (login) and a customer_id (either email address or other identifier that might group users of a similar company or department so they can see each other's tickets in "Company Tickets"
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
robmen
Znuny newbie
Posts: 7
Joined: 06 Jun 2016, 19:37
Znuny Version: OTRS5
Real Name: Rob Mendes
Company: Moseley Wireless Solutions Group

Re: LDAP Backend - No Customer ID in emailed ticket

Post by robmen »

I am still not understanding your answer.

Our inbound emailed tickets are shown in the log as being from the postmaster address. No Customer addresses listed. How else is would we confirm otrs "sees" the customer's email address?

Also, there is no reference to a variable call customer_id in the Config.pm file only CustomerID.

Like I said the Customer Web interface works just fine. We only have the problem with emailed tickets.

Thanks,
rob
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: LDAP Backend - No Customer ID in emailed ticket

Post by crythias »

what's in your Map in Config.pm?
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
robmen
Znuny newbie
Posts: 7
Joined: 06 Jun 2016, 19:37
Znuny Version: OTRS5
Real Name: Rob Mendes
Company: Moseley Wireless Solutions Group

Re: LDAP Backend - No Customer ID in emailed ticket

Post by robmen »

Here it is.
Could this issue be in the email receive chain and not a problem in the mapping?
Maybe the fetchmail from the local mailbox into otrs isn't setup correctly?

Thanks so much,
rob



CustomerKey => 'mail',
CustomerID => 'mail',
CustomerUserListFields => ['userPrincipalName', 'sAMAccountName', 'cn', 'mail'],
CustomerUserSearchFields => ['userPrincipalName', 'sAMAccountName', 'cn', 'givenname', 'mail'],
CustomerUserSearchPrefix => '',
CustomerUserSearchSuffix => '*',
CustomerUserSearchListLimit => 3000,
CustomerUserPostMasterSearchFields => ['mail'],
CustomerUserNameFields => ['givenname', 'sn'],
Map => [
[ 'UserFirstname', 'Firstname', 'givenname', 1, 1, 'var' ],
[ 'UserLastname', 'Lastname', 'sn', 1, 1, 'var' ],
[ 'UserName', 'Username', 'sAMAccountName', 1, 1, 'var' ],
[ 'UserLogin', 'Login', 'mail', 1, 1, 'var' ],
[ 'UserEmail', 'Email', 'mail', 1, 1, 'var' ],
[ 'UserCustomerID', 'CustomerID', 'mail', 0, 1, 'var' ],
[ 'UserPhone', 'Phone', 'telephonenumber', 1, 0, 'var' ],
],
};
robmen
Znuny newbie
Posts: 7
Joined: 06 Jun 2016, 19:37
Znuny Version: OTRS5
Real Name: Rob Mendes
Company: Moseley Wireless Solutions Group

Resolved: LDAP Backend - No Customer ID in emailed ticket

Post by robmen »

As we were unable to determine the cause to the problem we resorted to a rebuild of the services on the OTRS host. The result of the reinstall "fixed" the issue and the CustomerID is now mapped and displayed properly in the emailed tickets.

Thank You for your help,
rob
Locked