Skip to content
This repository has been archived by the owner on Jul 2, 2024. It is now read-only.
/ rfc-822 Public archive

Library for RFC822 compatible email validation and MX record checks

License

Notifications You must be signed in to change notification settings

dim/rfc-822

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RFC822

RFC822 compatible email validation and MX record check.

Features

  • Ruby 1.9, 2.0 & 2.1 compatible
  • MRI, JRuby and Rubinius compatible
  • Email validation
  • MX checks (requires ‘host’ command line application)

Installation

Download from GitHub
wget http://github.com/dim/rfc-822/tarball/master
As a GEM
gem install rfc-822
Clone from GitHub
git clone git://github.com/dim/rfc-822.git
As a Rails plugin
ruby script/plugin install git://github.com/dim/rfc-822.git

Usage Examples

validates_format_of :email, :with => RFC822::EMAIL
"user@example.com" =~ RFC822::EMAIL ? puts("Email is valid.") : puts("Email is invalid")
RFC822.mx_records('user@mail.com') # => [#<struct RFC822::MXRecord priority=15, host="mailin-01.mx.aol.com">]

License

Please see LICENSE document

Acknowledgements

  • Inspired by previous work of Cal Henderson, Tim Fletcher and Dan Kubb.

About

Library for RFC822 compatible email validation and MX record checks

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages