
Security News
Follow-up and Clarification on Recent Malicious Ruby Gems Campaign
A clarification on our recent research investigating 60 malicious Ruby gems.
actionmailer_extensions
Advanced tools
= actionmailer_extensions
These extensions wrap around the "deliver!" method on ActionMailer::Base to provide:
Note - only tested up to and including ActionMailer 2.3.8. Not tested on 3.0.
== Saving email to disk
Sending email with markup from a web app is a pain in the ass because HTML markup renders differently in every email client. (If you don't believe me, check out this {matrix of CSS support across the different email clients}[http://www.campaignmonitor.com/css/?utm_medium=email&utm_source=Email%20marketing%20software&utm_content=299578507&utm_campaign=September+News+-+Version+A+_+khihur&utm_term=AllnewCSSguidecovering24emailclients].
The only foolproof way to ensure that your content is rendering properly is to visually inspect the emails yourself. To get going, configure ActionMailer like so:
require 'actionmailer_extensions' ActionMailer::Base.save_emails_to_disk = true # Defaults to false ActionMailer::Base.email_output_dir = "some/path" # Defaults to "/tmp/actionmailer_output_emails"
Then send some emails with ActionMailer, and inspect the files in the output path that you specified. The emails are saved with a .eml extension which should open in your favourite email client for easy visual inspection.
== Safe recipients list
Ever found that you want to limit the list of people that can receive email from a Rails app? This is a particularly handy feature during development when you don't want your (unfinished) application to send out real mail to people beyond the dev team.
Configure ActionMailer like so:
require 'actionmailer_extensions' ActionMailer::Base.safe_recipients = ["pete@example.com", "dave@foo.com"]
Pete and Dave are now the only recipients that ActionMailer will send to, and all other mail will be quietly dropped. (And logged to disk, if save_emails_to_disk is enabled.)
Make sure that the recipients list contains the :any symbol in production mode.
ActionMailer::Base.safe_recipients = [:any]
This is enabled by default. Also note that an empty or nil recipients list means no mail will be sent out to anyone.
== Install
gem source --add http://gemcutter.org gem install actionmailer_extensions
== Note on Patches/Pull Requests
== Copyright
Copyright (c) 2010 Peter MacRobert. See LICENSE for details.
FAQs
Unknown package
We found that actionmailer_extensions demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A clarification on our recent research investigating 60 malicious Ruby gems.
Security News
ESLint now supports parallel linting with a new --concurrency flag, delivering major speed gains and closing a 10-year-old feature request.
Research
/Security News
A malicious Go module posing as an SSH brute forcer exfiltrates stolen credentials to a Telegram bot controlled by a Russian-speaking threat actor.