Class: SDM::OktaMFAConfig

Inherits:
Object
  • Object
show all
Defined in:
lib/models/porcelain.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_token: nil, api_token_set: nil, auth_mode: nil, client_id: nil, multidevice_push_enabled: nil, organization_url: nil, private_key_id: nil, private_key_id_set: nil, private_key_pem: nil, private_key_pem_set: nil, user_lookup: nil) ⇒ OktaMFAConfig

Returns a new instance of OktaMFAConfig.



12811
12812
12813
12814
12815
12816
12817
12818
12819
12820
12821
12822
12823
12824
12825
12826
12827
12828
12829
12830
12831
12832
12833
12834
12835
# File 'lib/models/porcelain.rb', line 12811

def initialize(
  api_token: nil,
  api_token_set: nil,
  auth_mode: nil,
  client_id: nil,
  multidevice_push_enabled: nil,
  organization_url: nil,
  private_key_id: nil,
  private_key_id_set: nil,
  private_key_pem: nil,
  private_key_pem_set: nil,
  user_lookup: nil
)
  @api_token = api_token == nil ? "" : api_token
  @api_token_set = api_token_set == nil ? false : api_token_set
  @auth_mode = auth_mode == nil ? "" : auth_mode
  @client_id = client_id == nil ? "" : client_id
  @multidevice_push_enabled = multidevice_push_enabled == nil ? false : multidevice_push_enabled
  @organization_url = organization_url == nil ? "" : organization_url
  @private_key_id = private_key_id == nil ? "" : private_key_id
  @private_key_id_set = private_key_id_set == nil ? false : private_key_id_set
  @private_key_pem = private_key_pem == nil ? "" : private_key_pem
  @private_key_pem_set = private_key_pem_set == nil ? false : private_key_pem_set
  @user_lookup = user_lookup == nil ? "" : user_lookup
end

Instance Attribute Details

#api_tokenObject

The API token to authenticate with when auth_mode is api_token.



12787
12788
12789
# File 'lib/models/porcelain.rb', line 12787

def api_token
  @api_token
end

#api_token_setObject

Indicates if an API token is already stored.



12789
12790
12791
# File 'lib/models/porcelain.rb', line 12789

def api_token_set
  @api_token_set
end

#auth_modeObject

The Okta auth mode, one of the OktaAuthMode constants.



12791
12792
12793
# File 'lib/models/porcelain.rb', line 12791

def auth_mode
  @auth_mode
end

#client_idObject

The Okta client ID to authenticate with when auth_mode is client_credentials.



12793
12794
12795
# File 'lib/models/porcelain.rb', line 12793

def client_id
  @client_id
end

#multidevice_push_enabledObject

Indicates if multidevice push is enabled.



12795
12796
12797
# File 'lib/models/porcelain.rb', line 12795

def multidevice_push_enabled
  @multidevice_push_enabled
end

#organization_urlObject

The Okta organization URL.



12797
12798
12799
# File 'lib/models/porcelain.rb', line 12797

def organization_url
  @organization_url
end

#private_key_idObject

The key ID (kid) assigned by Okta to the registered public key.



12799
12800
12801
# File 'lib/models/porcelain.rb', line 12799

def private_key_id
  @private_key_id
end

#private_key_id_setObject

Indicates if a key ID is already stored or explicitly supplied. This allows callers to preserve the existing value when omitted or clear it by sending an empty string with private_key_id_set=true.



12803
12804
12805
# File 'lib/models/porcelain.rb', line 12803

def private_key_id_set
  @private_key_id_set
end

#private_key_pemObject

The PEM encoded private key to authenticate with when auth_mode is client_credentials.



12805
12806
12807
# File 'lib/models/porcelain.rb', line 12805

def private_key_pem
  @private_key_pem
end

#private_key_pem_setObject

Indicates if a PEM encoded private key is already stored.



12807
12808
12809
# File 'lib/models/porcelain.rb', line 12807

def private_key_pem_set
  @private_key_pem_set
end

#user_lookupObject

The Okta user lookup strategy, one of the OktaUserLookup constants.



12809
12810
12811
# File 'lib/models/porcelain.rb', line 12809

def user_lookup
  @user_lookup
end

Instance Method Details

#to_json(options = {}) ⇒ Object



12837
12838
12839
12840
12841
12842
12843
# File 'lib/models/porcelain.rb', line 12837

def to_json(options = {})
  hash = {}
  self.instance_variables.each do |var|
    hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var
  end
  hash.to_json
end