Class: MistApi::Sso

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/mist_api/models/sso.rb

Overview

SSO

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from BaseModel

#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json

Constructor Details

#initialize(name = nil, created_time = SKIP, custom_logout_url = SKIP, default_role = SKIP, domain = SKIP, group_filter = SKIP, id = SKIP, idp_cert = SKIP, idp_sign_algo = SKIP, idp_sso_url = SKIP, idp_type = SsoIdpTypeEnum::SAML, ignore_unmatched_roles = SKIP, issuer = SKIP, ldap_base_dn = SKIP, ldap_bind_dn = SKIP, ldap_bind_password = SKIP, ldap_cacerts = SKIP, ldap_client_cert = SKIP, ldap_client_key = SKIP, ldap_group_attr = 'memberOf', ldap_group_dn = 'base_dn', ldap_resolve_groups = false, ldap_server_hosts = SKIP, ldap_type = SsoLdapTypeEnum::AZURE, ldap_user_filter = SKIP, member_filter = SKIP, modified_time = SKIP, msp_id = SKIP, mxedge_proxy = SKIP, nameid_format = SsoNameidFormatEnum::EMAIL, oauth_cc_client_id = SKIP, oauth_cc_client_secret = SKIP, oauth_discovery_url = SKIP, oauth_ping_identity_region = OauthPingIdentityRegionEnum::US, oauth_provider_domain = OauthProviderDomainEnum::ENUM_OKTACOM, oauth_ropc_client_id = SKIP, oauth_ropc_client_secret = SKIP, oauth_tenant_id = SKIP, oauth_type = SsoOauthTypeEnum::AZURE, openroaming = SKIP, org_id = SKIP, role_attr_extraction = SKIP, role_attr_from = 'Role', scim_enabled = false, scim_secret_token = SKIP, site_id = SKIP, additional_properties = nil) ⇒ Sso

Returns a new instance of Sso.



347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
# File 'lib/mist_api/models/sso.rb', line 347

def initialize(
  name = nil, created_time = SKIP, custom_logout_url = SKIP,
  default_role = SKIP, domain = SKIP, group_filter = SKIP, id = SKIP,
  idp_cert = SKIP, idp_sign_algo = SKIP, idp_sso_url = SKIP,
  idp_type = SsoIdpTypeEnum::SAML, ignore_unmatched_roles = SKIP,
  issuer = SKIP, ldap_base_dn = SKIP, ldap_bind_dn = SKIP,
  ldap_bind_password = SKIP, ldap_cacerts = SKIP, ldap_client_cert = SKIP,
  ldap_client_key = SKIP, ldap_group_attr = 'memberOf',
  ldap_group_dn = 'base_dn', ldap_resolve_groups = false,
  ldap_server_hosts = SKIP, ldap_type = SsoLdapTypeEnum::AZURE,
  ldap_user_filter = SKIP, member_filter = SKIP, modified_time = SKIP,
  msp_id = SKIP, mxedge_proxy = SKIP,
  nameid_format = SsoNameidFormatEnum::EMAIL, oauth_cc_client_id = SKIP,
  oauth_cc_client_secret = SKIP, oauth_discovery_url = SKIP,
  oauth_ping_identity_region = OauthPingIdentityRegionEnum::US,
  oauth_provider_domain = OauthProviderDomainEnum::ENUM_OKTACOM,
  oauth_ropc_client_id = SKIP, oauth_ropc_client_secret = SKIP,
  oauth_tenant_id = SKIP, oauth_type = SsoOauthTypeEnum::AZURE,
  openroaming = SKIP, org_id = SKIP, role_attr_extraction = SKIP,
  role_attr_from = 'Role', scim_enabled = false, scim_secret_token = SKIP,
  site_id = SKIP, additional_properties = nil
)
  # Add additional model properties to the instance
  additional_properties = {} if additional_properties.nil?

  @created_time = created_time unless created_time == SKIP
  @custom_logout_url = custom_logout_url unless custom_logout_url == SKIP
  @default_role = default_role unless default_role == SKIP
  @domain = domain unless domain == SKIP
  @group_filter = group_filter unless group_filter == SKIP
  @id = id unless id == SKIP
  @idp_cert = idp_cert unless idp_cert == SKIP
  @idp_sign_algo = idp_sign_algo unless idp_sign_algo == SKIP
  @idp_sso_url = idp_sso_url unless idp_sso_url == SKIP
  @idp_type = idp_type unless idp_type == SKIP
  @ignore_unmatched_roles = ignore_unmatched_roles unless ignore_unmatched_roles == SKIP
  @issuer = issuer unless issuer == SKIP
  @ldap_base_dn = ldap_base_dn unless ldap_base_dn == SKIP
  @ldap_bind_dn = ldap_bind_dn unless ldap_bind_dn == SKIP
  @ldap_bind_password = ldap_bind_password unless ldap_bind_password == SKIP
  @ldap_cacerts = ldap_cacerts unless ldap_cacerts == SKIP
  @ldap_client_cert = ldap_client_cert unless ldap_client_cert == SKIP
  @ldap_client_key = ldap_client_key unless ldap_client_key == SKIP
  @ldap_group_attr = ldap_group_attr unless ldap_group_attr == SKIP
  @ldap_group_dn = ldap_group_dn unless ldap_group_dn == SKIP
  @ldap_resolve_groups = ldap_resolve_groups unless ldap_resolve_groups == SKIP
  @ldap_server_hosts = ldap_server_hosts unless ldap_server_hosts == SKIP
  @ldap_type = ldap_type unless ldap_type == SKIP
  @ldap_user_filter = ldap_user_filter unless ldap_user_filter == SKIP
  @member_filter = member_filter unless member_filter == SKIP
  @modified_time = modified_time unless modified_time == SKIP
  @msp_id = msp_id unless msp_id == SKIP
  @mxedge_proxy = mxedge_proxy unless mxedge_proxy == SKIP
  @name = name
  @nameid_format = nameid_format unless nameid_format == SKIP
  @oauth_cc_client_id = oauth_cc_client_id unless oauth_cc_client_id == SKIP
  @oauth_cc_client_secret = oauth_cc_client_secret unless oauth_cc_client_secret == SKIP
  @oauth_discovery_url = oauth_discovery_url unless oauth_discovery_url == SKIP
  unless oauth_ping_identity_region == SKIP
    @oauth_ping_identity_region =
      oauth_ping_identity_region
  end
  @oauth_provider_domain = oauth_provider_domain unless oauth_provider_domain == SKIP
  @oauth_ropc_client_id = oauth_ropc_client_id unless oauth_ropc_client_id == SKIP
  @oauth_ropc_client_secret = oauth_ropc_client_secret unless oauth_ropc_client_secret == SKIP
  @oauth_tenant_id = oauth_tenant_id unless oauth_tenant_id == SKIP
  @oauth_type = oauth_type unless oauth_type == SKIP
  @openroaming = openroaming unless openroaming == SKIP
  @org_id = org_id unless org_id == SKIP
  @role_attr_extraction = role_attr_extraction unless role_attr_extraction == SKIP
  @role_attr_from = role_attr_from unless role_attr_from == SKIP
  @scim_enabled = scim_enabled unless scim_enabled == SKIP
  @scim_secret_token = scim_secret_token unless scim_secret_token == SKIP
  @site_id = site_id unless site_id == SKIP
  @additional_properties = additional_properties
end

Instance Attribute Details

#created_timeFloat

When the object has been created, in epoch

Returns:

  • (Float)


14
15
16
# File 'lib/mist_api/models/sso.rb', line 14

def created_time
  @created_time
end

#custom_logout_urlString

If ‘idp_type`==`saml`, a URL we will redirect the user after user logout from Mist (for some IdP which supports a custom logout URL that is different from SP-initiated SLO process)

Returns:

  • (String)


20
21
22
# File 'lib/mist_api/models/sso.rb', line 20

def custom_logout_url
  @custom_logout_url
end

#default_roleString

If ‘idp_type`==`saml`, default role to assign if there’s no match. By default, an assertion is treated as invalid when there’s no role matched

Returns:

  • (String)


25
26
27
# File 'lib/mist_api/models/sso.rb', line 25

def default_role
  @default_role
end

#domainString

Random string generated during the SSO creation and used to generate the SAML URLs:

* ACS URL = `/api/v1/saml/{domain}/login` (e.g.

api.mist.com/api/v1/saml/s4t5vwv8/login`)

* Single Logout URL = `/api/v1/saml/{domain}/logout` (e.g.

api.mist.com/api/v1/saml/s4t5vwv8/logout`)

Returns:

  • (String)


34
35
36
# File 'lib/mist_api/models/sso.rb', line 34

def domain
  @domain
end

#group_filterString

Required if ‘ldap_type`==`custom`, LDAP filter that will identify the type of group

Returns:

  • (String)


39
40
41
# File 'lib/mist_api/models/sso.rb', line 39

def group_filter
  @group_filter
end

#idUUID | String

Unique ID of the object instance in the Mist Organization

Returns:

  • (UUID | String)


43
44
45
# File 'lib/mist_api/models/sso.rb', line 43

def id
  @id
end

#idp_certString

If ‘idp_type`==`saml`. IDP Cert (used to verify the signed response)

Returns:

  • (String)


47
48
49
# File 'lib/mist_api/models/sso.rb', line 47

def idp_cert
  @idp_cert
end

#idp_sign_algoSsoIdpSignAlgoEnum

Required if ‘idp_type`==`saml`, Signing algorithm for SAML Assertion. enum: `sha1`, `sha256`, `sha384`, `sha512`

Returns:



52
53
54
# File 'lib/mist_api/models/sso.rb', line 52

def idp_sign_algo
  @idp_sign_algo
end

#idp_sso_urlString

Required if ‘idp_type`==`saml`, IDP Single-Sign-On URL

Returns:

  • (String)


56
57
58
# File 'lib/mist_api/models/sso.rb', line 56

def idp_sso_url
  @idp_sso_url
end

#idp_typeSsoIdpTypeEnum

SSO IDP Type:

* For Admin SSO, enum: `saml`
* For NAC SSO, enum: `ldap`, `mxedge_proxy`, `oauth`, `openroaming`

Returns:



62
63
64
# File 'lib/mist_api/models/sso.rb', line 62

def idp_type
  @idp_type
end

#ignore_unmatched_rolesTrueClass | FalseClass

If ‘idp_type`==`saml`, ignore any unmatched roles provided in assertion. By default, an assertion is treated as invalid for any unmatched role

Returns:

  • (TrueClass | FalseClass)


67
68
69
# File 'lib/mist_api/models/sso.rb', line 67

def ignore_unmatched_roles
  @ignore_unmatched_roles
end

#issuerString

If ‘idp_type`==`saml`. IDP issuer URL

Returns:

  • (String)


71
72
73
# File 'lib/mist_api/models/sso.rb', line 71

def issuer
  @issuer
end

#ldap_base_dnString

Required if ‘idp_type`==`ldap`, whole domain or a specific organization unit (container) in Search base to specify where users and groups are found in the LDAP tree

Returns:

  • (String)


77
78
79
# File 'lib/mist_api/models/sso.rb', line 77

def ldap_base_dn
  @ldap_base_dn
end

#ldap_bind_dnString

Required if ‘idp_type`==`ldap`, the account used to authenticate against the LDAP

Returns:

  • (String)


82
83
84
# File 'lib/mist_api/models/sso.rb', line 82

def ldap_bind_dn
  @ldap_bind_dn
end

#ldap_bind_passwordString

Required if ‘idp_type`==`ldap`, the password used to authenticate against the LDAP

Returns:

  • (String)


87
88
89
# File 'lib/mist_api/models/sso.rb', line 87

def ldap_bind_password
  @ldap_bind_password
end

#ldap_cacertsArray[String]

Required if ‘idp_type`==`ldap`, list of CA certificates to validate the LDAP certificate

Returns:

  • (Array[String])


92
93
94
# File 'lib/mist_api/models/sso.rb', line 92

def ldap_cacerts
  @ldap_cacerts
end

#ldap_client_certString

If ‘idp_type`==`ldap`, LDAPS Client certificate

Returns:

  • (String)


96
97
98
# File 'lib/mist_api/models/sso.rb', line 96

def ldap_client_cert
  @ldap_client_cert
end

#ldap_client_keyString

If ‘idp_type`==`ldap`, Key for the `ldap_client_cert`

Returns:

  • (String)


100
101
102
# File 'lib/mist_api/models/sso.rb', line 100

def ldap_client_key
  @ldap_client_key
end

#ldap_group_attrString

If ‘ldap_type`==`custom`

Returns:

  • (String)


104
105
106
# File 'lib/mist_api/models/sso.rb', line 104

def ldap_group_attr
  @ldap_group_attr
end

#ldap_group_dnString

If ‘ldap_type`==`custom`

Returns:

  • (String)


108
109
110
# File 'lib/mist_api/models/sso.rb', line 108

def ldap_group_dn
  @ldap_group_dn
end

#ldap_resolve_groupsTrueClass | FalseClass

If ‘idp_type`==`ldap`, whether to recursively resolve LDAP groups

Returns:

  • (TrueClass | FalseClass)


112
113
114
# File 'lib/mist_api/models/sso.rb', line 112

def ldap_resolve_groups
  @ldap_resolve_groups
end

#ldap_server_hostsArray[String]

If ‘idp_type`==`ldap`, list of LDAP/LDAPS server IP Addresses or Hostnames

Returns:

  • (Array[String])


116
117
118
# File 'lib/mist_api/models/sso.rb', line 116

def ldap_server_hosts
  @ldap_server_hosts
end

#ldap_typeSsoLdapTypeEnum

if ‘idp_type`==`ldap`. enum: `azure`, `custom`, `google`, `okta`, `ping_identity`

Returns:



121
122
123
# File 'lib/mist_api/models/sso.rb', line 121

def ldap_type
  @ldap_type
end

#ldap_user_filterString

Required if ‘ldap_type`==`custom`, LDAP filter that will identify the type of user

Returns:

  • (String)


126
127
128
# File 'lib/mist_api/models/sso.rb', line 126

def ldap_user_filter
  @ldap_user_filter
end

#member_filterString

Required if ‘ldap_type`==`custom`,LDAP filter that will identify the type of member

Returns:

  • (String)


131
132
133
# File 'lib/mist_api/models/sso.rb', line 131

def member_filter
  @member_filter
end

#modified_timeFloat

When the object has been modified for the last time, in epoch

Returns:

  • (Float)


135
136
137
# File 'lib/mist_api/models/sso.rb', line 135

def modified_time
  @modified_time
end

#msp_idUUID | String

When the object has been modified for the last time, in epoch

Returns:

  • (UUID | String)


139
140
141
# File 'lib/mist_api/models/sso.rb', line 139

def msp_id
  @msp_id
end

#mxedge_proxySsoMxedgeProxy

If ‘idp_type`==`mxedge_proxy`, this requires `mist_nac` to be enabled on the mxcluster

Returns:



144
145
146
# File 'lib/mist_api/models/sso.rb', line 144

def mxedge_proxy
  @mxedge_proxy
end

#nameString

Name

Returns:

  • (String)


148
149
150
# File 'lib/mist_api/models/sso.rb', line 148

def name
  @name
end

#nameid_formatSsoNameidFormatEnum

if ‘idp_type`==`saml`. enum: `email`, `unspecified`

Returns:



152
153
154
# File 'lib/mist_api/models/sso.rb', line 152

def nameid_format
  @nameid_format
end

#oauth_cc_client_idString

Required if ‘idp_type`==`oauth`, Client Credentials

Returns:

  • (String)


156
157
158
# File 'lib/mist_api/models/sso.rb', line 156

def oauth_cc_client_id
  @oauth_cc_client_id
end

#oauth_cc_client_secretString

Required if ‘idp_type`==`oauth`, oauth_cc_client_secret is RSA private key, of the form “—–BEGIN RSA PRIVATE KEY–.…”

Returns:

  • (String)


161
162
163
# File 'lib/mist_api/models/sso.rb', line 161

def oauth_cc_client_secret
  @oauth_cc_client_secret
end

#oauth_discovery_urlString

If ‘idp_type`==`oauth`

Returns:

  • (String)


165
166
167
# File 'lib/mist_api/models/sso.rb', line 165

def oauth_discovery_url
  @oauth_discovery_url
end

#oauth_ping_identity_regionOauthPingIdentityRegionEnum

enum: ‘us` (United States, default), `ca` (Canada), `eu` (Europe), `asia` (Asia), `au` (Australia)



170
171
172
# File 'lib/mist_api/models/sso.rb', line 170

def oauth_ping_identity_region
  @oauth_ping_identity_region
end

#oauth_provider_domainOauthProviderDomainEnum

If ‘oauth_type`==`okta`, specifies the region-specific OAuth provider domain. enum: `okta.com`, `oktapreview.com`, `okta-emea.com`, `okta-gov.com`, `okta.mil`, `mtls.okta.com`



176
177
178
# File 'lib/mist_api/models/sso.rb', line 176

def oauth_provider_domain
  @oauth_provider_domain
end

#oauth_ropc_client_idString

If ‘idp_type`==`oauth`, ropc = Resource Owner Password Credentials

Returns:

  • (String)


180
181
182
# File 'lib/mist_api/models/sso.rb', line 180

def oauth_ropc_client_id
  @oauth_ropc_client_id
end

#oauth_ropc_client_secretString

If ‘oauth_type`==`azure` or `oauth_type`==`azure-gov`. oauth_ropc_client_secret can be empty

Returns:

  • (String)


185
186
187
# File 'lib/mist_api/models/sso.rb', line 185

def oauth_ropc_client_secret
  @oauth_ropc_client_secret
end

#oauth_tenant_idString

Required if ‘idp_type`==`oauth`, oauth_tenant_id

Returns:

  • (String)


189
190
191
# File 'lib/mist_api/models/sso.rb', line 189

def oauth_tenant_id
  @oauth_tenant_id
end

#oauth_typeSsoOauthTypeEnum

if ‘idp_type`==`oauth`. enum: `azure`, `azure-gov`, `okta`, `ping_identity`

Returns:



194
195
196
# File 'lib/mist_api/models/sso.rb', line 194

def oauth_type
  @oauth_type
end

#openroamingSsoOpenroaming

if ‘idp_type`==`openroaming`

Returns:



198
199
200
# File 'lib/mist_api/models/sso.rb', line 198

def openroaming
  @openroaming
end

#org_idUUID | String

if ‘idp_type`==`openroaming`

Returns:

  • (UUID | String)


202
203
204
# File 'lib/mist_api/models/sso.rb', line 202

def org_id
  @org_id
end

#role_attr_extractionString

If ‘idp_type`==`saml`, custom role attribute parsing scheme. Supported Role Parsing Schemes <table><tr><th>Name</th><th>Scheme</th></tr><tr><td>`cn`</td><td><ul><li>T he expected role attribute format in SAML Assertion is “CN=cn,OU=ou1,OU=ou2,…”</li><li>CN (the key) is case-insensitive and exactly 1 CN is expected (or the entire entry will be ignored)</li></ul>E.g. if role attribute is “CN=cn,OU=ou1,OU=ou2” then parsed role value is “cn”</td></tr></table>

Returns:

  • (String)


213
214
215
# File 'lib/mist_api/models/sso.rb', line 213

def role_attr_extraction
  @role_attr_extraction
end

#role_attr_fromString

If ‘idp_type`==`saml`, name of the attribute in SAML Assertion to extract role from

Returns:

  • (String)


218
219
220
# File 'lib/mist_api/models/sso.rb', line 218

def role_attr_from
  @role_attr_from
end

#scim_enabledTrueClass | FalseClass

If ‘idp_type`==`oauth`, indicates if SCIM provisioning is enabled for the OAuth IDP

Returns:

  • (TrueClass | FalseClass)


223
224
225
# File 'lib/mist_api/models/sso.rb', line 223

def scim_enabled
  @scim_enabled
end

#scim_secret_tokenString

If ‘idp_type`==`oauth`, scim_secret_token (auto-generated when not provided by caller and `scim_enabled`==`true`, empty string when `scim_enabled`==`false`) is used as the Bearer token in the Authorization header of SCIM provisioning requests by the IDP

Returns:

  • (String)


230
231
232
# File 'lib/mist_api/models/sso.rb', line 230

def scim_secret_token
  @scim_secret_token
end

#site_idUUID | String

If ‘idp_type`==`oauth`, scim_secret_token (auto-generated when not provided by caller and `scim_enabled`==`true`, empty string when `scim_enabled`==`false`) is used as the Bearer token in the Authorization header of SCIM provisioning requests by the IDP

Returns:

  • (UUID | String)


237
238
239
# File 'lib/mist_api/models/sso.rb', line 237

def site_id
  @site_id
end

Class Method Details

.from_hash(hash) ⇒ Object

Creates an instance of the object from a hash.



425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
# File 'lib/mist_api/models/sso.rb', line 425

def self.from_hash(hash)
  return nil unless hash

  # Extract variables from the hash.
  name = hash.key?('name') ? hash['name'] : nil
  created_time = hash.key?('created_time') ? hash['created_time'] : SKIP
  custom_logout_url =
    hash.key?('custom_logout_url') ? hash['custom_logout_url'] : SKIP
  default_role = hash.key?('default_role') ? hash['default_role'] : SKIP
  domain = hash.key?('domain') ? hash['domain'] : SKIP
  group_filter = hash.key?('group_filter') ? hash['group_filter'] : SKIP
  id = hash.key?('id') ? hash['id'] : SKIP
  idp_cert = hash.key?('idp_cert') ? hash['idp_cert'] : SKIP
  idp_sign_algo = hash.key?('idp_sign_algo') ? hash['idp_sign_algo'] : SKIP
  idp_sso_url = hash.key?('idp_sso_url') ? hash['idp_sso_url'] : SKIP
  idp_type = hash['idp_type'] ||= SsoIdpTypeEnum::SAML
  ignore_unmatched_roles =
    hash.key?('ignore_unmatched_roles') ? hash['ignore_unmatched_roles'] : SKIP
  issuer = hash.key?('issuer') ? hash['issuer'] : SKIP
  ldap_base_dn = hash.key?('ldap_base_dn') ? hash['ldap_base_dn'] : SKIP
  ldap_bind_dn = hash.key?('ldap_bind_dn') ? hash['ldap_bind_dn'] : SKIP
  ldap_bind_password =
    hash.key?('ldap_bind_password') ? hash['ldap_bind_password'] : SKIP
  ldap_cacerts = hash.key?('ldap_cacerts') ? hash['ldap_cacerts'] : SKIP
  ldap_client_cert =
    hash.key?('ldap_client_cert') ? hash['ldap_client_cert'] : SKIP
  ldap_client_key =
    hash.key?('ldap_client_key') ? hash['ldap_client_key'] : SKIP
  ldap_group_attr = hash['ldap_group_attr'] ||= 'memberOf'
  ldap_group_dn = hash['ldap_group_dn'] ||= 'base_dn'
  ldap_resolve_groups = hash['ldap_resolve_groups'] ||= false
  ldap_server_hosts =
    hash.key?('ldap_server_hosts') ? hash['ldap_server_hosts'] : SKIP
  ldap_type = hash['ldap_type'] ||= SsoLdapTypeEnum::AZURE
  ldap_user_filter =
    hash.key?('ldap_user_filter') ? hash['ldap_user_filter'] : SKIP
  member_filter = hash.key?('member_filter') ? hash['member_filter'] : SKIP
  modified_time = hash.key?('modified_time') ? hash['modified_time'] : SKIP
  msp_id = hash.key?('msp_id') ? hash['msp_id'] : SKIP
  mxedge_proxy = SsoMxedgeProxy.from_hash(hash['mxedge_proxy']) if hash['mxedge_proxy']
  nameid_format = hash['nameid_format'] ||= SsoNameidFormatEnum::EMAIL
  oauth_cc_client_id =
    hash.key?('oauth_cc_client_id') ? hash['oauth_cc_client_id'] : SKIP
  oauth_cc_client_secret =
    hash.key?('oauth_cc_client_secret') ? hash['oauth_cc_client_secret'] : SKIP
  oauth_discovery_url =
    hash.key?('oauth_discovery_url') ? hash['oauth_discovery_url'] : SKIP
  oauth_ping_identity_region =
    hash['oauth_ping_identity_region'] ||= OauthPingIdentityRegionEnum::US
  oauth_provider_domain =
    hash['oauth_provider_domain'] ||= OauthProviderDomainEnum::ENUM_OKTACOM
  oauth_ropc_client_id =
    hash.key?('oauth_ropc_client_id') ? hash['oauth_ropc_client_id'] : SKIP
  oauth_ropc_client_secret =
    hash.key?('oauth_ropc_client_secret') ? hash['oauth_ropc_client_secret'] : SKIP
  oauth_tenant_id =
    hash.key?('oauth_tenant_id') ? hash['oauth_tenant_id'] : SKIP
  oauth_type = hash['oauth_type'] ||= SsoOauthTypeEnum::AZURE
  openroaming = SsoOpenroaming.from_hash(hash['openroaming']) if hash['openroaming']
  org_id = hash.key?('org_id') ? hash['org_id'] : SKIP
  role_attr_extraction =
    hash.key?('role_attr_extraction') ? hash['role_attr_extraction'] : SKIP
  role_attr_from = hash['role_attr_from'] ||= 'Role'
  scim_enabled = hash['scim_enabled'] ||= false
  scim_secret_token =
    hash.key?('scim_secret_token') ? hash['scim_secret_token'] : SKIP
  site_id = hash.key?('site_id') ? hash['site_id'] : SKIP

  # Create a new hash for additional properties, removing known properties.
  new_hash = hash.reject { |k, _| names.value?(k) }

  additional_properties = APIHelper.get_additional_properties(
    new_hash, proc { |value| value }
  )

  # Create object from extracted values.
  Sso.new(name,
          created_time,
          custom_logout_url,
          default_role,
          domain,
          group_filter,
          id,
          idp_cert,
          idp_sign_algo,
          idp_sso_url,
          idp_type,
          ignore_unmatched_roles,
          issuer,
          ldap_base_dn,
          ldap_bind_dn,
          ldap_bind_password,
          ldap_cacerts,
          ldap_client_cert,
          ldap_client_key,
          ldap_group_attr,
          ldap_group_dn,
          ldap_resolve_groups,
          ldap_server_hosts,
          ldap_type,
          ldap_user_filter,
          member_filter,
          modified_time,
          msp_id,
          mxedge_proxy,
          nameid_format,
          oauth_cc_client_id,
          oauth_cc_client_secret,
          oauth_discovery_url,
          oauth_ping_identity_region,
          oauth_provider_domain,
          oauth_ropc_client_id,
          oauth_ropc_client_secret,
          oauth_tenant_id,
          oauth_type,
          openroaming,
          org_id,
          role_attr_extraction,
          role_attr_from,
          scim_enabled,
          scim_secret_token,
          site_id,
          additional_properties)
end

.namesObject

A mapping from model property names to API property names.



240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
# File 'lib/mist_api/models/sso.rb', line 240

def self.names
  @_hash = {} if @_hash.nil?
  @_hash['created_time'] = 'created_time'
  @_hash['custom_logout_url'] = 'custom_logout_url'
  @_hash['default_role'] = 'default_role'
  @_hash['domain'] = 'domain'
  @_hash['group_filter'] = 'group_filter'
  @_hash['id'] = 'id'
  @_hash['idp_cert'] = 'idp_cert'
  @_hash['idp_sign_algo'] = 'idp_sign_algo'
  @_hash['idp_sso_url'] = 'idp_sso_url'
  @_hash['idp_type'] = 'idp_type'
  @_hash['ignore_unmatched_roles'] = 'ignore_unmatched_roles'
  @_hash['issuer'] = 'issuer'
  @_hash['ldap_base_dn'] = 'ldap_base_dn'
  @_hash['ldap_bind_dn'] = 'ldap_bind_dn'
  @_hash['ldap_bind_password'] = 'ldap_bind_password'
  @_hash['ldap_cacerts'] = 'ldap_cacerts'
  @_hash['ldap_client_cert'] = 'ldap_client_cert'
  @_hash['ldap_client_key'] = 'ldap_client_key'
  @_hash['ldap_group_attr'] = 'ldap_group_attr'
  @_hash['ldap_group_dn'] = 'ldap_group_dn'
  @_hash['ldap_resolve_groups'] = 'ldap_resolve_groups'
  @_hash['ldap_server_hosts'] = 'ldap_server_hosts'
  @_hash['ldap_type'] = 'ldap_type'
  @_hash['ldap_user_filter'] = 'ldap_user_filter'
  @_hash['member_filter'] = 'member_filter'
  @_hash['modified_time'] = 'modified_time'
  @_hash['msp_id'] = 'msp_id'
  @_hash['mxedge_proxy'] = 'mxedge_proxy'
  @_hash['name'] = 'name'
  @_hash['nameid_format'] = 'nameid_format'
  @_hash['oauth_cc_client_id'] = 'oauth_cc_client_id'
  @_hash['oauth_cc_client_secret'] = 'oauth_cc_client_secret'
  @_hash['oauth_discovery_url'] = 'oauth_discovery_url'
  @_hash['oauth_ping_identity_region'] = 'oauth_ping_identity_region'
  @_hash['oauth_provider_domain'] = 'oauth_provider_domain'
  @_hash['oauth_ropc_client_id'] = 'oauth_ropc_client_id'
  @_hash['oauth_ropc_client_secret'] = 'oauth_ropc_client_secret'
  @_hash['oauth_tenant_id'] = 'oauth_tenant_id'
  @_hash['oauth_type'] = 'oauth_type'
  @_hash['openroaming'] = 'openroaming'
  @_hash['org_id'] = 'org_id'
  @_hash['role_attr_extraction'] = 'role_attr_extraction'
  @_hash['role_attr_from'] = 'role_attr_from'
  @_hash['scim_enabled'] = 'scim_enabled'
  @_hash['scim_secret_token'] = 'scim_secret_token'
  @_hash['site_id'] = 'site_id'
  @_hash
end

.nullablesObject

An array for nullable fields



343
344
345
# File 'lib/mist_api/models/sso.rb', line 343

def self.nullables
  []
end

.optionalsObject

An array for optional fields



292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
# File 'lib/mist_api/models/sso.rb', line 292

def self.optionals
  %w[
    created_time
    custom_logout_url
    default_role
    domain
    group_filter
    id
    idp_cert
    idp_sign_algo
    idp_sso_url
    idp_type
    ignore_unmatched_roles
    issuer
    ldap_base_dn
    ldap_bind_dn
    ldap_bind_password
    ldap_cacerts
    ldap_client_cert
    ldap_client_key
    ldap_group_attr
    ldap_group_dn
    ldap_resolve_groups
    ldap_server_hosts
    ldap_type
    ldap_user_filter
    member_filter
    modified_time
    msp_id
    mxedge_proxy
    nameid_format
    oauth_cc_client_id
    oauth_cc_client_secret
    oauth_discovery_url
    oauth_ping_identity_region
    oauth_provider_domain
    oauth_ropc_client_id
    oauth_ropc_client_secret
    oauth_tenant_id
    oauth_type
    openroaming
    org_id
    role_attr_extraction
    role_attr_from
    scim_enabled
    scim_secret_token
    site_id
  ]
end

Instance Method Details

#inspectObject

Provides a debugging-friendly string with detailed object information.



578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
# File 'lib/mist_api/models/sso.rb', line 578

def inspect
  class_name = self.class.name.split('::').last
  "<#{class_name} created_time: #{@created_time.inspect}, custom_logout_url:"\
  " #{@custom_logout_url.inspect}, default_role: #{@default_role.inspect}, domain:"\
  " #{@domain.inspect}, group_filter: #{@group_filter.inspect}, id: #{@id.inspect}, idp_cert:"\
  " #{@idp_cert.inspect}, idp_sign_algo: #{@idp_sign_algo.inspect}, idp_sso_url:"\
  " #{@idp_sso_url.inspect}, idp_type: #{@idp_type.inspect}, ignore_unmatched_roles:"\
  " #{@ignore_unmatched_roles.inspect}, issuer: #{@issuer.inspect}, ldap_base_dn:"\
  " #{@ldap_base_dn.inspect}, ldap_bind_dn: #{@ldap_bind_dn.inspect}, ldap_bind_password:"\
  " #{@ldap_bind_password.inspect}, ldap_cacerts: #{@ldap_cacerts.inspect}, ldap_client_cert:"\
  " #{@ldap_client_cert.inspect}, ldap_client_key: #{@ldap_client_key.inspect},"\
  " ldap_group_attr: #{@ldap_group_attr.inspect}, ldap_group_dn: #{@ldap_group_dn.inspect},"\
  " ldap_resolve_groups: #{@ldap_resolve_groups.inspect}, ldap_server_hosts:"\
  " #{@ldap_server_hosts.inspect}, ldap_type: #{@ldap_type.inspect}, ldap_user_filter:"\
  " #{@ldap_user_filter.inspect}, member_filter: #{@member_filter.inspect}, modified_time:"\
  " #{@modified_time.inspect}, msp_id: #{@msp_id.inspect}, mxedge_proxy:"\
  " #{@mxedge_proxy.inspect}, name: #{@name.inspect}, nameid_format:"\
  " #{@nameid_format.inspect}, oauth_cc_client_id: #{@oauth_cc_client_id.inspect},"\
  " oauth_cc_client_secret: #{@oauth_cc_client_secret.inspect}, oauth_discovery_url:"\
  " #{@oauth_discovery_url.inspect}, oauth_ping_identity_region:"\
  " #{@oauth_ping_identity_region.inspect}, oauth_provider_domain:"\
  " #{@oauth_provider_domain.inspect}, oauth_ropc_client_id: #{@oauth_ropc_client_id.inspect},"\
  " oauth_ropc_client_secret: #{@oauth_ropc_client_secret.inspect}, oauth_tenant_id:"\
  " #{@oauth_tenant_id.inspect}, oauth_type: #{@oauth_type.inspect}, openroaming:"\
  " #{@openroaming.inspect}, org_id: #{@org_id.inspect}, role_attr_extraction:"\
  " #{@role_attr_extraction.inspect}, role_attr_from: #{@role_attr_from.inspect},"\
  " scim_enabled: #{@scim_enabled.inspect}, scim_secret_token: #{@scim_secret_token.inspect},"\
  " site_id: #{@site_id.inspect}, additional_properties: #{@additional_properties}>"
end

#to_sObject

Provides a human-readable string representation of the object.



551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
# File 'lib/mist_api/models/sso.rb', line 551

def to_s
  class_name = self.class.name.split('::').last
  "<#{class_name} created_time: #{@created_time}, custom_logout_url: #{@custom_logout_url},"\
  " default_role: #{@default_role}, domain: #{@domain}, group_filter: #{@group_filter}, id:"\
  " #{@id}, idp_cert: #{@idp_cert}, idp_sign_algo: #{@idp_sign_algo}, idp_sso_url:"\
  " #{@idp_sso_url}, idp_type: #{@idp_type}, ignore_unmatched_roles:"\
  " #{@ignore_unmatched_roles}, issuer: #{@issuer}, ldap_base_dn: #{@ldap_base_dn},"\
  " ldap_bind_dn: #{@ldap_bind_dn}, ldap_bind_password: #{@ldap_bind_password}, ldap_cacerts:"\
  " #{@ldap_cacerts}, ldap_client_cert: #{@ldap_client_cert}, ldap_client_key:"\
  " #{@ldap_client_key}, ldap_group_attr: #{@ldap_group_attr}, ldap_group_dn:"\
  " #{@ldap_group_dn}, ldap_resolve_groups: #{@ldap_resolve_groups}, ldap_server_hosts:"\
  " #{@ldap_server_hosts}, ldap_type: #{@ldap_type}, ldap_user_filter: #{@ldap_user_filter},"\
  " member_filter: #{@member_filter}, modified_time: #{@modified_time}, msp_id: #{@msp_id},"\
  " mxedge_proxy: #{@mxedge_proxy}, name: #{@name}, nameid_format: #{@nameid_format},"\
  " oauth_cc_client_id: #{@oauth_cc_client_id}, oauth_cc_client_secret:"\
  " #{@oauth_cc_client_secret}, oauth_discovery_url: #{@oauth_discovery_url},"\
  " oauth_ping_identity_region: #{@oauth_ping_identity_region}, oauth_provider_domain:"\
  " #{@oauth_provider_domain}, oauth_ropc_client_id: #{@oauth_ropc_client_id},"\
  " oauth_ropc_client_secret: #{@oauth_ropc_client_secret}, oauth_tenant_id:"\
  " #{@oauth_tenant_id}, oauth_type: #{@oauth_type}, openroaming: #{@openroaming}, org_id:"\
  " #{@org_id}, role_attr_extraction: #{@role_attr_extraction}, role_attr_from:"\
  " #{@role_attr_from}, scim_enabled: #{@scim_enabled}, scim_secret_token:"\
  " #{@scim_secret_token}, site_id: #{@site_id}, additional_properties:"\
  " #{@additional_properties}>"
end