diff options
author | Seb Bacon <seb.bacon@gmail.com> | 2011-03-09 14:58:30 +0000 |
---|---|---|
committer | Seb Bacon <seb.bacon@gmail.com> | 2011-03-09 14:58:30 +0000 |
commit | b4585af18e9c3a033f6cfe27213f0575af795a66 (patch) | |
tree | 996efa1487ac0d8cb7e4f53ee6478ad625b9d27d /vendor/gems/recaptcha-0.3.1/lib/recaptcha.rb | |
parent | 224b8a4ba3a24af91068505c7907724448a4096d (diff) | |
parent | 4cc2cf2a6d935adfd263ea4fd7791a6d84f704da (diff) |
merge from master (post-CSRF changes)
Diffstat (limited to 'vendor/gems/recaptcha-0.3.1/lib/recaptcha.rb')
-rw-r--r-- | vendor/gems/recaptcha-0.3.1/lib/recaptcha.rb | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/vendor/gems/recaptcha-0.3.1/lib/recaptcha.rb b/vendor/gems/recaptcha-0.3.1/lib/recaptcha.rb new file mode 100644 index 000000000..cb6f039a4 --- /dev/null +++ b/vendor/gems/recaptcha-0.3.1/lib/recaptcha.rb @@ -0,0 +1,40 @@ +require 'recaptcha/configuration' +require 'recaptcha/client_helper' +require 'recaptcha/verify' + +module Recaptcha + module VERSION #:nodoc: + MAJOR = 0 + MINOR = 2 + TINY = 2 + PATCH = 1 + + STRING = [MAJOR, MINOR, TINY, PATCH].join('.') + end + + + RECAPTCHA_API_SERVER_URL = 'http://www.google.com/recaptcha/api' + RECAPTCHA_API_SECURE_SERVER_URL = 'https://www.google.com/recaptcha/api' + RECAPTCHA_VERIFY_URL = 'http://www.google.com/recaptcha/api/verify' + + SKIP_VERIFY_ENV = ['test', 'cucumber'] + + # Gives access to the current Configuration. + def self.configuration + @configuration ||= Configuration.new + end + + # Allows easy setting of multiple configuration options. See Configuration + # for all available options. + #-- + # The temp assignment is only used to get a nicer rdoc. Feel free to remove + # this hack. + #++ + def self.configure + config = configuration + yield(config) + end + + class RecaptchaError < StandardError + end +end |