lib/sidekiq/encrypted_args.rb
def decrypt_string(value)
        return value if encryptors == [nil]
        encryptors.each do |encryptor|
          begin
            return encryptor.decrypt(value) if encryptor
          rescue OpenSSL::Cipher::CipherError
            # Not the right key, try the next one
          end
        end
        raise InvalidSecretError
      end
# Set the secret key used for encrypting arguments. If this is not set,
# the value will be loaded from the `SIDEKIQ_ENCRYPTED_ARGS_SECRET` environment
# variable. If that value is not set, arguments will not be encrypted.
#
# You can set multiple secrets by passing an array if you need to roll your secrets.
# The left most value in the array will be used as the encryption secret, but
# all the values will be tried when decrypting. That way if you have scheduled
# jobs that were encrypted with a different secret, you can still make it available
# when decrypting the arguments when the job gets run. If you are using the
# environment variable, separate the keys with spaces.
#
# @param [String] value One or more secrets to use for encrypting arguments.
# @return [void]
Set the secret key used for encrypting arguments. If this is not set,
the value will be loaded from the `SIDEKIQ_ENCRYPTED_ARGS_SECRET` environment
variable. If that value is not set, arguments will not be encrypted.

You can set multiple secrets by passing an array if you need to roll your secrets.
The left most value in the array will be used as the encryption secret, but
all the values will be tried when decrypting. That way if you have scheduled
jobs that were encrypted with a different secret, you can still make it available
when decrypting the arguments when the job gets run. If you are using the
environment variable, separate the keys with spaces.
Set the secret key used for encrypting arguments . If this is not set the value will be loaded from the ` SIDEKIQ_ENCRYPTED_ARGS_SECRET ` environment variable . If that value is not set arguments will not be encrypted . You can set multiple secrets by passing an array if you need to roll your secrets . The left most value in the array will be used as the encryption secret but all the values will be tried when decrypting . That way if you have scheduled jobs that were encrypted with a different secret you can still make it available when decrypting the arguments when the job gets run . If you are using the environment variable separate the keys with spaces .
def decrypt_string(value)
        return value if encryptors == [nil]
        encryptors.each do |encryptor|
          begin
            return encryptor.decrypt(value) if encryptor
          rescue OpenSSL::Cipher::CipherError
          end
        end
        raise InvalidSecretError
      end
def decrypt_string ( value ) return value if encryptors == [ nil ] encryptors . each do | encryptor | begin return encryptor . decrypt ( value ) if encryptor rescue OpenSSL :: Cipher :: CipherError end end raise InvalidSecretError end
Set the secret key used for encrypting arguments.
Set the secret key used for encrypting arguments .
# Not the right key, try the next one
None
void
value
value One or more secrets to use for encrypting arguments.
value One or more secrets to use for encrypting arguments .