Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Interface to execute remote commands using the infrastructure of an MTA
Fetching latest commit…
Cannot retrieve the latest commit at this time.
|Type||Name||Latest commit message||Commit time|
|Failed to load latest commit information.|
MailCommander is an interface to execute remote commands using the infrastructure of an MTA and emails as its UI. It does so by parsing the data received in the body of the email and fetching the command from either the recipient of the email or the subject. It includes a small API for commands implementation: Commands API. It also has an authentication/authorization module, so commands can be validated first before actually executing them. New commands may be added by placing them under the "cmds" folder as python modules, and each command should extend the Command class. This way, the code remains the same while being scalable. Each module included in the "cmds" folder may include a configuration file "command.conf" where parser, parser options and output templates may be specified. If no parser is registered for the command then the PropertiesParser will be used by default. Each command may return text or html output after being executed, and this output will be sent to the person that requested the command as well as to every user that is responsable for authorizing it. The output by default is generated using Cheetah templates, and the location to these may be included in the command's configuration file. It's been tested under Postfix, but other MTAs should work as long as they allow setting custom transports for specific domains. YOU DON'T NEED AN MTA TO USE/TEST THIS (although it's meant to be used by one). REQUERIMENTS: -> Cheetah templates http://www.cheetahtemplate.org USAGE: mailcommander.py <options> Available options: -c, --config path to configuration file default: /etc/MailCommander/commander.conf -h, --help show this message The email source should be passed through stdin.