postmaster rule - reply ticekt by mail

Moderator: crythias

Post Reply
helldesk
Znuny newbie
Posts: 6
Joined: 20 Jun 2011, 16:35
Znuny Version: 3.03

postmaster rule - reply ticekt by mail

Post by helldesk »

Hi,

I wanted the following task to complete. Agents should be able to reply by mail to those tickets which were opened already by the customers, but customers shouldn't be able to open new ticket via e-mail, just from the ticketing interface.

At the moment both the agents & customers are able to open/reply tickets via mail.

I tried to do this with the postmaster filter settings:
Filter condition: X-OTRS-State Value1: new
Set e-mail headers: X-OTRS-Ignore: value1: yes
But it seems still opening the ticket from the mail.

it would be nice if somebody could help with this.

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

Re: postmaster rule - reply ticekt by mail

Post by crythias »

helldesk wrote:I wanted the following task to complete. Agents should be able to reply by mail to those tickets which were opened already by the customers,
Generally not recommended by OTRS.
viewtopic.php?f=53&t=8376
but customers shouldn't be able to open new ticket via e-mail, just from the ticketing interface.
This is generally backwards, but the short answer is don't give out (change) your inbound ticket email address.
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
MichaelR
Znuny expert
Posts: 250
Joined: 12 Oct 2010, 01:35
Znuny Version: 3.0.9
Company: LRS Health

Re: postmaster rule - reply ticekt by mail

Post by MichaelR »

You can perform a few code changes to make these happen, but generally it isn't a good idea.
Agents can get around accounting time and setting freetestfields etc.
And as crythias said, just don't give out/use your OTRS inbound address.
OTRS: 3.0.9 & ITSM 3.0.4 - OS: Windows 7 - DB: MySQL - Heaps of random/useful hacks :)
[Major Code Changes]
ArticleFreeTime1-3
Ability to search ArticleFreeText
helldesk
Znuny newbie
Posts: 6
Joined: 20 Jun 2011, 16:35
Znuny Version: 3.03

Re: postmaster rule - reply ticekt by mail

Post by helldesk »

Hi,

Thanks for the quick reply. I think i weren't completely detailed about the problem. Due not just the agents need to reply via mail, the users (customers) need to use that too. So that's not count that we don't give out the mail address unfortunately.

So both the agents & customers should be able to reply with mail to a ticket, but customers shouldn't be able to open a new ticket via mail, so they will forced to use the ticketing system for opening a new ticket.
crythias
Moderator
Posts: 10169
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: postmaster rule - reply ticekt by mail

Post by crythias »

Edit Config Settings in Ticket -> Core::PostMaster
PostMaster::PreFilterModule###3-NewTicketReject
Blocks all the incoming emails that do not have a valid ticket number in subject with From: @example.com address.
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
helldesk
Znuny newbie
Posts: 6
Joined: 20 Jun 2011, 16:35
Znuny Version: 3.03

Re: postmaster rule - reply ticekt by mail

Post by helldesk »

Thanks man! You saved my life! Exactly that was what I was searching for.

Thanks again.
helldesk
Znuny newbie
Posts: 6
Joined: 20 Jun 2011, 16:35
Znuny Version: 3.03

Re: postmaster rule - reply ticekt by mail

Post by helldesk »

Hi,

I need some help again, due my management came up with idea I had to modify things.
(The basic idea what I need is internal users/agent should be able to reply to the ticket via mail, but internal users shouldn't be able to open new ticket by mail. But for some external users should be able to open ticket by mails too. Now that part which is the open/block new mails via mail I was able to solve with .procmail rules in server side.) But I have problems with the notification mails which are send out. The problem is when an agent reply to a ticket via mail, then the user not getting the mail, instead the agent get back his own reply. It seems the system thinks the agent as a customer in this case and send back the mail to himself. When a user reply via mail, then that's works, our agents get it without problem.

I have the following stuff activated in the "Notifications(Event)" section.

1. mail notify ticket reply from agent to customer

Recipient groups:
Customer

Event:
TicketCustomerUpdate

Article-type:
email-external
email-notification-external

----

I put here the rest of the rules just to make sure, there is the roblem not caused by overlap between the rules

2. Send mail to customer after he opened a ticket

Recipient groups:
Customer

Event:
ticketcreate

3. sending attachment to agents

Recipient groups:
Agent(all with write permission)

Event:
ArticleCreate

state: new

Article-type:
email-external
webrequest

Include attachments to notification: YES

--

Is there a way that I can fix this, that the user get the reply from the agent too?

Thanks
helldesk
Znuny newbie
Posts: 6
Joined: 20 Jun 2011, 16:35
Znuny Version: 3.03

Re: postmaster rule - reply ticekt by mail

Post by helldesk »

Hi,

is anybody has some idea for this please?

"The problem is when an agent reply to a ticket via mail, then the user not getting the mail, instead the agent get back his own reply. It seems the system thinks the agent as a customer in this case and send back the mail to himself. When a user reply via mail, then that's works, our agents get it without problem."

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

Re: postmaster rule - reply ticekt by mail

Post by crythias »

There is no clean way for OTRS to determine if an inbound email is from an agent or a customer, so it assumes all inbound emails are customer. Since an agent sends a message, the agent won't get a bounce because he's the customer. The customer won't get notification because it's an open ticket and a customer added to the ticket.

You can play around with Notification (Event) again, but there are no guarantees. Besides, it's easy to spoof being an agent, so there's that problem as well.
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
helldesk
Znuny newbie
Posts: 6
Joined: 20 Jun 2011, 16:35
Znuny Version: 3.03

Re: postmaster rule - reply ticekt by mail

Post by helldesk »

Thanks, so it seems it's just better if the agents just using the webinterface and leave alone the sending by mail part.
Post Reply