Class: Fortifier::AuthSteps::CheckForUsExternalIp

Inherits:
Object
  • Object
show all
Defined in:
app/models/fortifier/auth_steps/check_for_us_external_ip.rb

Class Method Summary collapse

Class Method Details

.invoke(params) ⇒ Object



8
9
10
11
# File 'app/models/fortifier/auth_steps/check_for_us_external_ip.rb', line 8

def self.invoke(params)
  allowed = MaxMind.valid_ip?(params[:auth_log])
  params.merge! auth_msg: allowed ? nil : Messaging::MAX_MIND_EXTERNAL_IP
end

.skip_step?(params) ⇒ Boolean

Returns:

  • (Boolean)


4
5
6
# File 'app/models/fortifier/auth_steps/check_for_us_external_ip.rb', line 4

def self.skip_step?(params)
  params[:auth_msg].present?
end