Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I need to determine if the ISP is blocking or closing a local port? 2

Status
Not open for further replies.

dogrofflog

Programmer
Mar 16, 2005
9
0
0
US
I need code to determine if port 25 is being blocked by the ISP (or any other program like that).

Thats it! Short and simple? I'll use any common ocx tha comes with VB6 if that works easy but maybe there is some solid API code out there (will work on 95,97, 2000, xp) that will get the job done too!

Thanks in advance!

 
Yes, the proxy interacts like a real SMTP server. It even claims to accept messages sent to it.
 
Real identities stripped, here's a trace of a short interaction:
[tt]
Capture Mode: ASCII
Client Port: 25
Server Port: 25
Server Host: fake.com
Capture file created: C:\Documents and Settings\xxxxxx\Desktop\smtp.log

Capture initiated: 03/17/2005 5:25:55 PM

Client connected. Port 25 Host [IP 127.0.0.1]

Server connected. Port 25 Host "fake.com" [IP 213.212.70.146]

<- 0000 32 32 30 20 41 56 47 20 45 53 4D 54 50 20 50 72 220 AVG ESMTP Pr
0010 6F 78 79 20 53 65 72 76 65 72 20 37 2E 30 2E 33 oxy Server 7.0.3
0020 30 37 2F 37 2E 30 2E 33 30 38 20 5B 32 36 36 2E 07/7.0.308 [266.
0030 37 2E 33 5D 0D 0A 7.3]..
-> 0000 48 45 4C 4F 20 70 61 76 6C 6F 76 0D 0A HELO pavlov..
<- 0000 32 35 30 20 6C 6F 63 61 6C 68 6F 73 74 20 48 65 250 localhost He
0010 6C 6C 6F 20 70 61 76 6C 6F 76 0D 0A llo pavlov..
-> 0000 4D 41 49 4C 20 46 52 4F 4D 3A 20 3C 42 6F 62 40 MAIL FROM: <Bob@
0010 62 6F 62 2E 63 6F 6D 3E 0D 0A bob.com>..
<- 0000 32 35 30 20 53 65 6E 64 65 72 20 6F 6B 0D 0A 250 Sender ok..
-> 0000 52 43 50 54 20 54 4F 3A 20 3C xx xx xx xx xx xx RCPT TO: <xxxxxx
0010 xx xx xx xx 40 79 61 68 6F 6F 2E 63 6F 6D 3E 0D xxxx@yahoo.com>.
0020 0A .
<- 0000 32 35 30 20 52 65 63 69 70 69 65 6E 74 20 6F 6B 250 Recipient ok
0010 0D 0A ..
-> 0000 44 41 54 41 0D 0A DATA..
<- 0000 33 35 34 20 4F 6B 2C 20 73 65 6E 64 20 74 68 65 354 Ok, send the
0010 20 6D 65 73 73 61 67 65 0D 0A message..
-> 0000 4D 65 73 73 61 67 65 2D 49 44 3A 20 3C 30 30 30 Message-ID: <000
0010 33 30 31 63 35 32 62 34 30 24 38 33 30 35 36 66 301c52b40$83056f
0020 38 30 24 62 34 37 62 61 38 63 30 40 70 61 76 6C 80$b47ba8c0@pavl
0030 6F 76 3E 0D 0A 52 65 70 6C 79 2D 54 6F 3A 20 22 ov>..Reply-To: "
0040 xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xx xxxxxx xxxxxxxxx
0050 22 20 3C 4D 72 52 6F 62 6F 74 6F 40 62 6F 62 2E " <MrRoboto@bob.
0060 63 6F 6D 3E 0D 0A 46 72 6F 6D 3A 20 22 xx xx xx com>..From: "xxx
0070 xx xx xx xx xx xx xx xx xx xx xx xx xx 22 20 3C xxxxxxxxxxxxx" <
0080 42 6F 62 40 62 6F 62 2E 63 6F 6D 3E 0D 0A 54 6F Bob@bob.com>..To
0090 3A 20 22 xx xx xx xx xx xx xx xx xx xx xx xx xx : "xxxxxx xxxxxx
00A0 xx xx xx 22 20 3C xx xx xx xx xx xx xx xx xx xx xxx" <xxxxxxxxxx
00B0 40 79 61 68 6F 6F 2E 63 6F 6D 3E 0D 0A 53 75 62 @yahoo.com>..Sub
00C0 6A 65 63 74 3A 20 54 65 73 74 69 6E 67 20 61 67 ject: Testing ag
00D0 61 69 6E 0D 0A 44 61 74 65 3A 20 54 68 75 2C 20 ain..Date: Thu,
00E0 31 37 20 4D 61 72 20 32 30 30 35 20 31 37 3A 32 17 Mar 2005 17:2
00F0 37 3A 33 31 20 2D 30 35 30 30 0D 0A 4D 49 4D 45 7:31 -0500..MIME
0100 2D 56 65 72 73 69 6F 6E 3A 20 31 2E 30 0D 0A 43 -Version: 1.0..C
0110 6F 6E 74 65 6E 74 2D 54 79 70 65 3A 20 74 65 78 ontent-Type: tex
0120 74 2F 70 6C 61 69 6E 3B 0D 0A 09 66 6F 72 6D 61 t/plain;...forma
0130 74 3D 66 6C 6F 77 65 64 3B 0D 0A 09 63 68 61 72 t=flowed;...char
0140 73 65 74 3D 22 57 69 6E 64 6F 77 73 2D 31 32 35 set="Windows-125
0150 32 22 3B 0D 0A 09 72 65 70 6C 79 2D 74 79 70 65 2";...reply-type
0160 3D 6F 72 69 67 69 6E 61 6C 0D 0A 43 6F 6E 74 65 =original..Conte
0170 6E 74 2D 54 72 61 6E 73 66 65 72 2D 45 6E 63 6F nt-Transfer-Enco
0180 64 69 6E 67 3A 20 37 62 69 74 0D 0A 58 2D 50 72 ding: 7bit..X-Pr
0190 69 6F 72 69 74 79 3A 20 33 0D 0A 58 2D 4D 53 4D iority: 3..X-MSM
01A0 61 69 6C 2D 50 72 69 6F 72 69 74 79 3A 20 4E 6F ail-Priority: No
01B0 72 6D 61 6C 0D 0A 58 2D 4D 61 69 6C 65 72 3A 20 rmal..X-Mailer:
01C0 4D 69 63 72 6F 73 6F 66 74 20 4F 75 74 6C 6F 6F Microsoft Outloo
01D0 6B 20 45 78 70 72 65 73 73 20 36 2E 30 30 2E 32 k Express 6.00.2
01E0 39 30 30 2E 32 31 38 30 0D 0A 58 2D 4D 69 6D 65 900.2180..X-Mime
01F0 4F 4C 45 3A 20 50 72 6F 64 75 63 65 64 20 42 79 OLE: Produced By
0200 20 4D 69 63 72 6F 73 6F 66 74 20 4D 69 6D 65 4F Microsoft MimeO
0210 4C 45 20 56 36 2E 30 30 2E 32 39 30 30 2E 32 31 LE V6.00.2900.21
0220 38 30 0D 0A 0D 0A 54 68 69 73 20 69 73 20 61 20 80....This is a
0230 74 65 73 74 2E test.
-> 0000 0D 0A 2E 0D 0A .....
<- 0000 32 35 30 20 4F 6B 3A 20 71 75 65 75 65 64 20 61 250 Ok: queued a
0010 73 20 34 34 45 32 31 42 0D 0A s 44E21B..
-> 0000 51 55 49 54 0D 0A QUIT..
<- 0000 32 32 31 20 41 73 74 61 20 6C 61 20 76 69 73 74 221 Asta la vist
0010 61 0D 0A a..

Client port 25 closed.

Client port 25 closed.

Capture terminated: 03/17/2005 5:27:43 PM

Client Port Traffic Totals: 7 sent 654 bytes.
Server Port Traffic Totals: 7 xcvd 186 bytes.
[/tt]
 
I would be curious to see if you use a valid from email address or yours, would you actually get the email message then?

I can see from the capture it took the message not problem.

again, thanks man... really cool!
 
I'm not sure what I triggered, because now I get a result in OE of the form:
The message could not be sent because one of the recipients was rejected by the server. The rejected e-mail address was 'xxxxxxxxxx@yahoo.com'. Subject 'A small, final test', Account: 'xxxxxxxxxx@yahoo.com', Server: 'mail.fake.com', Protocol: SMTP, Server Response: '550 relay not permitted without authentication', Port: 25, Secure(SSL): No, Server Error: 550, Error Number: 0x800CCC79
At this point I'm backing off. Hate to trigger any "abuse" alarms and end up trying to explain my curiosity. It's a "shoot first, ask questions later" world out there.
 
550 relay not permitted without authentication

I think this means that it did not find the sender's email address in its local user list.

I think it doesn't want to forward messages from Bob@bob.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top