milter | Go package for writing milters
kandi X-RAY | milter Summary
kandi X-RAY | milter Summary
The milter package is a framework for writing milters (mail filters) for Sendmail and Postfix. To implement a milter, make a type that implements the Milter interface, listen on a Unix or TCP socket, and call Serve with that socket and a factory function that returns instances of your Milter type.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Serve accepts connections on the listener .
- readPacket reads a single packet .
- splitCStrings splits a byte slice into a slice of strings .
- stripBrackets returns s with the first two brackets .
- newConn returns a connection .
- encode encodes val as a byte array .
- decode decodes data into dest .
milter Key Features
milter Examples and Code Snippets
Community Discussions
Trending Discussions on milter
QUESTION
I'm writing a Milter for Postfix, that handles incoming messages in a server (Postfix+Dovecot) with virtual domains and users. Communication beetweend Postfix and the Milter are done with the Sendmail Milter Protocol V 2
I really need that Dovecot (and Postfix by consequence) does not reject messages with invalid recipient, because I need the Milter to do this check (and reject as weel).
This is needed because i'm writing a PEC mail server (Pec stand for Posta Elettronica Certificata, that is an Italian implementation for certified mail).
When receiving mails with incorrect recipient, I need to produce a specific receipt in a form of an e-mail.
But Postfix in this case (told by dovecot) reject the mail BEFORE sending it to the Milter.
I've tried to search this in the documentation, but were not able to find this specific need.
I've attached PostFix configuration....
...ANSWER
Answered 2021-Jun-01 at 15:13I've found a solution:
I need to set in main.cf
QUESTION
for a while now I am trying to install Spamassassin properly as root user with 'apt install spamassassin spamc'. The installation fails when it runs sa-compile producing following output:
...ANSWER
Answered 2021-Jan-15 at 09:01This seems like apt's problem (not SpamAssasin's). Please follow the general steps for solving this type of problems and let us know if they helped.
QUESTION
I have followed this tutorial to configure DKIM and Postfix on Debian 7 wheezy. These instructions are pretty much a standard on the interwebz.
I am using Gmail to send and receive emails using my own domain. I followed this instructions to achieve that.
My problem
I can send and receive emails but I can't manage to pass the DKIM test (at least with Gmail). After searching and struggling for a while I have come to the conclusion that the reason of my woes is that my message is getting multiple DKIM signatures (see mail.log below). And this, according to the DKIM directives is enough for the DKIM to fail.
But after reading about on how to solve the multiple signatures problem I found that absolutely all of these solutions refer to having 'amavis' installed. Thing is...I don't have it installed!
In any case these solutions mention changing postfix configurations related to the milters in master.cnf and/or main.cfn. For example, adding this to the 'receive_override_options' (again, I don't have that variable since I don't have amavis installed) should solve the issue:
...ANSWER
Answered 2018-Apr-24 at 09:52I managed to fix this some time ago after several trails and errors. Problem is I don't remember what exactly I did to solve it. I was playing with several parameters -sometimes simultaneously- without keeping any track (my bad). However, at some point everything worked!
Here are my configuration files. Hope they can guide/help someone.
/etc/postfix/master.cf
QUESTION
Is there any way that a milter under postfix can be told that a given client connection attempt failed specifically because of an authentication error?
Sometimes, my email server gets blasted with repeated SMTP authentication attempts from the same client, presumably in order to try to break through my security. I'm running a milter, and these attempts show up as a CONNECT followed by a CLOSE, with an error message in my postfix log that contains info like this:
...ANSWER
Answered 2017-Nov-27 at 17:08Well, after a week, I've gotten no responses, and I haven't found any way to make this happen. I will now assume that the answer to my question is "no".
QUESTION
I'm currently using postfix-2.11.3, and I am doing a lot of message processing through a milter. This processing takes place before the client is notified that the message is accepted, and it sometimes involves enough work that it delays the client's receipt of the initial SMTP 250 2.0.0 Ok: queued as xxxxxxxxxxx
message.
During large email blasts to my server, this milter processing can cause a backlog, and in some cases, the client connections time out while waiting for that initial 250 ...
message.
My question is this: if I rewrite my milter as a postfix after-queue filter with no before-queue processing, will clients indeed get the initial 250
messages right away, with perhaps subsequent SMTP messages coming later? Or will the 250
message still be deferred until after postfix completes the after-queue filtering?
And is it possible for an initial 250
message to be received by the client with a subsequent 4xx
or 5xx
message received and processed later by that same client, in case the after-queue filter decides to subsequently reject the message?
I know I could test this by writing an after-queue filter. However, my email server is busy, and I don't have a test server available, and so I'd like to know in advance whether an after-queue filter can behave in this manner.
Thank you for any wisdom you could share about this.
...ANSWER
Answered 2017-Nov-25 at 00:03I managed to set up a postfix instance on a test machine, and I was able to install a dummy after-queue filter. This allowed me to figure out the answer to my question. It turns out that postfix indeed sends the 250 2.0.0 Ok: queued as xxxxxxxxxxx
message before the after-queue filter completes.
This means that I can indeed move my slower milter processing to the after-queue filter in order give senders a quicker SMTP response.
QUESTION
I've created myself a mailserver with postfix, dovecot, spamasasin.. Was looking in the logs today and found a lot of this
...ANSWER
Answered 2017-Mar-09 at 11:50Remove this mynetworks = 0.0.0.0/0 [::ffff:127.0.0.0]/104 [::1]/128
And put only your networks
Your server is working as open relay
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install milter
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page