heapsource / active_model_otp

Adds methods to set and authenticate against one time passwords (Two-Factor Authentication). Inspired in AM::SecurePassword
MIT License
769 stars 81 forks source link

Require 'cgi', rotp needs it for encoding parameters #4

Closed andrehjr closed 10 years ago

andrehjr commented 10 years ago

Turns out that the latest version is rotp is using CGI for encoding params, so without it 2 specs are failing on my machine.

I could either just require it on spec_helper or require it inside active_model_otp.. I think that the later is better.

Also fixed a test that was failing sometimes, OTP can return codes with 5-6 digits. The test was asserting that the code could only have 6.

robertomiranda commented 10 years ago

@andrehjr could you squash your commits in a single one? looks good for me :+1: