19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
# File 'app/models/fortifier/authentication_steps.rb', line 19
def self.stepper(params={})
case params[:auth_type]
when "standard_auth"
STEPS.each do |step|
step_class = ("Fortifier::AuthSteps::" + step).constantize
next if step_class.respond_to?(:skip_step?) && step_class.skip_step?(params)
params = step_class.invoke(params)
end
when "batch_sso_auth"
BATCH_SSO_STEPS.each do |step|
step_class = ("Fortifier::AuthSteps::" + step).constantize
next if step_class.respond_to?(:skip_step?) && step_class.skip_step?(params)
params = step_class.invoke(params)
end
when "on_demand_sso_auth"
ON_DEMAND_SSO_STEPS.each do |step|
step_class = ("Fortifier::AuthSteps::" + step).constantize
next if step_class.respond_to?(:skip_step?) && step_class.skip_step?(params)
params = step_class.invoke(params)
end
end
params
end
|