Searching \ for '[PIC:] SMTP, POP3 ?' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/pcbs.htm?key=smt
Search entire site for: 'SMTP, POP3 ?'.

Exact match. Not showing close matches.
PICList Thread
'[PIC:] SMTP, POP3 ?'
2004\01\21@014839 by MSullivan

flavicon
face
Does anyone have experience with SMTP and POP3 email protocols ?

I'm trying to write C code for the PIC 18F452 to negotiate the connection to a server through an 802.11b wireless access point connection to the internet.

Mark Sullivan
spam_OUTmsulliTakeThisOuTspaminsightbb.com



--
http://www.piclist.com hint: To leave the PICList
.....piclist-unsubscribe-requestKILLspamspam@spam@mitvma.mit.edu

2004\01\21@025019 by Robert Reimiller

flavicon
face
On Wed, 21 Jan 2004 00:47:21 -0600, you wrote:
>Does anyone have experience with SMTP and POP3 email protocols ?
>
Yes.

>I'm trying to write C code for the PIC 18F452 to negotiate the connection to a server through an 802.11b wireless access point connection to the internet.

I'm assuming you know that a TCP connection is required, that's the hard
part. Beyond that, its just a text based conversation often done using
a state machine. The best place to start is to read the RFC's. Using the
RFC's you can simply telnet into the SMTP or POP server and issue commands
(you might need to use line input mode, don't remember) to get a feel for
how it all works.

--
http://www.piclist.com hint: To leave the PICList
piclist-unsubscribe-requestspamKILLspammitvma.mit.edu

2004\01\21@075924 by Olin Lathrop

face picon face
MSullivan wrote:
> Does anyone have experience with SMTP and POP3 email protocols ?

Yes.  I've written both POP3 and SMTP servers and additional software to
form a whole mail queueing and forwarding system.  What are your specific
questions?

You can't do much with these protocols without reading the specs, which in
this case are RFCs.  There is no substitute for going to the source and
getting the definative answer.


*****************************************************************
Embed Inc, embedded system specialists in Littleton Massachusetts
(978) 742-9014, http://www.embedinc.com

--
http://www.piclist.com hint: To leave the PICList
.....piclist-unsubscribe-requestKILLspamspam.....mitvma.mit.edu

2004\01\21@090156 by MSullivan

flavicon
face
Olin,

thanks for responding....

specifically.. how to negotiatate (or figure out how to negotiate) the
connection to the mail server ?
I have a PIC board with an 802.11b wireless card on it,   and I have a
wireless access point router connected to the internet through a cable
modem.   I can communicate to the PIC card using a PC with a wireless card
on it, that goes through the access point (with TCP/IP).   How do I
negotiate the connection with the mail sever,  from the PIC board...through
the router?   Will I have to send out IP addresses, passwords etc...... and
what responses will I get and need to respond to?  How do I determine that?

Thanks,

Mark Sullivan
EraseMEmsullispam_OUTspamTakeThisOuTinsightbb.com


{Original Message removed}

2004\01\21@090611 by MSullivan
flavicon
face
thanks Bob,

how do I telnet into the SMTP/POP3 server?  what is line input mode?

----- Original Message -----
From: "Robert Reimiller" <bobspamspam_OUTCERTSOFT.COM>
To: <@spam@PICLISTKILLspamspamMITVMA.MIT.EDU>
Sent: Wednesday, January 21, 2004 1:48 AM
Subject: Re: [PIC:] SMTP, POP3 ?


On Wed, 21 Jan 2004 00:47:21 -0600, you wrote:
>Does anyone have experience with SMTP and POP3 email protocols ?
>
Yes.

>I'm trying to write C code for the PIC 18F452 to negotiate the connection
to a server through an 802.11b wireless access point connection to the
internet.

I'm assuming you know that a TCP connection is required, that's the hard
part. Beyond that, its just a text based conversation often done using
a state machine. The best place to start is to read the RFC's. Using the
RFC's you can simply telnet into the SMTP or POP server and issue commands
(you might need to use line input mode, don't remember) to get a feel for
how it all works.

--
http://www.piclist.com hint: To leave the PICList
KILLspampiclist-unsubscribe-requestKILLspamspammitvma.mit.edu

--
http://www.piclist.com hint: To leave the PICList
RemoveMEpiclist-unsubscribe-requestTakeThisOuTspammitvma.mit.edu

2004\01\21@092405 by Dan Oelke

flavicon
face
What you MUST do first is to get the RFCs for SMTP and POP3.
There are many sources - I like faqs.org
   http://www.faqs.org/rfcs/rfc2821.html  - SMTP defined. (although 821
is still mostly correct)
   http://www.faqs.org/rfcs/rfc1939.html   - POP3 defined (and 1081 is
also still mostly correct)

You can then practice these protocols by telneting to the server.  On
your favorite workstation just enter the command
   telnet servername 25
This opens a connection to port 25 which is defined as the port for
SMTP.  Really it is just an opened socket that you send and receive
ASCII command over.

Dan

MSullivan wrote:

>thanks Bob,
>
>how do I telnet into the SMTP/POP3 server?  what is line input mode?
>
>{Original Message removed}

2004\01\21@092614 by Olin Lathrop

face picon face
Don't send me personal copies of your PIClist posts.  I don't need to see
the same message twice.

MSullivan wrote:
{Quote hidden}

None of this has anything to do with SMTP or POP3.  For SMTP you first have
to establish a TCP connection to port 25 of the server in the usual way.
POP3 is the same, but uses port 110.  You only start talking SMTP or POP3
after these have been established.


*****************************************************************
Embed Inc, embedded system specialists in Littleton Massachusetts
(978) 742-9014, http://www.embedinc.com

--
http://www.piclist.com hint: To leave the PICList
spamBeGonepiclist-unsubscribe-requestspamBeGonespammitvma.mit.edu

2004\01\21@093310 by Olin Lathrop

face picon face
MSullivan wrote:
> how do I telnet into the SMTP/POP3 server?

It depends on your telnet client, but it's usually:

 telnet <machine name> <port number>

This works for TELNET that comes with Windows 2000.  The port number for
SMTP is 25 and for POP3 is 110.


*****************************************************************
Embed Inc, embedded system specialists in Littleton Massachusetts
(978) 742-9014, http://www.embedinc.com

--
http://www.piclist.com hint: To leave the PICList
TakeThisOuTpiclist-unsubscribe-requestEraseMEspamspam_OUTmitvma.mit.edu

2004\01\21@095349 by Shawn Tan

flavicon
face
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wednesday 21 January 2004 22:05, you wrote:
> thanks Bob,
>
> how do I telnet into the SMTP/POP3 server?  what is line input mode?

You do a telnet to port 25 for SMTP or 110 for POP3... then, you can communicate with it using the protocols specified in the RFC... for example, in POP3, you'll have to enter your USER xxxx and PASS xxxx command to get logged in followed by the STAT and LIST commands to get a list of emails and then the RETR command to get mails...

>
> {Original Message removed}

2004\01\21@114741 by William Chops Westfield

face picon face
On Wednesday, Jan 21, 2004, at 04:57 US/Pacific, Olin Lathrop wrote:

> You can't do much with these protocols without reading the specs,
> which in
> this case are RFCs.  There is no substitute for going to the source and
> getting the definative answer.

Some specs are practically useless, as far as understanding the
protocols.
The internet RFCs, however, are surprisingly readable.

BillW

--
http://www.piclist.com hint: To leave the PICList
RemoveMEpiclist-unsubscribe-requestspamTakeThisOuTmitvma.mit.edu

2004\01\21@120402 by William Chops Westfield

face picon face
On Wednesday, Jan 21, 2004, at 06:00 US/Pacific, MSullivan wrote:

> specifically.. how to negotiatate (or figure out how to negotiate) the
> connection to the mail server ?
> I have a PIC board with an 802.11b wireless card on it,   and I have a
> wireless access point router connected to the internet through a cable
> modem.   I can communicate to the PIC card using a PC with a wireless
> card
> on it, that goes through the access point (with TCP/IP).   How do I
> negotiate the connection with the mail sever,  from the PIC
> board...through
> the router?   Will I have to send out IP addresses, passwords
> etc...... and
> what responses will I get and need to respond to?  How do I determine
> that?

I'm sorry, but you need to back up a few steps and learn a bit and learn
how the internet "works" at a basic level, especially with respect to
the
layering of protocols.   An SMTP client does not
"negotiate a connection" with a mail server; it simply opens a TCP
connection,
using whatever tcp APIs are provided.   the TCP layer handles the
negotiation
and "connection."  A TCP connection does not 'work through a router";
it sends
IP packets using internal APIs.  The IP layer handles (more or less,
using
additional protocols like ICMP or ARP) figuring out which router to use.

Writing SMTP code is easy; a nice ascii dialog.  writing a complete
internet
stack containing all the layers needed to communicate over an 802.11b
card
is a major undertaking...

BillW

--
http://www.piclist.com hint: To leave the PICList
piclist-unsubscribe-requestEraseMEspam.....mitvma.mit.edu

2004\01\21@193359 by Bruce Douglas

flavicon
face
MSullivan wrote:
> Does anyone have experience with SMTP and POP3 email protocols ?

This page has an example of the text protocol used for a pop3 transaction:
http://www.wowarea.com/english/help/poptel.htm

This is the rfc for pop3: http://www.faqs.org/rfcs/rfc1939.html

Here is an example of an smtp script:
http://www.aspheute.com/english/20001009.asp

This page explains smtp in a little more detail:
http://cr.yp.to/smtp.html

This is the smtp rfc: http://www.faqs.org/rfcs/rfc2821.html

Authenticating smtp can be a little complicated depending on the
authentication scheme your isp uses, if you don't send mail from the
same server you dialed up to.

Bruce Douglas

--
http://www.piclist.com hint: To leave the PICList
EraseMEpiclist-unsubscribe-requestspammitvma.mit.edu

2004\01\21@232515 by Tim H.

picon face
Hello,

----- Original Message -----
From: "MSullivan" <RemoveMEmsulliEraseMEspamEraseMEINSIGHTBB.COM>
To: <RemoveMEPICLISTspam_OUTspamKILLspamMITVMA.MIT.EDU>
Sent: Wednesday, January 21, 2004 6:00 AM
Subject: Re: [PIC:] SMTP, POP3 ?


{Quote hidden}

board...through
> the router?   Will I have to send out IP addresses, passwords etc......
and
> what responses will I get and need to respond to?  How do I determine
that?

So far, two people have said that the best source are RFC's. It would be far
more efficient for YOU to read the RFC's to determine exactly what you need
to do rather than relying on someone to walk you through step-by-step.

To make it easy, you can resolve the POP/SMTP server domain to an IP address
beforehand and use that to connect. Otherwise, you'll have to implement a
DNS client. Once you have the IP address, for POP3, you would initiate (3
way handshake) a connection to port 110 of the remote machine. Then, you
proceed to send the necessary commands.

This will take a bit of coding on your part.

For POP3, the aforementioned RFC is RFC1939:

http://www.networksorcery.com/enp/rfc/rfc1939.txt

For SMTP, RFC821:

http://www.faqs.org/rfcs/rfc821.html

-Tim

>
> Thanks,
>
> Mark Sullivan
> RemoveMEmsulliTakeThisOuTspamspaminsightbb.com
>
>

--
http://www.piclist.com hint: To leave the PICList
EraseMEpiclist-unsubscribe-requestspamspamspamBeGonemitvma.mit.edu

2004\01\22@045304 by Jonathan Johnson

flavicon
face
For an idea of how big an undertaking, google for & layer OSI (open systems
interconnect) and look up all the rfc's the article you choose mentions, the
read through all these several times going through each layer in detail so
you undestand how it all 'interconnects'.

Happy reading (there is a bit of it)

JJ

{Original Message removed}

2004\01\23@083222 by MSullivan

flavicon
face
thanks..

if I'm understanding correctly...   not sure I am because is not
working......   I have a local network....   on it are a laptop... a
desktop....  the PIC card I am developing code for....  and a router
connected to a cable modem to the internet...   the PIC card address is
192.168.0.20    ... desktop   192.168.0.2 ...  laptop  192.168.0.10 ...
router  192.168.0.1 .....   and the mailserver IP  is  32.x.x.x ....

so I ARP request and get a respone...

then send    SYN through TCP client.....

and should get back an ACK flag.... but instead I get back   RST (reset)
flag....

because the mailserver  is outside the 255.255.255.0 mask  (ie 32.x.x.x
compared to 192.x.x ,  the LAN router address is used ? to ARP?  to send SYN
to mailserver IP?


{Original Message removed}

2004\01\23@091021 by

picon face
MSullivan wrote :

> if I'm understanding correctly...

I wouldn't bet on that...

{Quote hidden}

What response ?

> then send    SYN

Where to ?

> through TCP client.....
>
> and should get back an ACK flag.... but instead I get back
> RST (reset) flag....

Now, you do know how IP routing works, right ?

In short, your "client" should see that the target IP
address is outside the local netmask, and then send
the request (route) through your router.

Now, does the PIC software support routing ?

>
> because the mailserver  is outside the 255.255.255.0 mask
> (ie 32.x.x.x compared to 192.x.x ,  the LAN router addres
> is used ? to ARP?  to send SYN to mailserver IP?

In a way...  ...I think...

Jan-Erik.

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

2004\01\23@115646 by piclist

flavicon
face
On Fri, 23 Jan 2004, MSullivan wrote:

> then send    SYN through TCP client.....

What software are you using on the PIC that requires you to know about
SYN packets?

> because the mailserver  is outside the 255.255.255.0 mask  (ie 32.x.x.x
> compared to 192.x.x ,  the LAN router address is used ? to ARP?  to send SYN
> to mailserver IP?

Since the mail server is off your LAN, you have to ARP for the
router's address, then use the router's MAC address with the mail
server's IP address for all the packets you are directing to the mail
server.

--
John W. Temples, III

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

2004\01\23@203727 by Lee Jones

flavicon
face
> if I'm understanding correctly...   not sure I am because is not
> working......   I have a local network....   on it are a laptop... a
> desktop....  the PIC card I am developing code for....  and a router
> connected to a cable modem to the internet...   the PIC card address is
> 192.168.0.20    ... desktop   192.168.0.2 ...  laptop  192.168.0.10 ...
> router  192.168.0.1 .....   and the mailserver IP  is  32.x.x.x ....

> because the mailserver  is outside the 255.255.255.0 mask
> (ie 32.x.x.x compared to 192.x.x),

By definition, if the netmask is 255.255.255.0 (it's a bit mask)
then the local network is 192.168.0.0, not 192.x.x.x.  The mailer
server's network number would be 32.x.x.0 using your netmask.

To compute a network number you bit-wise AND the IP address with
the netmask.


> so I ARP request and get a respone...
>
> then send  SYN through TCP client.....
>
> and should get back an ACK flag.... but instead I get back
> RST (reset) flag....

You don't specifically state it, but from the hints in your
questions, I'm assuming you are layering SMTP/POP3 on top of
TCP on top of IP on top of an Ethernet physical layer.

Where did you get the TCP/IP & Ethernet layers running on
your PIC?  Do they work?  Do you trust them to work?


I don't think you have a clear understanding of how the
TCP, IP, and Ethernet layers work.

Your first question implies you are implementing the IP
layer and interfacing directly to the Ethernet layer (ARP).
Yet later questions imply you are working at the TCP layer.

I think you need to spend some time studying up on IP, TCP,
Ethernet encapsulation of IP, etc.  All these subjects are
well covered by various RFCs.  And then provide a clear
description of how your application is trying to hook into
the layer(s) of whatever network stack you are using.


> the LAN router address is used ? to ARP?  to send SYN

If the destination IP address is not on the local network,
then you need to use your routing table to determine what
gateway IP address is most appropriate for traffic destined
for any specific remote IP network.  Decision is usually
made based on IP address but may include link cost metrics
or other factors.

The easiest & most common case for end nodes is a single
default gateway.  It is normally the IP address of the
router, DSL box, etc on your local network and appears to
be 192.168.0.1 from your above description.  In this case,
all traffic that isn't destined for the local IP network
is sent to the gateway router's IP address.

                                               Lee Jones

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

2004\01\23@204555 by piclist

flavicon
face
On Fri, 23 Jan 2004, Lee Jones wrote:

> The easiest & most common case for end nodes is a single
> default gateway.  It is normally the IP address of the
> router, DSL box, etc on your local network and appears to
> be 192.168.0.1 from your above description.  In this case,
> all traffic that isn't destined for the local IP network
> is sent to the gateway router's IP address.

No, it is not.  It is sent to the desired destination IP address,
using the router's MAC address.

--
John W. Temples, III

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

More... (looser matching)
- Last day of these posts
- In 2004 , 2005 only
- Today
- New search...