Can Email Piping reject emails w/out existing ticket?
Moderator: mkoch227
Can Email Piping reject emails w/out existing ticket?
Script URL: instantpianogenius.com/helpdesk
Version of script: Just upgraded from 2.52 to 2.55
Hosting company: SoftLayer
URL of phpinfo.php: http://instantpianogenius.com/phpinfo.php
URL of session_test.php: Not sure what that is
What terms did you try when SEARCHING for a solution: spam, email, piping, block, reject
Write your message below:
I'm getting a lot of spam generated by email to my Hesk "reply" email, I have Email Piping [ON]. Is there a way to have Email Piping accept an email response to an existing ticket but reject random emails so that a new ticket isn't created by them?
All new legitimate tickets are initiated on my /helpdesk page so I don't need new tickets created by every spammy email that comes to my Hesk email, but I do want legitimate customers to be able to reply by email to existing tickets, please advise. Thanks in advance!
Keywords: spam, stop, piping, block, reject, generate
Version of script: Just upgraded from 2.52 to 2.55
Hosting company: SoftLayer
URL of phpinfo.php: http://instantpianogenius.com/phpinfo.php
URL of session_test.php: Not sure what that is
What terms did you try when SEARCHING for a solution: spam, email, piping, block, reject
Write your message below:
I'm getting a lot of spam generated by email to my Hesk "reply" email, I have Email Piping [ON]. Is there a way to have Email Piping accept an email response to an existing ticket but reject random emails so that a new ticket isn't created by them?
All new legitimate tickets are initiated on my /helpdesk page so I don't need new tickets created by every spammy email that comes to my Hesk email, but I do want legitimate customers to be able to reply by email to existing tickets, please advise. Thanks in advance!
Keywords: spam, stop, piping, block, reject, generate
Re: Can Email Piping reject emails w/out existing ticket?
SPAM filtering of incoming emails is something that should be done on the server side before piping into HESK.
However, in your specific case you can try changing this in file "inc/pipe_functions.inc.php":
1. find
2. below that add
This will discard any emails that are not recognized as replies to tickets.
However, in your specific case you can try changing this in file "inc/pipe_functions.inc.php":
1. find
Code: Select all
} // END REPLY
Code: Select all
return true;
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
You should follow me on Twitter here
Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools


Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Re: Can Email Piping reject emails w/out existing ticket?
Thank you, it sounds like that may be perfect, I'll try that! I'm trying to be careful about this since I'm afraid I'll accidentally block legit customer support emails which would cause trouble...
It also occurred to me that since all subject lines have "[#" in them to denote the ticket number once they're in the Hesk system and that all replies would still retain them, that a simple filter that said
"Reject if Subject line does not contain [#"
That way I could redirect emails to Hesk after putting [# in the subject line to get them accepted by Hesk.
I'm glad I've got options, thanks again.
It also occurred to me that since all subject lines have "[#" in them to denote the ticket number once they're in the Hesk system and that all replies would still retain them, that a simple filter that said
"Reject if Subject line does not contain [#"
That way I could redirect emails to Hesk after putting [# in the subject line to get them accepted by Hesk.
I'm glad I've got options, thanks again.
Re: Can Email Piping reject emails w/out existing ticket?
Hi unadonis,
I have same problem with you could you please helpp me where I should write this code on pipe_functions.inc.php ?
I have same problem with you could you please helpp me where I should write this code on pipe_functions.inc.php ?
Re: Can Email Piping reject emails w/out existing ticket?
I really don't recommend doing this, you will not be able to distinguish between legit first time emails and spam (neither contains [# inside).
The only solution to this issue is to filter email for spam before sending them to Hesk; there are many third party spam filters available, creating (and maintaining) a new one to be built into Hesk would be a huge waste of time and resources.
The only solution to this issue is to filter email for spam before sending them to Hesk; there are many third party spam filters available, creating (and maintaining) a new one to be built into Hesk would be a huge waste of time and resources.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
You should follow me on Twitter here
Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools


Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Re: Can Email Piping reject emails w/out existing ticket?
Hi klemen my scenerio like this : I want my costumer create ticket only via website. after they can contiune via mail they can reply tickey via mail yes ı can do this but ı dont want create ticket first via mail because this mail account recive another mail (spam , and another topic with costumer)
I Mean costumer will create ticket on web site. System send mail your ticket created Subject ([#LIY-980-83567] to costumer after costumer can reply. Another my cron job when work all another spam mail will crate new ticket this is very bad
I Mean costumer will create ticket on web site. System send mail your ticket created Subject ([#LIY-980-83567] to costumer after costumer can reply. Another my cron job when work all another spam mail will crate new ticket this is very bad
Re: Can Email Piping reject emails w/out existing ticket?
The simplest way to do that is to reject and emails that weren't identified as replies then.
In inc/pipe_functions.inc.php find and just ABOVE that code add
I would still recommend keeping a copy of all emails somewhere.
In inc/pipe_functions.inc.php find
Code: Select all
$tmpvar['trackid'] = hesk_createID();
Code: Select all
return hesk_cleanExit();
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
You should follow me on Twitter here
Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools


Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools
-
- Posts: 18
- Joined: Thu Sep 04, 2014 12:02 pm
Re: Can Email Piping reject emails w/out existing ticket?
I searched and this was the most recent post I could find regarding spam, so thought I'd ask here...please let me know if it's preferred to do a new post.
I have Apache SpamAssassin enabled on my server at Level 5, but have auto-delete disabled. Overall, it's done a really good job of finding and marking spam emails with a standardized *** SPAM *** insertion in the subject line. The spammers have found my support email address piping to HESK and I spend too much time per day blocking and deleting spam tickets. Is there a way to have all piped emails with *** SPAM *** in the subject line blocked from creating a ticket? I could enable auto-delete in Apache to most likely accomplish it prior to piping, but I still like to have the mail delivered to my email client (Thunderbird) to ensure I don't accidentally miss something. Thunderbird does a good job of routing them to the Junk folder, so I can peruse through or delete as necessary. Email piping works great, and having them route to HESK has been a huge help in managing my support business.
Thanks in advance,
Jason
I have Apache SpamAssassin enabled on my server at Level 5, but have auto-delete disabled. Overall, it's done a really good job of finding and marking spam emails with a standardized *** SPAM *** insertion in the subject line. The spammers have found my support email address piping to HESK and I spend too much time per day blocking and deleting spam tickets. Is there a way to have all piped emails with *** SPAM *** in the subject line blocked from creating a ticket? I could enable auto-delete in Apache to most likely accomplish it prior to piping, but I still like to have the mail delivered to my email client (Thunderbird) to ensure I don't accidentally miss something. Thunderbird does a good job of routing them to the Junk folder, so I can peruse through or delete as necessary. Email piping works great, and having them route to HESK has been a huge help in managing my support business.
Thanks in advance,
Jason
Re: Can Email Piping reject emails w/out existing ticket?
Try this:
1. backup existing inc/pipe_functions.inc.php file
2. open the file in a powerful text editor that can properly encode files, such as Notepad++
3. find line4. just ABOVE that line add 5. save, upload and test
That should discard any email with a subject that STARTS with *** SPAM ***, but still allow *** SPAM *** in other parts of subject, so it doesn't block legit inquiries such as "Why are my emails marked with *** SPAM *** when I receive them?"
P.s.: in the future yes, if your question is unrelated to the topic, please create a new topic.
1. backup existing inc/pipe_functions.inc.php file
2. open the file in a powerful text editor that can properly encode files, such as Notepad++
3. find line
Code: Select all
// Process email message, convert to UTF-8
Code: Select all
if (strpos($tmpvar['subject'], '*** SPAM ***') === 0)
{
return hesk_cleanExit();
}
That should discard any email with a subject that STARTS with *** SPAM ***, but still allow *** SPAM *** in other parts of subject, so it doesn't block legit inquiries such as "Why are my emails marked with *** SPAM *** when I receive them?"
P.s.: in the future yes, if your question is unrelated to the topic, please create a new topic.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
You should follow me on Twitter here
Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools


Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools
-
- Posts: 18
- Joined: Thu Sep 04, 2014 12:02 pm
Re: Can Email Piping reject emails w/out existing ticket?
Thanks Klemen! It's been a few days and I haven't seen a single ***SPAM*** email create a ticket, so it seems to be working like a champ. I still get spam mail tickets, but only because they are being missed by SpamAssassin and not tagged as spam.
I had upgraded to 2.7.3 prior to testing out the spam rejection code so am current for now, but will I need to add this code manually to subsequent updates? No problem if not, just want to make sure I save this and do so at the next upgrade.
Thanks again...
Jason
I had upgraded to 2.7.3 prior to testing out the spam rejection code so am current for now, but will I need to add this code manually to subsequent updates? No problem if not, just want to make sure I save this and do so at the next upgrade.
Thanks again...
Jason
Re: Can Email Piping reject emails w/out existing ticket?
Yes, for now you will need to manually update the code when needed. It may be added as a new setting in the future though.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
You should follow me on Twitter here
Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools


Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...
Also browse for php hosting companies, read php books, find php resources and use webmaster tools