Class | Net::SSH::Transport::HMAC::Abstract |
In: |
lib/net/ssh/transport/hmac/abstract.rb
lib/net/ssh/transport/hmac/abstract.rb |
Parent: | Object |
key | [R] | The key in use for this instance. |
key | [R] | The key in use for this instance. |
# File lib/net/ssh/transport/hmac/abstract.rb, line 37 37: def initialize(key=nil) 38: self.key = key 39: end
# File lib/net/ssh/transport/hmac/abstract.rb, line 37 37: def initialize(key=nil) 38: self.key = key 39: end
Sets the key to the given value, truncating it so that it is the correct length.
# File lib/net/ssh/transport/hmac/abstract.rb, line 43 43: def key=(value) 44: @key = value ? value.to_s[0,key_length] : nil 45: end