LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 03-18-2004, 04:00 PM   #1
root3d
Member
 
Registered: Jan 2004
Distribution: Mandrake 9.2
Posts: 40

Rep: Reputation: 15
Python - sending mail w/ smtplib


Hey,

I know how to use smtplib to send mail, but is there a way I could code a server to allow relaying? My problem is this.. I set up a CGI script to send mail to the email address a user inputs into a form. The problem.. if I use a mailserver name@mydomain.com it can only send to users that have the mydomain domain. Is there a way around this? I need to be able to send mail to anyones email addy.

Could I run a commercial (free) SMTP server? Never used anything like that so that could be the solution..

Any help would be appreciated.
 
Old 03-18-2004, 04:08 PM   #2
rootyard
Member
 
Registered: Aug 2003
Posts: 167

Rep: Reputation: 30
You should be able to create many domains with your smtp agent (most modern ones support this).
 
Old 03-18-2004, 04:13 PM   #3
root3d
Member
 
Registered: Jan 2004
Distribution: Mandrake 9.2
Posts: 40

Original Poster
Rep: Reputation: 15
What do you mean by create many domains? Would I have to specify yahoo, hotmail etc? If I find a server that allows relaying, would it allow me to send to any domain? But that sounds shady to me (finding a server like that). So I'd really like to do this in Python if its possible, if not I'll d/l an SMTP server (I think thats what you implied in your post).

Any suggestions?
 
Old 03-18-2004, 04:15 PM   #4
rootyard
Member
 
Registered: Aug 2003
Posts: 167

Rep: Reputation: 30
Virtual hosts/domains and the like is what I meant. Python will use whichever mail server you designate. So, maybe I'm not sure what your question is exactly.
 
Old 03-18-2004, 04:17 PM   #5
root3d
Member
 
Registered: Jan 2004
Distribution: Mandrake 9.2
Posts: 40

Original Poster
Rep: Reputation: 15
I need to be able to send an email to anyones email addy. I know how to write the client in Python (which I've done), but you need to specify a server to send the email from. Most servers I've used only only you to send to email addresses with their domain eg @dell would let you send to dave@dell.com but not dave@hp.com. Hopefully that cleared it up. Thanks.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Postfix mail transfer agent not sending mail locally or to other servers sketelsen Linux - Software 3 02-09-2006 11:16 AM
Cron mail sending using outside SMTP mail server Utah Linux - Software 6 08-24-2005 07:44 PM
Sending mail through mail server. TheRealDeal Linux - Networking 17 09-11-2004 11:31 PM
sending mail between two mail server !! hitesh_linux Linux - General 3 12-14-2003 12:53 PM
Sending an automatic mail using bash + mail Minuteman Linux - Software 4 08-21-2003 12:49 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 12:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration