Where is the best place to deny a message?

Use this forum if you have problems with a hMailServer script, such as hMailServer WebAdmin or code in an event handler.
Post Reply
User avatar
Nime
Normal user
Normal user
Posts: 123
Joined: 2009-03-12 11:50
Contact:

Where is the best place to deny a message?

Post by Nime » 2016-02-01 09:56

I want to cut down the unnecessary traffic & disk usage. Currently I disable the account if it's inactive for a year. It's not a good solution for returning users. Now I decided to deny their incoming messages instead of making the account inactive.

So where is the best place in the events to check the last seen and deny the new messages of a user? OnDeliverMessage or OnAcceptMessage? What should I do if the message has multiple recipients? Can I remove a recipient from the list if it's not readonly?

Any suggestions?

User avatar
mattg
Moderator
Moderator
Posts: 21267
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: Where is the best place to deny a message?

Post by mattg » 2016-02-01 11:07

OnSMTPData will gine you a from address >> https://www.hmailserver.com/documentati ... onSMTPdata
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

User avatar
jimimaseye
Moderator
Moderator
Posts: 8917
Joined: 2011-09-08 17:48

Re: Where is the best place to deny a message?

Post by jimimaseye » 2016-02-01 13:53

Full order of execution (events) here: https://www.hmailserver.com/documentati ... ce_scripts
5.7 on test.
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829

Post Reply