[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: ruby lib that will receive email

Peña, Botp

4/1/2005 12:46:00 AM

Florian Gross [mailto:flgr@ccan.de] wrote:

//> the net/smtp only sends mail. Is there any email ruby lib out there
//> that can receive email? I just want to capture inbound
//mail; no worry
//> on where to save it.
//
//Net::POP and Net::IMAP in Ruby's standard library?
//

hmmm.. pop/imap retrieves email fr the server. It pulls the email already
arrived at the server. I want something like _that server (so then i can
pop/imap/orwhatever fr it).

thanks and kind regards -botp




9 Answers

Brian Candler

4/1/2005 10:08:00 AM

0

On Fri, Apr 01, 2005 at 09:45:33AM +0900, "Pea, Botp" wrote:
> //> the net/smtp only sends mail. Is there any email ruby lib out there
> //> that can receive email? I just want to capture inbound
> //mail; no worry
> //> on where to save it.
> //
> //Net::POP and Net::IMAP in Ruby's standard library?
> //
>
> hmmm.. pop/imap retrieves email fr the server. It pulls the email already
> arrived at the server. I want something like _that server (so then i can
> pop/imap/orwhatever fr it).

I'd like one of these too, to go into a Unit testing framework for a mail
system. A sort of mock SMTP server.

If you write this, please release it :-)

I think if you have a look at the architecture of Exim, you might get some
good ideas. For example, Exim has ACLs which are triggered at various points
(e.g. MAIL FROM, RCPT TO) to make a decision as to whether to accept or
reject the message at that point. These could be Proc callbacks or instances
of an ACL object that you provide.

But a fully-fledged MTA in Ruby, complete with message queues and periodic
retries, isn't something that I need; just something which accepts mail via
SMTP, and stores it (even in RAM). If it were ever put onto the open
Internet it would at least have to have a way to decide whether the
recipient address is known or not, and accept/reject as appropriate.

Regards,

Brian.

P.S. I have a nice threaded server pattern you can use - see attached.

Aredridel

4/1/2005 6:46:00 PM

0

> I'd like one of these too, to go into a Unit testing framework for a mail
> system. A sort of mock SMTP server.
>
> If you write this, please release it :-)
>
> I think if you have a look at the architecture of Exim, you might get some
> good ideas. For example, Exim has ACLs which are triggered at various points
> (e.g. MAIL FROM, RCPT TO) to make a decision as to whether to accept or
> reject the message at that point. These could be Proc callbacks or instances
> of an ACL object that you provide.

I've had it in mind to do something like this before ... Exim's design
cleaned up and rubyfied would rock in a lot of ways. Wouldn't be as
fast, but for something like a mail server that's easy to extend, it
would be perfect. (And the syntax would not be as insane as Exim's)

Ari


khaines

4/1/2005 7:54:00 PM

0

Aredridel wrote:

> I've had it in mind to do something like this before ... Exim's design
> cleaned up and rubyfied would rock in a lot of ways. Wouldn't be as
> fast, but for something like a mail server that's easy to extend, it
> would be perfect. (And the syntax would not be as insane as Exim's)

Oh, do it. Do it. I have longed for such a thing for a variety of uses.


Kirk Haines

Glenn Parker

4/1/2005 8:41:00 PM

0

Aredridel wrote:
>
> I've had it in mind to do something like this before ... Exim's design
> cleaned up and rubyfied would rock in a lot of ways. Wouldn't be as
> fast, but for something like a mail server that's easy to extend, it
> would be perfect. (And the syntax would not be as insane as Exim's)

It sounds like a fun project to me, too. It might also be fun to have
pure (or mostly pure) Ruby servers for LDAP, DNS, FTP, NIS, SSH, telnet,
syslog, crontab, NFS...

--
Glenn Parker | glenn.parker-AT-comcast.net | <http://www.tetrafoi...


Aredridel

4/1/2005 9:02:00 PM

0

> It sounds like a fun project to me, too. It might also be fun to have
> pure (or mostly pure) Ruby servers for LDAP, DNS, FTP, NIS, SSH, telnet,
> syslog, crontab, NFS...

I was thinking the same thing. I was going to try an experiment and
rewrite some startup scripts in Ruby, too, to see if I can't
straighten out the load time on my box into something on the order of
not-very-many seconds.


Matt Lawrence

4/1/2005 9:07:00 PM

0

Glenn Parker

4/1/2005 9:11:00 PM

0

Matt Lawrence wrote:
>>
>> It sounds like a fun project to me, too. It might also be fun to have
>> pure (or mostly pure) Ruby servers for LDAP, DNS, FTP, NIS, SSH,
>> telnet, syslog, crontab, NFS...
>
> I would enjoy working on some of these. Shorter, more easily maintained
> and hopefully more secure.

Shall I submit this to RubyQuiz? :)

--
Glenn Parker | glenn.parker-AT-comcast.net | <http://www.tetrafoi...


James Gray

4/1/2005 11:08:00 PM

0

On Apr 1, 2005, at 3:11 PM, Glenn Parker wrote:

> Matt Lawrence wrote:
>>>
>>> It sounds like a fun project to me, too. It might also be fun to
>>> have pure (or mostly pure) Ruby servers for LDAP, DNS, FTP, NIS,
>>> SSH, telnet, syslog, crontab, NFS...
>> I would enjoy working on some of these. Shorter, more easily
>> maintained and hopefully more secure.
>
> Shall I submit this to RubyQuiz? :)

Those are pretty good size projects, but there are certainly some
interesting points in there.

Break them down into something we can play with in an hour or so. A
piece of the puzzle. Or possibly break one complete project down into
a three part quiz series that gets us most of the way there.

There's always some option...

James Edward Gray II



Aredridel

4/1/2005 11:35:00 PM

0

On Apr 1, 2005 12:54 PM, Kirk Haines <khaines@enigo.com> wrote:
> Aredridel wrote:
>
> > I've had it in mind to do something like this before ... Exim's design
> > cleaned up and rubyfied would rock in a lot of ways. Wouldn't be as
> > fast, but for something like a mail server that's easy to extend, it
> > would be perfect. (And the syntax would not be as insane as Exim's)
>
> Oh, do it. Do it. I have longed for such a thing for a variety of uses.
>
>

Has anyone tried using http://tmtm.org/r... ?

Doesn't look like it would replace exim as-is, but looks like a good
base for a fork-and-deliver or closed-system mail server.

Ari