Closed twhaples closed 10 years ago
I'm having the exact same issue. -- on OSX: Lion Using this version of hmac.rb, however, fixes the issue. http://code.google.com/p/cloudcache-ruby/source/browse/trunk/lib/hmac.rb?r=10
Sorry for the long-long delay on this. But I'm having trouble reproing your issue. Presumably you've moved onto another problem or solved this one already. Please reopen if you're still encountering the error.
FYI, I was able to repro this by passing in nil in. Double check that @key and @secret are filled in.
2.0.0-p353 :003 > conn = Route53::Connection.new(nil, nil)
=> #<Route53::Connection:0x00000102323770 @accesskey=nil, @secret=nil, @api="2012-12-12", @endpoint="https://route53.amazonaws.com/", @base_url="https://route53.amazonaws.com/2012-12-12", @verbose=false, @ssl_no_verify=false>
2.0.0-p353 :004 > conn.get_zones
RuntimeError: The underlying hash algorithm has not yet been initialized.
from /Users/pcorliss/.rvm/gems/ruby-2.0.0-p353@route53/gems/ruby-hmac-0.4.0/lib/hmac.rb:36:in `check_status'
from /Users/pcorliss/.rvm/gems/ruby-2.0.0-p353@route53/gems/ruby-hmac-0.4.0/lib/hmac.rb:68:in `update'
from /Users/pcorliss/git/ruby_route_53/lib/route53/connection.rb:28:in `request'
from /Users/pcorliss/git/ruby_route_53/lib/route53/connection.rb:50:in `get_zones'
from (irb):4
from /Users/pcorliss/.rvm/rubies/ruby-2.0.0-p353/bin/irb:12:in `<main>'
Thanks @pcorliss - I had the same issue, and it turned out that key
and secret
were blank.
I've got a script which looks something like this; it's about as simple as I could come up with.
It results in a backtrace like the following.
`` RuntimeError: The underlying hash algorithm has not yet been initialized. /Users/me/.rvm/gems/ruby-1.9.2-p180@snet/gems/ruby-hmac-0.4.0/lib/hmac.rb:36:in
check_status' /Users/me/.rvm/gems/ruby-1.9.2-p180@snet/gems/ruby-hmac-0.4.0/lib/hmac.rb:68:inupdate' /Users/me/.rvm/gems/ruby-1.9.2-p180@snet/gems/route53-0.2.1/lib/route53.rb:41:in
request' /Users/me/.rvm/gems/ruby-1.9.2-p180@snet/gems/route53-0.2.1/lib/route53.rb:63:inget_zones' /Users/me/git/ops/dns.rb:19:in
shakedown'