email filter
Moderator: crythias
email filter
Hello everyone!
Im new using OTRS. I'd like to Know if is possible to receive emails only from costumers in DB (OTRS will automatic open a new ticket). All others emails must be discarded.
Sorry about my english!
Vitor
Im new using OTRS. I'd like to Know if is possible to receive emails only from costumers in DB (OTRS will automatic open a new ticket). All others emails must be discarded.
Sorry about my english!
Vitor
-
- Znuny newbie
- Posts: 2
- Joined: 28 Jun 2010, 10:52
- Znuny Version: 2.4.7
Re: email filter
Ubuntu 10.04, OTRS 2.4.7 @ China
MSN: michael.chong@live.com
MSN: michael.chong@live.com
-
- Moderator
- Posts: 10170
- Joined: 04 May 2010, 18:38
- Znuny Version: 5.0.x
- Location: SouthWest Florida, USA
- Contact:
Re: Only Accept tickets from customers in database
This only affects known domains, unfortunately.michael_zhong wrote:refer to http://lists.otrs.org/pipermail/otrs/20 ... 23287.html
There is a possibility to modify a file to do this...
Kernel/System/PostMaster/NewTicket.pm around line 135 original code follows
Code: Select all
# if there is no customer id found!
if ( !$GetParam{'X-OTRS-CustomerNo'} ) {
$GetParam{'X-OTRS-CustomerNo'} = $GetParam{SenderEmailAddress};
}
# if there is no customer user found!
if ( !$GetParam{'X-OTRS-CustomerUser'} ) {
$GetParam{'X-OTRS-CustomerUser'} = $GetParam{SenderEmailAddress};
}
Code: Select all
# if there is no customer id found!
if ( !$GetParam{'X-OTRS-CustomerNo'} ) {
$Self->{LogObject}->Log( Priority => 'info', Message => "$_ not in database" );
return;
}
# if there is no customer user found!
if ( !$GetParam{'X-OTRS-CustomerUser'} ) {
$Self->{LogObject}->Log( Priority => 'info', Message => "$_ not in database" );
return;
}
- Back up the file before editing
- I haven't tried this
- Don't blame me if it doesn't work
- This change can not be bypassed (you can never create a new ticket via email without being in the customer database) -- I think(?)
- If you want, you can change "info" to "notice" or "error" depending on how you want to log this message
- This change WILL get overwritten by updates.
- Please let me know your results!
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
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
-
- Znuny superhero
- Posts: 723
- Joined: 10 Oct 2007, 14:30
- Znuny Version: 3.0
- Location: Hamburg, Germany
Re: email filter
@crythias
I have a very modified version of this file, so I cannot give line numbers.
Your code refers to given X-OTRS- Mailheaders only. One should rather check for '$CustomerData{UserLogin}' if I get this right, which is a few lines above.
I have a very modified version of this file, so I cannot give line numbers.
Your code refers to given X-OTRS- Mailheaders only. One should rather check for '$CustomerData{UserLogin}' if I get this right, which is a few lines above.
openSuSE on ESX
IT-Helpdesk: OTRS 3.0
Customer Service: OTRS 3.0 (upgraded from 2.3)
Customer Service (subsidiary): OTRS 3.0
+additional test and development systems
IT-Helpdesk: OTRS 3.0
Customer Service: OTRS 3.0 (upgraded from 2.3)
Customer Service (subsidiary): OTRS 3.0
+additional test and development systems
-
- Moderator
- Posts: 10170
- Joined: 04 May 2010, 18:38
- Znuny Version: 5.0.x
- Location: SouthWest Florida, USA
- Contact:
Re: email filter
The reason I chose this method was that it was a default after checking if the user *did* exist. So, basically, if the user check failed, X-OTRS is the last hope, and if that failed, don't create. Did I miss something?
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
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
-
- Znuny superhero
- Posts: 723
- Joined: 10 Oct 2007, 14:30
- Znuny Version: 3.0
- Location: Hamburg, Germany
Re: email filter
No, you don't.
There are way more changes in my file. This should be fine.
We do not trust X-OTSR headers and therefore this part was probably changed, since we also have another SOAP customer data source to query for.
There are way more changes in my file. This should be fine.
We do not trust X-OTSR headers and therefore this part was probably changed, since we also have another SOAP customer data source to query for.
openSuSE on ESX
IT-Helpdesk: OTRS 3.0
Customer Service: OTRS 3.0 (upgraded from 2.3)
Customer Service (subsidiary): OTRS 3.0
+additional test and development systems
IT-Helpdesk: OTRS 3.0
Customer Service: OTRS 3.0 (upgraded from 2.3)
Customer Service (subsidiary): OTRS 3.0
+additional test and development systems
-
- Znuny newbie
- Posts: 14
- Joined: 30 Oct 2012, 16:25
- Znuny Version: 3.0.9
- Real Name: Ghislain
- Company: Logdirect
Re: email filter
Hi all,
I tried this hack and it works but it's logged as follow when someone is unregistered as customer :
"Message: 1 not in database".
$_ is given as 1 as you can see
I would like to know how email can be gave instead at this point.
Excuse me for my "poor" english
and thank you by advance.
I tried this hack and it works but it's logged as follow when someone is unregistered as customer :
"Message: 1 not in database".
$_ is given as 1 as you can see
I would like to know how email can be gave instead at this point.
Excuse me for my "poor" english

-
- Moderator
- Posts: 10170
- Joined: 04 May 2010, 18:38
- Znuny Version: 5.0.x
- Location: SouthWest Florida, USA
- Contact:
Re: email filter
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
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