Skip to content

Commit

Permalink
Merge pull request #81 from nov/amatsuda-warnings
Browse files Browse the repository at this point in the history
⚠️ method redefined; discarding old header, signature_base_str…
  • Loading branch information
nov authored Jun 27, 2019
2 parents 03c73a5 + b258297 commit 0531d39
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/json/jose.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ module JOSE
register_header_keys :alg, :jku, :jwk, :x5u, :x5t, :x5c, :kid, :typ, :cty, :crit
alias_method :algorithm, :alg

attr_accessor :header
attr_writer :header
def header
@header ||= {}
end
Expand Down
5 changes: 3 additions & 2 deletions lib/json/jwe.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@ class UnexpectedAlgorithm < JWT::UnexpectedAlgorithm; end

attr_accessor(
:public_key_or_secret, :private_key_or_secret,
:plain_text, :cipher_text, :authentication_tag, :iv, :auth_data,
:content_encryption_key, :jwe_encrypted_key, :encryption_key, :mac_key
:plain_text, :cipher_text, :iv, :auth_data,
:content_encryption_key, :encryption_key, :mac_key
)
attr_writer :jwe_encrypted_key, :authentication_tag

register_header_keys :enc, :epk, :zip, :apu, :apv
alias_method :encryption_method, :enc
Expand Down
2 changes: 1 addition & 1 deletion lib/json/jws.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ class UnexpectedAlgorithm < JWT::UnexpectedAlgorithm; end

NUM_OF_SEGMENTS = 3

attr_accessor :signature_base_string
attr_writer :signature_base_string

def initialize(jwt)
update jwt
Expand Down

0 comments on commit 0531d39

Please sign in to comment.