Sha256: 6844cd571445fee40eeba69982bdf34f7dd2523bafea25e24813ad553f2b0503
Contents?: true
Size: 719 Bytes
Versions: 17
Compression:
Stored size: 719 Bytes
Contents
# bandwidth # # This file was automatically generated by APIMATIC v2.0 # ( https://apimatic.io ). require 'base64' module Bandwidth # Utility class for basic authorization. class MultiFactorAuthBasicAuth # Add basic authentication to the request. # @param [HttpRequest] The HttpRequest object to which authentication will # be added. def self.apply(config, http_request) username = config.multi_factor_auth_basic_auth_user_name password = config.multi_factor_auth_basic_auth_password value = Base64.strict_encode64("#{username}:#{password}") header_value = "Basic #{value}" http_request.headers['Authorization'] = header_value end end end
Version data entries
17 entries across 17 versions & 1 rubygems