diff --git a/config/initializers/delegated_account_recovery.rb b/config/initializers/delegated_account_recovery.rb index 4640973..8fb6f30 100644 --- a/config/initializers/delegated_account_recovery.rb +++ b/config/initializers/delegated_account_recovery.rb @@ -8,7 +8,7 @@ Darrrr.icon_152px = "#{Darrrr.authority}/icon.png" Darrrr::AccountProvider.configure do |config| config.signing_private_key = ENV["ACCOUNT_PROVIDER_PRIVATE_KEY"] config.symmetric_key = ENV["TOKEN_DATA_AES_KEY"] - config.tokensign_pubkeys_secp256r1 = lambda do |account_provider, context| + config.tokensign_pubkeys_secp256r1 = lambda do |context| [ENV["ACCOUNT_PROVIDER_PUBLIC_KEY"]] end config.save_token_return = "#{Darrrr.authority}/account-provider/save-token-return" @@ -17,7 +17,7 @@ end Darrrr::RecoveryProvider.configure do |config| config.signing_private_key = ENV["RECOVERY_PROVIDER_PRIVATE_KEY"] - config.countersign_pubkeys_secp256r1 = lambda do |recovery_provider, context| + config.countersign_pubkeys_secp256r1 = lambda do |context| [ENV["RECOVERY_PROVIDER_PUBLIC_KEY"]] end config.token_max_size = 8192 diff --git a/lib/darrrr/account_provider.rb b/lib/darrrr/account_provider.rb index bb7b815..52d2cba 100644 --- a/lib/darrrr/account_provider.rb +++ b/lib/darrrr/account_provider.rb @@ -30,7 +30,7 @@ module Darrrr # passing `self` as the first argument. def unseal_keys(context = nil) if @tokensign_pubkeys_secp256r1.respond_to?(:call) - @tokensign_pubkeys_secp256r1.call(self, context) + @tokensign_pubkeys_secp256r1.call(context) else @tokensign_pubkeys_secp256r1 end diff --git a/lib/darrrr/recovery_provider.rb b/lib/darrrr/recovery_provider.rb index d17668a..7fd35cb 100644 --- a/lib/darrrr/recovery_provider.rb +++ b/lib/darrrr/recovery_provider.rb @@ -44,7 +44,7 @@ module Darrrr # passing `self` as the first argument. def unseal_keys(context = nil) if @countersign_pubkeys_secp256r1.respond_to?(:call) - @countersign_pubkeys_secp256r1.call(self, context) + @countersign_pubkeys_secp256r1.call(context) else @countersign_pubkeys_secp256r1 end