Skip to content

ac000/recmail

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Overview
========

recmail is a simple utility to receive email passed to it from a MDA,
saving off any mime-parts and also storing a copy of the original message.


Building
========

It requires gmime 2.6.x and libuuid, on Fedora, these can be installed via

    $ sudo dnf install gmime gmime-devel libuuid libuuid-devel

To build simply type make


Use
===

Add a symlink in /etc/smrsh pointing <sender> to /usr/local/sbin/recmail
e.g
	
	# cd /etc/smrsh
	# ln -s /usr/local/sbin/recmail globocom

Add an entry for the sender to /etc/mail/virtusertable pointing to an alias 
for which you put an alias in /etc/aliases.

In /etc/mail/virtusertable add an entry

	globocom@pccl.info	globocom

Running make after making that change.

Then in /etc/aliases add an entry

	globocom:	|/etc/smrsh/globocom

Running newaliases after making that change.


Whenever email is sent to that address it is piped through recmail

recmail will look at argv[0] to see who it has been called as (stripping off
the pathname). It will use this to determine where to store the data.

It will split the message up into its parts and store them under 
/data/maildata/<sender>/YYYY/MM/DD/part-xxx.obj along with the original
email stored under /data/maildata/<sender>/YYYY/MM/DD/UUID/maildata.dat

There is also an index file created (00INDEX) that links original attachment 
filenames to their part-xxx.obj counterparts.

Multiple messages sent in the same day will be stored under separate UUID/ 
directories, where UUID is e.g 33faa523-d10f-4162-9876-ba30476a155c.


You can run recmail manually e.g

	./recmail /path/to/somedir < mailfile

Where /path/to/somedir is instead of /data/maildata and mailfile is a full
email message.

About

Save off mime-parts from an email message passed to it

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors