„Freiheit oder Tod“
GSmtp is a command line smtp mailer optimized for google’s smtp server using tls. Its purpose is to quickly send out emails in e.g. backupscripts. It supports multiple attachments. It can be used with gmail accounts but also with google apps accounts set up for mail. No configuration needed.

Example



        Gmail:
 
        ./gsmtp.pl
                --username="testuser@gmail.com"
                --password=thePassword
                --from="testuser@gmail.com"
                --to="targetuser@host.com"
                --subject="Testemail dude"
                --message="what I am here for is..."
                --attachments="/tmp/file1.txt,/tmp/file2.txt"
 
 
        Other:
 
        ./gsmtp.pl
                --host=smtp.mycompany.com
                --port=25
                --username="testuser@mycompany.com"
                --password=thePassword
                --from="testuser@mycompany.com"
                --to="targetuser@host.com"
                --subject="Testemail mate"
                --message="The message"
                --attachments="/tmp/file1.txt,/tmp/file2.txt"


Important



if you are using Net::SMTP::TLS 0.12 you have to edit the “TLS.pm” because it contains an unresolved bug but Joseph DiPaolo submitted a fix. (more info: http://rt.cpan.org/Public/Bug/Display.html?id=33031).

Here is the complete file: http://gsmtp.googlecode.com/files/TLS.pm
You can find the file in /usr/local/share/perl/5.8.8/Net/SMTP/

I created gsmtp using Perl.
http://gsmtp.googlecode.com/files/gsmtp.pl http://gsmtp.googlecode.com/files/TLS.pm

GSMTP


Copyright (C) Andreas Schipplock

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.

Support for GSMTP


The easiest and most transparent way to get support is to use the mailing list provided by google. Just subscribe and mail your question or problem. Me or another nice guy or girl then is going to help you as much as possible. Just keep in mind that the primary language used there is english.

First subscribe

Email:

Visit the group

schipplock-support