Skip to content

Commit d1bc487

Browse files
author
Ben Lavender
committed
Fix a nil error when alternative public key isn't present
1 parent 5586435 commit d1bc487

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

lib/chatops/controller.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,7 @@ def should_authenticate_chatops?
167167
end
168168

169169
def signature_valid?(key_string, signature, signature_string)
170+
return false unless key_string.present?
170171
digest = OpenSSL::Digest::SHA256.new
171172
decoded_signature = Base64.decode64(signature)
172173
public_key = OpenSSL::PKey::RSA.new(key_string)

lib/chatops/controller/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module ChatopsController
2-
VERSION = "3.0.0"
2+
VERSION = "3.0.1"
33
end

0 commit comments

Comments
 (0)