Giter VIP home page Giter VIP logo

mailin's People

Contributors

bryant1410 avatar cbab avatar davidtanner avatar flolagale avatar inxilpro avatar jimihford avatar josnidhin avatar kennethlimcp avatar mbuk avatar mefernandez avatar nikolaygalkin avatar nmai avatar placeba avatar rightfold avatar tomforster avatar xpepermint avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mailin's Issues

Mailin Failing SPF and DKIM detection

Just moved over to v3.0.1 from v1.0.1 and mails I am sending are failing dkim/spf validation. Looking through the logs, I am getting some errors from the python scripts. (these emails shouldn't be failing dkim/spf)

2015-09-08T22:02:41.809Z - verbose: f0460130-046f-43a7-a8f0-55298773006b Validating dkim.
2015-09-08T22:02:41.848Z - verbose: f0460130-046f-43a7-a8f0-55298773006b Validating spf.
2015-09-08T22:02:41.868Z - verbose: f0460130-046f-43a7-a8f0-55298773006b Parsing email.
2015-09-08T22:02:42.326Z - verbose:  responseCode=0, responseMessage=EX_OK, isSpam=false, spamScore=0, baseSpamScore=5, report=[score=0.0, name=FREEMAIL_FROM, description=Sender email is commonly abused enduser mail provider (matkle414[at]gmail.com)
-0.0 NO_RELAYS              Informational, type=message, score=0.0, name=HTML_MESSAGE, description=BODY, type=HTML]
2015-09-08T22:02:42.345Z - verbose: [verifydkim.py] isDkimValid = False

2015-09-08T22:02:42.369Z - verbose: closed with return code 11
2015-09-08T22:02:42.538Z - verbose: [verifyspf.py] (none, )

2015-09-08T22:02:42.539Z - verbose: closed with return code 11

There is also an error with the mail path, (referencing the earlier issue #51 i brought us).

2015-09-08T22:02:42.612Z - error: f0460130-046f-43a7-a8f0-55298773006b Unable to finish processing message!! TypeError: path must be a string
  at TypeError (native)
  at Object.fs.unlink (fs.js:878:11)
  at Object.unlink 

It looks like the connection.mailPath is sent in as undefined. I will see to debugging a bit more to try and narrow down both problems.

Having difficulty using parsed results

For the life of me I cannot figure out how to grab a simple field like the sender's name or the plaintext body from the parsed results. Can anyone show me a quick example?

I'll put up some examples of what I've tried tomorrow but I thought I'd ask this before I crash..

Where are message attachments?

Hello,
I was trying to send email with pdf file but in mailin message event handler I get only these fields in attachments attribute of data variable:

 [ { contentType: 'application/pdf',
       contentDisposition: 'attachment',
       fileName: 'request.pdf',
       generatedFileName: 'request.pdf',
       contentId: '9d35d04b15f736a56b8ea607ea69fae4@mailparser' } ],

In examples there is always some content field with file data.. Am I missing something? How can I retrieve data of sent PDF? Can you help me please?

p: mailin._smtp should have public getter

I can't imagine not to customize SMTP for security reasons thus I would propose to make _smtp variable inside mailin public. At the moment we can read it like _smtp but interacting with it would mean doing a hack on a private variable. If we add get smtp getter the variable would become part of an official API.

I would also propose _convertTextToHtml and _convertHtmlToText to be public methods.

What do you think (before PR :) )?

Error message "Webhook seems invalid or down" despite accessible URL

Hi there!

I'm using mailin version 3.0.1 from command line, like this:

mailin --webhook http://localhost:3000/emails

When it starts up, a warning is shown:

warn: Webhook http://localhost:3000/emails seems invalid or down. You may want to double check the webhook url.

I've curled that URL from the machine mailin is running, and it seems ok.

curl -X HEAD -I http://localhost:3000/emails

HTTP/1.1 200 OK
X-Powered-By: Express
Date: Tue, 15 Dec 2015 11:08:39 GMT
Connection: keep-alive

So, I started mailin with node-debug and set a breakpoint at this line of code:

node-debug /usr/lib/node_modules/mailin/cli.js --webhook http://localhost:3000/emails --port 2500

I've found this:

/* Check the webhook validity. */
    if (!configuration.disableWebhook) {
        request.head({
            url: configuration.webhook,
            timeout: 3000
        }, function (err, resp) {
            if (err || resp.statusCode !== 200) {
                logger.warn('Webhook ' + configuration.webhook +
                    ' seems invalid or down. You may want to double check the webhook url.');
            } else {
                logger.info('Webhook ' + configuration.webhook + ' is valid, up and running.');
            }
        });
    }

In spite of configuration.webhook being Ok, function is called with this err:

image

It looks like superagent is calling 127.0.0.1:80 instead of what's in configuration.webhook. S

I've taken a look at current superagent docs, and it seems requests are done somewhat differently.

request
  .head('/favicon.ico')
  .end(function(err, res){

  });

Maybe there's been a change in superagent API.

Shall I fork+pull request?

Node v4.1.0

Hi,

Is it possible to upgrade to Node v4.1.0 ?
I am receiving:

Your current node version (v4.1.0) is not compatible with Mailin v3.0.1 which requires node ~0.12.4.
If you are running an older version of node, please consider installing Mailin ^2.0.0 (npm install [email protected])

Thanks

ENOENT when processing incoming message

I randomly get the following error when running. It doesn't happen on every message.

verbose: Validating spf.
verbose: Parsing email.
OUT: "250 2.0.0 Ok: queued as 6bb731f4038f12a8e7c6"
COMMAND:
{ [Error: ENOENT, open '.tmp/5536ed281ced6be3342688908dc292b707e70746']
errno: 34,
code: 'ENOENT',
path: '.tmp/5536ed281ced6be3342688908dc292b707e70746' }
We got an error when trying to read the file!!!
error: Error: ENOENT, open '.tmp/5536ed281ced6be3342688908dc292b707e70746'

events.js:72
throw er; // Unhandled 'error' event
^
Error: ENOENT, open '.tmp/5536ed281ced6be3342688908dc292b707e70746'
info: Mailin stopped.

Can't configure network interface to listen on

I followed the instructions to set up mailin, and I can get it to listen on localhost:

$ telnet localhost 25
Trying ::1...
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 localhost ESMTP Mailin Smtp Server

But it isn't listening on my actual public IP:

$ telnet 54.97.96.117 25
Trying 54.97.96.117...
telnet: Unable to connect to remote host: Connection refused

Perhaps I configured it wrong. But I've also noticed that my server is perhaps configured to think that is name is localhost:

$ echo $HOSTNAME
localhost

Is there something to do to fix my server config? Can't I just tell mailin "Hey, listen on interface eth0!"?

Access to simplesmtp's secureConnection & credentials

We should have access to underlying simplesmtp server or options at simplesmtp.createServer(options)

Option 1:
Mailin.start(options, callback) should take in options['smtpOptions'] and merge to options passed to simplesmtp.createServer(options).

Option 2:
Expose 'var smtp' to mailin class.

message.date not valid json

In an email sent from gMail I'm seeing:

  ...
  to: [ { address: '[email protected]', name: '' } ],
  date: Sat Jun 28 2014 20:55:13 GMT-0400 (EDT),
  dkim: 'pass',
  ....

where date needs to be a string to be valid json. This is using your example code in Node.js

mailin/test/utils/server.js outdated?

Hello there and thanks for sharing mailin!
I am quite new to node.js, but I think the server.js script is outdated for current version of the Express API?
I would like to test the webhook using this code :) Any help is appreciated!

Sender field is always empty

I tried the service at http://mailin.io/, the sender field is always empty. Must be a bug. This is an example of the same header in Gmail:

...
Subject: test Thu, 28 Aug 2014 23:24:53 -0400
X-Mailer: swaks v20130209.0 jetmore.org/john/code/swaks/
Sender: <[email protected]>
DKIM-Signature: v=1;a=rsa-sha25...
....

Duplicated params?

Hi!

Could you please explain the difference between envelopeFrom/envelopeTo and from/to?

Thank you!

Attachments are not being parsed

Hi there! First off: I am amazed by mailin, awesome piece of software. Saved me days in development. I have a slight issue with the attachments though:


I am not using the webhook, but rather the embedded mailin server. For that, I plugged myself into mailin.on('message', function(connection, data, content) {});. And this works fine, but somehow data.attachments is always non-existing. For debugging I printed both data and content:

Excerpt from content:

--Apple-Mail=_1CE57DD1-5830-4E39-BB06-17F285909745
Content-Disposition: attachment; filename=X
Content-Type: application/octet-stream;name="X"
Content-Transfer-Encoding: 7bit

TEST

But in data (shortened):

  { html: 'html',
    headers:
     { received: [ Object object ],
       from: 'Julian Krenge <[email protected]>',
       to: 'Tracking Agent <[email protected]>',
       subject: 'test',
       'thread-topic': 'test',
       'thread-index': 'AQHRJ1UYzntn5mE26ECrsi6sDecCjw==',
       date: 'Wed, 25 Nov 2015 07:44:20 +0000',
       'message-id': '<[email protected]>',
       'accept-language': 'de-DE, en-US',
       'content-language': 'en-US',
       'x-ms-has-attach': 'yes',
       'x-ms-tnef-correlator': '',
       'authentication-results': 'spf=none (sender IP is ) [email protected];',
       'x-ms-exchange-messagesentrepresentingtype': '1',
       'x-originating-ip': '[77.47.69.145]',
       'x-microsoft-exchange-diagnostics': 'string,
       'x-microsoft-antispam': 'UriScan:;BCL:0;PCL:0;RULEID:;SRVR:AMXPR07MB184;',
       'x-ld-processed': 'c9ad2ae3-2857-429e-bddf-50e548a323c0,ExtAddr',
       'x-microsoft-antispam-prvs': '<AMXPR07MB184102A08E5ECE495676F2CC6050@AMXPR07MB184.eurprd07.prod.outlook.com>',
       'x-exchange-antispam-report-test': 'UriScan:;',
       'x-exchange-antispam-report-cfa-test': 'BCL:0;PCL:0;RULEID:(601004)(2401047)(5005006)(8121501046)(520078)(10201501046)(3002001);SRVR:AMXPR07MB184;BCL:0;PCL:0;RULEID:;SRVR:AMXPR07MB184;',
       'x-forefront-prvs': '0771670921',
       'x-forefront-antispam-report': 'string',
       'received-spf': 'None (protection.outlook.com: parcellab.com does not designate permitted sender hosts)',
       spamdiagnosticoutput: '1:23',
       spamdiagnosticmetadata: 'NSPM',
       'content-type': 'multipart/signed; boundary="Apple-Mail=_F0CC39CA-E1ED-482A-B618-7EFEA7071FED"; protocol="application/pkcs7-signature"; micalg=sha1',
       'mime-version': '1.0',
       'x-originatororg': 'parcellab.com',
       'x-ms-exchange-crosstenant-originalarrivaltime': '25 Nov 2015 07:44:20.6059 (UTC)',
       'x-ms-exchange-crosstenant-fromentityheader': 'Hosted',
       'x-ms-exchange-crosstenant-id': 'c9ad2ae3-2857-429e-bddf-50e548a323c0',
       'x-ms-exchange-transport-crosstenantheadersstamped': 'AMXPR07MB184' },
    subject: 'test',
    messageId: '[email protected]',
    priority: 'normal',
    from: [ Array ],
    to: [ Array ],
    date: Wed Nov 25 2015 07:44:20 GMT+0000 (UTC),
    receivedDate: Wed Nov 25 2015 07:44:21 GMT+0000 (UTC),
    dkim: 'failed',
    spf: 'failed',
    spamScore: 0,
    language: 'romanian',
    cc: [],
    connection: [ Object object ],
    envelopeFrom: { address: '[email protected]', args: false },
    envelopeTo: [ { address: '[email protected]', args: false } ] }

Then I tried to check the webhook: But enabling this even throws an exception and mailin crashes.

Any ideas? :-)

Feature request: Alternate HTML to text method

I've found that using Cheerio for HTML to Text conversion isn't ideal. There's a great project called Node HTML to Text that uses htmlparser to parse the HTML contents and the intelligently formats it such that:

<h1>Hello world</h1>
<p>Lorem <a href="http://www.google.com/">ipsum</a> dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. 
Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in 
culpa qui officia deserunt mollit anim id est laborum.</p>

Becomes:

HELLO WORLD

Lorem ipsum [http://www.google.com] dolor sit amet, 
consectetur adipisicing elit, sed do eiusmod tempor incididunt ut 
labore et dolore magna aliqua. Ut enim ad minim veniam, quis 
nostrud exercitation ullamco laboris nisi ut aliquip ex ea 
commodo consequat. Duis aute irure dolor in reprehenderit in 
voluptate velit esse cillum dolore eu fugiat nulla pariatur. 
Excepteur sint occaecat cupidatat non proident, sunt in culpa 
qui officia deserunt mollit anim id est laborum.

Would you be open to a pull request that replaces the current implementation with node-html-to-text?

Better documentation - smtpOptions

I spent about an hour trying to figure out why I could not get my Jenkins CI/CD server to work with mailin. I finally realized that I needed to pass this in:

'smtpOptions': {
    'disableDNSValidation': true
}

I realize this option is for a separate library used by mailin, but it seems like mailin's documentation could at least point out the fact that if they run into issues, they may need to investigate simplesmtp.

memory leak when profile:true?

When using mailin with profile: true like this

 */
mailin.start({
  profile: true,
  ...
});

i see the Ram Usage property increase every second. I guess this is because of the output itself but still...

v2.0.0

could not find this versino,

Just a question really

Have you given any thought to extending this to save the mail to a noSQL // SQL storage layer?

I'd love to be able to drop this into a user facing web app so that I can have my users receive, read and respond to mail through a url like project/admin/mail.

Test failure due to error in test spec config

The test "should validate sender domain DNS if requested" is failing due to the config error in mailinSpec.js.

            mailin.start({
                disableDnsValidation: false, // wrong
                smtpOptions: {
                    disabledCommands: ['AUTH'],
                    secure: false
                }
            }, function (err) {...});

it should be the following according to the configuration object in lib/mailin.js

            mailin.start({
                disableDNSValidation: false, // correct
                smtpOptions: {
                    disabledCommands: ['AUTH'],
                    secure: false
                }
            }, function (err) {...});

Link to that line
https://github.com/Flolagale/mailin/blob/master/test/mailinSpec.js#L335

Webhook called even with disableWebhook: true?

Hey,
am I missing something here or is the webhook called even when I set disableWebhook to true?
Looking in the code, I see that the function "postWebhook" is always called.

Thanks in advance

Security best practices

Are there any security best practices you can recommend related to large email size or attachment size? For example, if someone wanted to spam your system with a barrage of emails that have 20MB+ attachment sizes, things would get slow.

SPF Validation error in the Code

You are using:

return mailUtilities.validateSpfAsync(connection.remoteAddress, connection.from, connection.clientHostname)

but connection.from is null

should be:

connection.envelope.mailFrom.address

ECONNRESET upon receiving message

@Flolagale I love the simplicity of mailin ... I hope we can keep it around. Simplest implementation here - it throws an ECONNRESET when an email is received. I'm sending it to [email protected] from an Exchange server. Also tried from GMail. Same error thrown once the email comes in. Any suggestions?

var mailin = require('mailin');
mailin.start({ port: 25, disableWebhook: true });
mailin.on('message', function (connection, data, content) { console.log(data); });

Error: write ECONNRESET
at errnoException (net.js:904:11)
at Socket._write (net.js:645:26)
at doWrite (_stream_writable.js:225:10)
at writeOrBuffer (_stream_writable.js:215:5)
at Socket.Writable.write (_stream_writable.js:182:11)
at Socket.write (net.js:615:40)
at write (_stream_readable.js:601:24)
at flow (_stream_readable.js:610:7)
at EncryptedStream.pipeOnReadable (_stream_readable.js:642:5)
at EncryptedStream.emit (events.js:92:17)

BCC support

is BCC supported? I tried your demo page http://mailin.io/ and put the address in the BCC field and nothing went to your app. I was wondering if BCC is supported?

Thanks

issues with file path

Having some issues getting the reports back after upgrading to 3.0.1 from 1.0.1

Here is the log:

2015-08-24T02:20:09.544Z - error: 6a071431-62db-4e39-a01f-3d66215a17b8 Unable to finish processing message!! TypeError: path must be a string
  at TypeError (native)
  at Object.fs.unlink (fs.js:878:11)
  at Object.unlink (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/loopback/node_modules/continuation-local-storage/node_modules/async-listener/index.js:19:15)
  at Object.tryCatcher (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/node_modules/bluebird/js/main/util.js:26:23)
  at Object.ret [as unlinkAsync] (<anonymous>:14:23)
  at unlinkFile (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/lib/mailin.js:408:19)
  at tryCatcher (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/node_modules/bluebird/js/main/util.js:26:23)
  at Promise._settlePromiseFromHandler (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/node_modules/bluebird/js/main/promise.js:503:31)
  at Promise._settlePromiseAt (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/node_modules/bluebird/js/main/promise.js:577:18)
  at Promise._settlePromises (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/node_modules/bluebird/js/main/promise.js:693:14)
  at Async._drainQueue (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/node_modules/bluebird/js/main/async.js:123:16)
  at Async._drainQueues (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/node_modules/bluebird/js/main/async.js:133:10)
  at Immediate.Async.drainQueues (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/mailin/node_modules/bluebird/js/main/async.js:15:14)
  at Immediate._onImmediate (/var/lib/strong-pm/svc/1/work/76cd4c0a88b529881f91f24e001600d55726d8c4.1440382413477/node_modules/loopback/node_modules/continuation-local-storage/node_modules/async-listener/glue.js:188:31)
  at processImmediate [as _immediateCallback] (timers.js:358:17)

Its an error with the mailPath variable on that line (408 in lib/mailin.js), as its being sent in undefined. I am using the default path for the temp directory, without a web hook.

var options = {
    port: 2500,
    disableWebhook: true,
    logFile: __dirname + '/../../client/mailin.io.log',
    logLevel: 'info'
  }

Mailin not using my options and AUTH LOGIN command not working

Hi guys Mailin is not applying my options to the server. Also the events are not emitted after a connection is established with the smtp server.

screen shot 2015-07-26 at 9 12 59 am

screen shot 2015-07-26 at 9 14 51 am

I am struggling to get the server working with a small hunting camera that needs to send emails to the server.

Receive notifications

Is there a way to connect a smartphone to server and receive inbox notifications?

Like notifications of gmail...

Mailin in node app listening to single ip

I'm using mailin embedded in my node app, but I need it to only listen to port 25 on a single IP.
Using netstat I can see node listening to 0.0.0.0:25, but I want it to listen to a.b.c.d:25 only
Is that possible?

From your code I thought that adding the option host: 'a.b.c.d' to the options in mailin.start() might help, but I still see 0.0.0.0:25

Am I overseeing something?

Update version requirements?

The docs says iojs 2.0 is required, but it seems to work fine with 3.2 as well, despite the warnings. Granted, I've only done some basic testing. But unless there are specific reasons why it shouldn't work with newer versions, maybe the warnings should be removed. Alternatively, how about saying WHY the specific version is required so people can fix it or have an idea of when it should be working with more modern versions?

Attachments array keys & PHP

Hi!

There is a problem described below:
http://stackoverflow.com/questions/68651/get-php-to-stop-replacing-characters-in-get-or-post-arrays
http://ca.php.net/manual/en/language.variables.external.php#81080

e.g. if I have attachment file:

fileName":"Folder.jpg", "generatedFileName":"Folder.jpg"

on PHP side I'll get an array key

'Folder_jpg'

So, may be it's better to generate unique keys for attachments array OR generate "generatedFileName" to bypass that problem?

Thank you!

Server sample is using old express

Thanks for the great package and documentation. I'm just getting started but found a problem with server.js. I think you just added this back in and used an older version. perhaps? It express packages no longer supports server.router. But, I see that you fixed this issue in an earlier update.

In any case I just commented out the server.use(server.router) line and the server now starts. I haven't yet tried using it.

Question

Greetings! This looks awesome. I'm wondering how one would go about replying to an email. I don't have a super solid understanding of SMTP. Because this system takes over the DNS, I'd have to reply from this server? Or could another Node SMTP service reply as well.

Thanks!

spamd Error

When i process message, i get this error:

Error: spamd returned a error: Error: connect ECONNREFUSED 127.0.0.1:783

which is result in multiple error:
Unable to compute spam score. Set spam score to 0.
Error: Unable to compute spam score.
TypeError: Cannot read property 'match' of undefined

Is it possible to forward email

from some accounts to some other accounts

just remark, It is really strange that you choose not to add config file for mailing, rather use super simple single route.

why not simple plain text config that would say something like

[email protected] -> http://domain1.com/mail_hook
[email protected] -> http://domain1.com/mail_hook
*@domain1.com -> [email protected]
[email protected] -> destroy

[email protected] -> http://domain2.com/mail_hook
*@domain2.com -> [email protected]

node 4.2.4 support

Hi Florent thanks for the awesome npm module, I have a quick question. Have you tested mailin on node 4.x?

I realized I have two express based applications that run mailin internally and the application that's still on node 0.12.6 works, but node 4.2.4.

I did a quick check to see if mailin was actually running on port 25, and as expected on node 4.2.4 the module emits info: Mailin Smtp server listening on port 25 but does not in fact run on port 25.

node 4.2.4

ubuntu@pcs-app2-prod:~$ sudo lsof -i -P | grep *:
dhclient    678     root    5u  IPv4   7716      0t0  UDP *:68 
dhclient    678     root   20u  IPv4   7678      0t0  UDP *:51930 
dhclient    678     root   21u  IPv6   7679      0t0  UDP *:18479 
sshd       1056     root    3u  IPv4   9212      0t0  TCP *:22 (LISTEN)
sshd       1056     root    4u  IPv6   9214      0t0  TCP *:22 (LISTEN)
nginx      1252     root    6u  IPv4   9406      0t0  TCP *:80 (LISTEN)
nginx      1252     root    7u  IPv6   9407      0t0  TCP *:80 (LISTEN)
nginx      1253 www-data    6u  IPv4   9406      0t0  TCP *:80 (LISTEN)
nginx      1253 www-data    7u  IPv6   9407      0t0  TCP *:80 (LISTEN)
nginx      1254 www-data    6u  IPv4   9406      0t0  TCP *:80 (LISTEN)
nginx      1254 www-data    7u  IPv6   9407      0t0  TCP *:80 (LISTEN)
nginx      1255 www-data    6u  IPv4   9406      0t0  TCP *:80 (LISTEN)
nginx      1255 www-data    7u  IPv6   9407      0t0  TCP *:80 (LISTEN)
nginx      1256 www-data    6u  IPv4   9406      0t0  TCP *:80 (LISTEN)
nginx      1256 www-data    7u  IPv6   9407      0t0  TCP *:80 (LISTEN)
ntpd       1530      ntp   16u  IPv4  10876      0t0  UDP *:123 
ntpd       1530      ntp   17u  IPv6  10877      0t0  UDP *:123 
node      15766     root   12u  IPv6 132402      0t0  TCP *:8786 (LISTEN)

versus node 0.12.6

ubuntu@pcs-app1-prod:~$ sudo lsof -i -P | grep *:
dhclient   680     root    5u  IPv4   8258      0t0  UDP *:68 
dhclient   680     root   20u  IPv4   8123      0t0  UDP *:37529 
dhclient   680     root   21u  IPv6   8124      0t0  UDP *:38796 
sshd      1049     root    3u  IPv4   8542      0t0  TCP *:22 (LISTEN)
sshd      1049     root    4u  IPv6   8544      0t0  TCP *:22 (LISTEN)
node      1197     root   12u  IPv6   9088      0t0  TCP *:25 (LISTEN)
node      1197     root   13u  IPv6   9089      0t0  TCP *:8786 (LISTEN)
nginx     1252     root    6u  IPv4   8837      0t0  TCP *:80 (LISTEN)
nginx     1252     root    7u  IPv6   8838      0t0  TCP *:80 (LISTEN)
nginx     1253 www-data    6u  IPv4   8837      0t0  TCP *:80 (LISTEN)
nginx     1253 www-data    7u  IPv6   8838      0t0  TCP *:80 (LISTEN)
nginx     1254 www-data    6u  IPv4   8837      0t0  TCP *:80 (LISTEN)
nginx     1254 www-data    7u  IPv6   8838      0t0  TCP *:80 (LISTEN)
nginx     1255 www-data    6u  IPv4   8837      0t0  TCP *:80 (LISTEN)
nginx     1255 www-data    7u  IPv6   8838      0t0  TCP *:80 (LISTEN)
nginx     1256 www-data    6u  IPv4   8837      0t0  TCP *:80 (LISTEN)
nginx     1256 www-data    7u  IPv6   8838      0t0  TCP *:80 (LISTEN)
ntpd      1527      ntp   16u  IPv4  10400      0t0  UDP *:123 
ntpd      1527      ntp   17u  IPv6  10401      0t0  UDP *:123 

cc @janbialostok

ISO-8859-8-I support

@Flolagale In the past this used to work, but currently I can't get it to work. Whenever I receive mail with UTF-8 all I get is question marks, which is also passed in the JSON to the webhook (A Python/Django server). I tried it on 2 machines, one with Ubuntu 14.04 and the second with Ubuntu Server.

The problem can be seen in the screenshot in the 'subject' and 'from' fields.
untitled

Address validation

Hi,

I have integrated mailin inside my nodejs app. I would like to know if its possible to reject emails on the validation event function for recipient address. I tried sending this as below -

callback(new Error('Email address format is invalid');

But this doesn't trigger the Mail Delivery Failure messages. Can you please help me out?

CLI params

Hi there!

Is it possible to use all params as CLI argv?

I mean like:

 mailin --disableDkim=true --disableSpf=true --disableSpamScore=true --verbose=true --debug=true --profile=true --logFile=logs/mailin.log --webhook=http://host.local

Thanks!

EnvelopeFrom address in Readme

The format for EnvelopeFrom in the README documentation seems to be wrong. EnvelopeFrom is not an array, just a single object. This makes sense since SMTP allows for a single return path in MAIL FROM (according to: http://cr.yp.to/smtp/mail.html).

Also, in the README, the comment about the options when embedding mailin inside a node application is wrong. Just had to look at the code to get the right arguments, but the "SMTPBanner" and "disableDNSValidation" do not match the code and might confuse users.

Thanks!

Empty payload (req.body) received by my app

Hi,

Starting mailin as root, it says it successfully posted an incoming email to my webhook.

But my (nodejs) app gets an empty request body.

mailin displays:
info: Receiving message from
info: Processing message from
info: Sending request to webhook http://localhost:3000/run/emailin
info: Convert attachments to strings
{ duration: '0ms' }
info: Succesfully posted to webhook http://localhost:3000/run/emailin
info: End processing message.

Is there a logging/debug option that I can use to see what is happening?

Colin G

License Type

Just wondering what the deal with the license for this project?

Can it be used commercially? Is it MIT? Apache? etc....

Cannot receive email from gmail

I can telnet to my server and successfully communicate with my mailin instance. I can also see console printouts from these communications on the server side. However, when I send an email from gmail or some other professional client, the mailin server is silent. It doesn't report errors or success. (I have tried multiple log levels, but to no avail.) I know this is not a problem with my server, since I created a simple SMTP server in Python and gmail can send messages to it. The only problem is likely some setup problem with mailin. Has anybody else encountered this problem?

I am using the no-webhook option, and embedding mailin in a node application, as set up in the bottom part of the README. Thanks in advance.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.