You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-user@james.apache.org by Lahu <la...@yahoo.com> on 2005/07/11 12:01:31 UTC

Invalid target MX IP !

Dear James, 

how do u handle outbound mails intended for MX records with target invalid target IP's like 127.0.0.1 or 0.0.0.0
For example, I have you configured as the endpoint in my environment, like the following description:

Internet -> James -> Trend AntiVirus -> Lotus Notes    (All on seperate machines with seperate IP Addresses)

I had an inbound spam to a non-existent address. My mail server naturally processed a bounce message to the original sender. Now, that sender domain has a target MX IP of 0.0.0.0. 
What happened was James ended up delivering the mail to itself again and again, creating a new message each time, which means that mail cant even be detected by the RelayHopLimit mailet. The resources swelled up soon !

Heres how to reproduce the thing:

1) James configured as the endpoint, delivering mail(s) via DNS delivery method.
2) The IP Address of the machine (NOT the localhost alias) is allowed to generate outbound mails, sort of Authorized IP.

Then try sending a message to this address:

some_address @ romymichele.com

I m running James 2.1.3 ( I know, a lot of banter on this ) on a windows 2003 Enterprise Edition.

Surprisingly, when sitting on the James machine i tried a telnet on 0.0.0.0 (25) myself, it was unable to create a connection. Whereas, I thought that i might be able to make a connection to James.

Am I missing something ?


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

RE: Invalid target MX IP !

Posted by Lahu <la...@yahoo.com>.
thanx Sefano and Jason !
both of u hav pointed me in the right direction... 
the story's a bit changed now.. mails intended for 0.0.0.0 r getting delivered to 192.168.1.30 ( my machine's internal network IP address ) See below in the mail headers and logs...
 
i was wrong abt that skipping thru the RelayLimitHop .that matcher isnt in my config :((
 otherwise this mail wudnt hav caused this situation... 
 
the delivery of such mails to the machine's IP address makes sense to me now; (thanx Jason for enlighting me) but is it valid anyway ?
 
this is the mail i caught in transit .. (in self-loop state)
================================================
 
Return-Path: <la...@mycompany.com>
Received: from lahu ([192.168.1.30])         // LOOPS ALL THE WAY 
 by mail2.mycompany.com (James Mail Server) with SMTP ID 281
          for <mo...@romymichele.com>;
          Mon, 11 Jul 2005 16:20:51 +0300 (GMT+03:00)
Received: from lahu ([192.168.1.30])
 by mail2.mycompany.com (James Mail Server) with SMTP ID 541
          for <mo...@romymichele.com>;
          Mon, 11 Jul 2005 16:19:44 +0300 (GMT+03:00)
Received: from lahu ([192.168.1.30])
 by mail2.mycompany.com (James Mail Server) with SMTP ID 568
          for <mo...@romymichele.com>;
          Mon, 11 Jul 2005 16:19:43 +0300 (GMT+03:00)
Received: from 192.168.1.1 ([192.168.1.1])    //  LOOK AT THIS , Original Sending Server
 by mail2.mycompany.com (James Mail Server) with SMTP ID 743
          for <mo...@romymichele.com>;
          Mon, 11 Jul 2005 16:19:41 +0300 (GMT+03:00)
MIME-Version: 1.0
To: montypeterpiper@romymichele.com
Subject: new test 0.0.0.0
Sensitivity: 
X-Mailer: Lotus Notes Release 6.5 September 26, 2003
Message-ID: <13...@lahu>
From: lahu@mycompany.com
Date: Mon, 11 Jul 2005 16:19:15 +0300
X-MIMETrack: Serialize by Router on RYDK/mycompany(Release 6.0.2CF1|June 9, 2003) at 07/11/2005
 04:19:22 PM,
 Serialize complete at 07/11/2005 04:19:22 PM
Content-Type: multipart/alternative; boundary="=_alternative 004933E24325703B_="

This is a multipart message in MIME format.
--=_alternative 004933E24325703B_=
Content-Type: text/plain; charset="US-ASCII"
Best regards,
lahu 
=====================================================
 
 
herez the SMTP Server log
======================
 
Retrieving a org.apache.james.smtpserver.SMTPHandler from the pool
11/07/05 16:07:02 DEBUG smtpserver: Getting SMTPHandler from pool.
11/07/05 16:07:06 INFO  smtpserver: Connection from 192.168.1.1 (192.168.1.1)
11/07/05 16:07:06 DEBUG smtpserver: Sent: 220 mail2.mycompany.com SMTP Server (James Mail Server) ready Mon, 11 Jul 2005 16:07:06 +0300 (GMT+03:00)
11/07/05 16:07:06 DEBUG smtpserver: Calling start()
11/07/05 16:07:06 DEBUG smtpserver: Watchdog default Worker #140 has time to sleep 360000
11/07/05 16:07:06 DEBUG smtpserver: Command received: EHLO mycompany.com
11/07/05 16:07:06 DEBUG smtpserver: Sent: 250-SIZE 20971520
11/07/05 16:07:06 DEBUG smtpserver: Sent: 250 mail2.mycompany.com Hello mycompany.com (192.168.1.1 [192.168.1.1])
11/07/05 16:07:06 DEBUG smtpserver: Calling reset() default Worker #140
11/07/05 16:07:06 DEBUG smtpserver: Command received: MAIL FROM:<la...@mycompany.com>
11/07/05 16:07:06 DEBUG smtpserver: Sent: 250 Sender <la...@mycompany.com> OK
11/07/05 16:07:06 DEBUG smtpserver: Calling reset() default Worker #140
11/07/05 16:07:06 DEBUG smtpserver: Command received: RCPT TO:<mo...@romymichele.com>
11/07/05 16:07:06 DEBUG smtpserver: Sent: 250 Recipient <mo...@romymichele.com> OK
11/07/05 16:07:06 DEBUG smtpserver: Calling reset() default Worker #140
11/07/05 16:07:06 DEBUG smtpserver: Command received: DATA
11/07/05 16:07:06 DEBUG smtpserver: Sent: 354 Ok Send data ending with <CRLF>.<CRLF>
11/07/05 16:07:06 DEBUG smtpserver: Using SizeLimitedInputStream  with max message size: 20971520
11/07/05 16:07:06 DEBUG smtpserver: Successfully spooled mail )Mail1121087226531-123 from lahu@mycompany.com for [montypeterpiper@romymichele.com]
11/07/05 16:07:06 DEBUG smtpserver: Sent: 250 Message received
11/07/05 16:07:06 DEBUG smtpserver: Calling reset() default Worker #140
11/07/05 16:07:06 DEBUG smtpserver: Command received: QUIT
11/07/05 16:07:06 DEBUG smtpserver: Sent: 221 mail2.mycompany.com Service closing transmission channel
11/07/05 16:07:06 DEBUG smtpserver: Calling stop() default Worker #140
11/07/05 16:07:06 DEBUG smtpserver: Closing socket.
11/07/05 16:07:06 DEBUG smtpserver: Calling disposeWatchdog() default Worker #140
11/07/05 16:07:06 DEBUG smtpserver: Returning SMTPHandler to pool.
11/07/05 16:07:06 DEBUG smtpserver: Returning a org.apache.james.smtpserver.SMTPHandler to the pool
11/07/05 16:07:06 DEBUG smtpserver: Watchdog default Worker #140 is exiting run().
11/07/05 16:07:08 DEBUG smtpserver: Retrieving a org.apache.james.smtpserver.SMTPHandler from the pool
11/07/05 16:07:08 DEBUG smtpserver: Getting SMTPHandler from pool.
11/07/05 16:07:08 INFO  smtpserver: Connection from lahu (192.168.1.30)
11/07/05 16:07:08 DEBUG smtpserver: Sent: 220 mail2.mycompany.com SMTP Server (James Mail Server) ready Mon, 11 Jul 2005 16:07:08 +0300 (GMT+03:00)
11/07/05 16:07:08 DEBUG smtpserver: Calling start()
11/07/05 16:07:08 DEBUG smtpserver: Watchdog default Worker #133 has time to sleep 360000
11/07/05 16:07:08 DEBUG smtpserver: Command received: HELO mail2.mycompany.com
11/07/05 16:07:08 DEBUG smtpserver: Sent: 250 mail2.mycompany.com Hello mail2.mycompany.com (lahu [192.168.1.30])
11/07/05 16:07:08 DEBUG smtpserver: Calling reset() default Worker #133
11/07/05 16:07:08 DEBUG smtpserver: Command received: MAIL FROM:<la...@mycompany.com>
11/07/05 16:07:08 DEBUG smtpserver: Sent: 250 Sender <la...@mycompany.com> OK
11/07/05 16:07:08 DEBUG smtpserver: Calling reset() default Worker #133
11/07/05 16:07:08 DEBUG smtpserver: Command received: RCPT TO:<mo...@romymichele.com>
11/07/05 16:07:08 DEBUG smtpserver: Sent: 250 Recipient <mo...@romymichele.com> OK
11/07/05 16:07:08 DEBUG smtpserver: Calling reset() default Worker #133
11/07/05 16:07:08 DEBUG smtpserver: Command received: DATA
11/07/05 16:07:08 DEBUG smtpserver: Sent: 354 Ok Send data ending with <CRLF>.<CRLF>
11/07/05 16:07:08 DEBUG smtpserver: Using SizeLimitedInputStream  with max message size: 20971520
11/07/05 16:07:08 DEBUG smtpserver: Successfully spooled mail )Mail1121087228093-124 from lahu@mycompany.com for [montypeterpiper@romymichele.com]
11/07/05 16:07:08 DEBUG smtpserver: Sent: 250 Message received
11/07/05 16:07:08 DEBUG smtpserver: Calling reset() default Worker #133
11/07/05 16:07:08 DEBUG smtpserver: Command received: QUIT
11/07/05 16:07:08 DEBUG smtpserver: Sent: 221 mail2.mycompany.com Service closing transmission channel
11/07/05 16:07:08 DEBUG smtpserver: Calling stop() default Worker #133
11/07/05 16:07:08 DEBUG smtpserver: Closing socket.
11/07/05 16:07:08 DEBUG smtpserver: Calling disposeWatchdog() default Worker #133
11/07/05 16:07:08 DEBUG smtpserver: Returning SMTPHandler to pool.
11/07/05 16:07:08 DEBUG smtpserver: Returning a org.apache.james.smtpserver.SMTPHandler to the pool
11/07/05 16:07:08 DEBUG smtpserver: Watchdog default Worker #133 is exiting run().
==============================================================
==== Begin processing mail Mail1121087296687-189====
11/07/05 16:08:16 DEBUG spoolmanager: Processing Mail1121087296687-189 through root
11/07/05 16:08:16 DEBUG spoolmanager.root: Servicing mail: Mail1121087296687-189
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.All@a522a6
11/07/05 16:08:16 DEBUG spoolmanager.root: Servicing Mail1121087296687-189 by Postmaster aliasing mailet
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.UnBlock@1860038
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.LogHeader@787c16
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.SubjectStartsWith@1a9d1b
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.SenderIs@140984b
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.SenderIs@1ce669e
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.SenderIs@1b33a0e
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.SenderIs@1a8773c
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.SenderIs@12c3327
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@d24e3f
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@10f41e9
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@b05acd
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@1989b5
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@a00185
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.SkipSpamSize@3c9c31
11/07/05 16:08:16 DEBUG spoolmanager.root: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.OutgoingMail@aa233f
11/07/05 16:08:16 DEBUG spoolmanager.root: Servicing Mail1121087296687-189 by ToProcessor Mailet
11/07/05 16:08:16 DEBUG spoolmanager: Processed Mail1121087296687-189 through root
11/07/05 16:08:16 DEBUG spoolmanager: Result was outbound
11/07/05 16:08:16 DEBUG spoolmanager: ==== Begin processing mail Mail1121087296687-189====
11/07/05 16:08:16 DEBUG spoolmanager: Processing Mail1121087296687-189 through outbound
11/07/05 16:08:16 DEBUG spoolmanager.outbound: Servicing mail: Mail1121087296687-189
11/07/05 16:08:16 DEBUG spoolmanager.outbound: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.AttachmentFileNameIsRegex@9c2715
11/07/05 16:08:16 DEBUG spoolmanager.outbound: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.AttachmentFileNameIsRegex@3caa4b
11/07/05 16:08:16 DEBUG spoolmanager.outbound: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.AttachmentFileNameIsRegex@d0220c
11/07/05 16:08:16 DEBUG spoolmanager.outbound: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.AttachmentFileNameIsRegex@6b496d
11/07/05 16:08:16 DEBUG spoolmanager.outbound: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.AttachmentFileNameIsRegex@1a19458
11/07/05 16:08:16 DEBUG spoolmanager.outbound: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.All@1124746
11/07/05 16:08:16 DEBUG spoolmanager.outbound: Servicing Mail1121087296687-189 by ToProcessor Mailet
11/07/05 16:08:16 DEBUG spoolmanager: Processed Mail1121087296687-189 through outbound
11/07/05 16:08:16 DEBUG spoolmanager: Result was transport
11/07/05 16:08:16 DEBUG spoolmanager: ==== Begin processing mail Mail1121087296687-189====
11/07/05 16:08:16 DEBUG spoolmanager: Processing Mail1121087296687-189 through transport
11/07/05 16:08:16 DEBUG spoolmanager.transport: Servicing mail: Mail1121087296687-189
11/07/05 16:08:16 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@1e67e6a
11/07/05 16:08:16 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@1758500
11/07/05 16:08:16 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@6ed322
11/07/05 16:08:16 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@1e78c96
11/07/05 16:08:16 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@bf053f
11/07/05 16:08:16 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@f1916f
11/07/05 16:08:16 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.RecipientIs@18330bf
11/07/05 16:08:16 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.All@1f54c5f
11/07/05 16:08:16 DEBUG spoolmanager.transport: Servicing Mail1121087296687-189 by 
11/07/05 16:08:17 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.ReturnReceipt@1d49247
11/07/05 16:08:17 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.DelayedScheduling@cf829d
11/07/05 16:08:17 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.HostIs@1884a40
11/07/05 16:08:17 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.HostIs@c2ee15
11/07/05 16:08:17 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.CheckOutgoing@19cd75a
11/07/05 16:08:17 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.CheckOutgoing@1fe8ce8
11/07/05 16:08:17 DEBUG spoolmanager.transport: Checking Mail1121087296687-189 with org.apache.james.transport.matchers.CheckOutgoing@d4d66b
11/07/05 16:08:17 DEBUG spoolmanager.transport: Servicing Mail1121087296687-189 by RemoteDelivery Mailet
11/07/05 16:08:17 DEBUG spoolmanager: Processed Mail1121087296687-189-to-romymichele.com through transport
11/07/05 16:08:17 DEBUG spoolmanager: Result was ghost
11/07/05 16:08:17 DEBUG spoolmanager: ==== Removed from spool mail Mail1121087296687-189-to-romymichele.com====
====================================================================
 
Best Regards,
Lahu
 
 
 
> Jason wrote:
 
>0.0.0.0 is an "all networks, all ip's" identifier. This includes localhost
>(127.0.0.1) and any other IP addresses your machine may be listening on. So
>no, you can't connect to James on all the IP address it may be listening on.
>
>For example (on my winxp box)
>
>TCP 0.0.0.0:25 0.0.0.0:0 LISTENING
>TCP 0.0.0.0:80 0.0.0.0:0 LISTENING
>TCP 0.0.0.0:135 0.0.0.0:0 LISTENING
>TCP 0.0.0.0:443 0.0.0.0:0 LISTENING
>
>Means that something is listening on all available IP address on ports 25
>(James),80 (IIS HTTP) ,135 (NetBIOS) & 443 (IIS HTTPS). If you run netstat
>-an on your machine I'm sure you'll find a lot more.
>
>-- Jason
>
>> -----Original Message-----
> From: Stefano Bagnara [mailto:apache@bago.org]
> Sent: 11 July 2005 13:46
> To: 'James Users List'
> Subject: Re: Invalid target MX IP !
> 
> > True, thats wat my knowledge told me too.. but then how come
> > James was able to self-deliver it ?
> > Is *telnet*-ing to 0.0.0.0:25, different than wat James uses
> > to create a connection on 0.0.0.0:25 ?
> 
> Can you provide detailed james logs so we can see what's happen?
> 
> Stefano


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

RE: Invalid target MX IP !

Posted by Jason Webb <jw...@inovem.com>.
0.0.0.0 is an "all networks, all ip's" identifier. This includes localhost
(127.0.0.1) and any other IP addresses your machine may be listening on. So
no, you can't connect to James on all the IP address it may be listening on.

For example (on my winxp box)

  TCP    0.0.0.0:25             0.0.0.0:0              LISTENING
  TCP    0.0.0.0:80             0.0.0.0:0              LISTENING
  TCP    0.0.0.0:135            0.0.0.0:0              LISTENING
  TCP    0.0.0.0:443            0.0.0.0:0              LISTENING

Means that something is listening on all available IP address on ports 25
(James),80 (IIS HTTP) ,135 (NetBIOS) & 443 (IIS HTTPS). If you run netstat
-an on your machine I'm sure you'll find a lot more.

-- Jason

> -----Original Message-----
> From: Stefano Bagnara [mailto:apache@bago.org]
> Sent: 11 July 2005 13:46
> To: 'James Users List'
> Subject: Re: Invalid target MX IP !
> 
> > True, thats wat my knowledge told me too.. but then how come
> > James was able to self-deliver it ?
> > Is *telnet*-ing to 0.0.0.0:25, different than wat James uses
> > to create a connection on 0.0.0.0:25 ?
> 
> Can you provide detailed james logs so we can see what's happen?
> 
> Stefano
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
> For additional commands, e-mail: server-user-help@james.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: Invalid target MX IP !

Posted by Stefano Bagnara <ap...@bago.org>.
> True, thats wat my knowledge told me too.. but then how come 
> James was able to self-deliver it ?
> Is *telnet*-ing to 0.0.0.0:25, different than wat James uses 
> to create a connection on 0.0.0.0:25 ?

Can you provide detailed james logs so we can see what's happen?

Stefano


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: Invalid target MX IP !

Posted by Lahu <la...@yahoo.com>.
>AFAIK 0.0.0.0 is not an alias for localhost. Only 127.0.0.1 is an alias for
>localhost.

True, thats wat my knowledge told me too.. but then how come James was able to self-deliver it ?
Is *telnet*-ing to 0.0.0.0:25, different than wat James uses to create a connection on 0.0.0.0:25 ?
 
>> Surprisingly, when sitting on the James machine i tried a 
>> telnet on 0.0.0.0 (25) myself, it was unable to create a 
>> connection. Whereas, I thought that i might be able to make a 
>> connection to James.
>>
>> Am I missing something ?

>AFAIK 0.0.0.0 is not an alias for localhost. Only 127.0.0.1 is an alias for
>localhost.

>Stefano

		
---------------------------------
 Sell on Yahoo! Auctions  - No fees. Bid on great items.

Re: Invalid target MX IP !

Posted by Stefano Bagnara <ap...@bago.org>.
> Surprisingly, when sitting on the James machine i tried a 
> telnet on 0.0.0.0 (25) myself, it was unable to create a 
> connection. Whereas, I thought that i might be able to make a 
> connection to James.
> 
> Am I missing something ?

AFAIK 0.0.0.0 is not an alias for localhost. Only 127.0.0.1 is an alias for
localhost.

Stefano


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org