mirror of
https://github.com/goauthentik/authentik.git
synced 2026-06-18 03:19:51 +03:00
2f70351c90
* packages/client-go: init Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space> * format Signed-off-by: Jens Langhammer <jens@goauthentik.io> * remove mod/sum Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix translate Signed-off-by: Jens Langhammer <jens@goauthentik.io> * no go replace Signed-off-by: Jens Langhammer <jens@goauthentik.io> * update rust makefile with pwd Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space> * fix build Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix docs Signed-off-by: Jens Langhammer <jens@goauthentik.io> * don't need a version ig? Signed-off-by: Jens Langhammer <jens@goauthentik.io> * exclude go client from cspell Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix main docker build Signed-off-by: Jens Langhammer <jens@goauthentik.io> --------- Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space> Signed-off-by: Jens Langhammer <jens@goauthentik.io> Co-authored-by: Jens Langhammer <jens@goauthentik.io>
625 lines
19 KiB
Go
Generated
625 lines
19 KiB
Go
Generated
/*
|
|
authentik
|
|
|
|
Making authentication simple.
|
|
|
|
API version: 2026.5.0-rc1
|
|
Contact: hello@goauthentik.io
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package api
|
|
|
|
import (
|
|
"encoding/json"
|
|
"fmt"
|
|
)
|
|
|
|
// checks if the LDAPProviderRequest type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &LDAPProviderRequest{}
|
|
|
|
// LDAPProviderRequest LDAPProvider Serializer
|
|
type LDAPProviderRequest struct {
|
|
Name string `json:"name"`
|
|
// Flow used for authentication when the associated application is accessed by an un-authenticated user.
|
|
AuthenticationFlow NullableString `json:"authentication_flow,omitempty"`
|
|
// Flow used when authorizing this provider.
|
|
AuthorizationFlow string `json:"authorization_flow"`
|
|
// Flow used ending the session from a provider.
|
|
InvalidationFlow string `json:"invalidation_flow"`
|
|
PropertyMappings []string `json:"property_mappings,omitempty"`
|
|
// DN under which objects are accessible.
|
|
BaseDn *string `json:"base_dn,omitempty"`
|
|
Certificate NullableString `json:"certificate,omitempty"`
|
|
TlsServerName *string `json:"tls_server_name,omitempty"`
|
|
// The start for uidNumbers, this number is added to the user.pk to make sure that the numbers aren't too low for POSIX users. Default is 2000 to ensure that we don't collide with local users uidNumber
|
|
UidStartNumber *int32 `json:"uid_start_number,omitempty"`
|
|
// The start for gidNumbers, this number is added to a number generated from the group.pk to make sure that the numbers aren't too low for POSIX groups. Default is 4000 to ensure that we don't collide with local groups or users primary groups gidNumber
|
|
GidStartNumber *int32 `json:"gid_start_number,omitempty"`
|
|
SearchMode *LDAPAPIAccessMode `json:"search_mode,omitempty"`
|
|
BindMode *LDAPAPIAccessMode `json:"bind_mode,omitempty"`
|
|
// When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.
|
|
MfaSupport *bool `json:"mfa_support,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _LDAPProviderRequest LDAPProviderRequest
|
|
|
|
// NewLDAPProviderRequest instantiates a new LDAPProviderRequest object
|
|
// This constructor will assign default values to properties that have it defined,
|
|
// and makes sure properties required by API are set, but the set of arguments
|
|
// will change when the set of required properties is changed
|
|
func NewLDAPProviderRequest(name string, authorizationFlow string, invalidationFlow string) *LDAPProviderRequest {
|
|
this := LDAPProviderRequest{}
|
|
this.Name = name
|
|
this.AuthorizationFlow = authorizationFlow
|
|
this.InvalidationFlow = invalidationFlow
|
|
return &this
|
|
}
|
|
|
|
// NewLDAPProviderRequestWithDefaults instantiates a new LDAPProviderRequest object
|
|
// This constructor will only assign default values to properties that have it defined,
|
|
// but it doesn't guarantee that properties required by API are set
|
|
func NewLDAPProviderRequestWithDefaults() *LDAPProviderRequest {
|
|
this := LDAPProviderRequest{}
|
|
return &this
|
|
}
|
|
|
|
// GetName returns the Name field value
|
|
func (o *LDAPProviderRequest) GetName() string {
|
|
if o == nil {
|
|
var ret string
|
|
return ret
|
|
}
|
|
|
|
return o.Name
|
|
}
|
|
|
|
// GetNameOk returns a tuple with the Name field value
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetNameOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return &o.Name, true
|
|
}
|
|
|
|
// SetName sets field value
|
|
func (o *LDAPProviderRequest) SetName(v string) {
|
|
o.Name = v
|
|
}
|
|
|
|
// GetAuthenticationFlow returns the AuthenticationFlow field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *LDAPProviderRequest) GetAuthenticationFlow() string {
|
|
if o == nil || IsNil(o.AuthenticationFlow.Get()) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.AuthenticationFlow.Get()
|
|
}
|
|
|
|
// GetAuthenticationFlowOk returns a tuple with the AuthenticationFlow field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *LDAPProviderRequest) GetAuthenticationFlowOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return o.AuthenticationFlow.Get(), o.AuthenticationFlow.IsSet()
|
|
}
|
|
|
|
// HasAuthenticationFlow returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasAuthenticationFlow() bool {
|
|
if o != nil && o.AuthenticationFlow.IsSet() {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetAuthenticationFlow gets a reference to the given NullableString and assigns it to the AuthenticationFlow field.
|
|
func (o *LDAPProviderRequest) SetAuthenticationFlow(v string) {
|
|
o.AuthenticationFlow.Set(&v)
|
|
}
|
|
|
|
// SetAuthenticationFlowNil sets the value for AuthenticationFlow to be an explicit nil
|
|
func (o *LDAPProviderRequest) SetAuthenticationFlowNil() {
|
|
o.AuthenticationFlow.Set(nil)
|
|
}
|
|
|
|
// UnsetAuthenticationFlow ensures that no value is present for AuthenticationFlow, not even an explicit nil
|
|
func (o *LDAPProviderRequest) UnsetAuthenticationFlow() {
|
|
o.AuthenticationFlow.Unset()
|
|
}
|
|
|
|
// GetAuthorizationFlow returns the AuthorizationFlow field value
|
|
func (o *LDAPProviderRequest) GetAuthorizationFlow() string {
|
|
if o == nil {
|
|
var ret string
|
|
return ret
|
|
}
|
|
|
|
return o.AuthorizationFlow
|
|
}
|
|
|
|
// GetAuthorizationFlowOk returns a tuple with the AuthorizationFlow field value
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetAuthorizationFlowOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return &o.AuthorizationFlow, true
|
|
}
|
|
|
|
// SetAuthorizationFlow sets field value
|
|
func (o *LDAPProviderRequest) SetAuthorizationFlow(v string) {
|
|
o.AuthorizationFlow = v
|
|
}
|
|
|
|
// GetInvalidationFlow returns the InvalidationFlow field value
|
|
func (o *LDAPProviderRequest) GetInvalidationFlow() string {
|
|
if o == nil {
|
|
var ret string
|
|
return ret
|
|
}
|
|
|
|
return o.InvalidationFlow
|
|
}
|
|
|
|
// GetInvalidationFlowOk returns a tuple with the InvalidationFlow field value
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetInvalidationFlowOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return &o.InvalidationFlow, true
|
|
}
|
|
|
|
// SetInvalidationFlow sets field value
|
|
func (o *LDAPProviderRequest) SetInvalidationFlow(v string) {
|
|
o.InvalidationFlow = v
|
|
}
|
|
|
|
// GetPropertyMappings returns the PropertyMappings field value if set, zero value otherwise.
|
|
func (o *LDAPProviderRequest) GetPropertyMappings() []string {
|
|
if o == nil || IsNil(o.PropertyMappings) {
|
|
var ret []string
|
|
return ret
|
|
}
|
|
return o.PropertyMappings
|
|
}
|
|
|
|
// GetPropertyMappingsOk returns a tuple with the PropertyMappings field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetPropertyMappingsOk() ([]string, bool) {
|
|
if o == nil || IsNil(o.PropertyMappings) {
|
|
return nil, false
|
|
}
|
|
return o.PropertyMappings, true
|
|
}
|
|
|
|
// HasPropertyMappings returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasPropertyMappings() bool {
|
|
if o != nil && !IsNil(o.PropertyMappings) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetPropertyMappings gets a reference to the given []string and assigns it to the PropertyMappings field.
|
|
func (o *LDAPProviderRequest) SetPropertyMappings(v []string) {
|
|
o.PropertyMappings = v
|
|
}
|
|
|
|
// GetBaseDn returns the BaseDn field value if set, zero value otherwise.
|
|
func (o *LDAPProviderRequest) GetBaseDn() string {
|
|
if o == nil || IsNil(o.BaseDn) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.BaseDn
|
|
}
|
|
|
|
// GetBaseDnOk returns a tuple with the BaseDn field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetBaseDnOk() (*string, bool) {
|
|
if o == nil || IsNil(o.BaseDn) {
|
|
return nil, false
|
|
}
|
|
return o.BaseDn, true
|
|
}
|
|
|
|
// HasBaseDn returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasBaseDn() bool {
|
|
if o != nil && !IsNil(o.BaseDn) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetBaseDn gets a reference to the given string and assigns it to the BaseDn field.
|
|
func (o *LDAPProviderRequest) SetBaseDn(v string) {
|
|
o.BaseDn = &v
|
|
}
|
|
|
|
// GetCertificate returns the Certificate field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *LDAPProviderRequest) GetCertificate() string {
|
|
if o == nil || IsNil(o.Certificate.Get()) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Certificate.Get()
|
|
}
|
|
|
|
// GetCertificateOk returns a tuple with the Certificate field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *LDAPProviderRequest) GetCertificateOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return o.Certificate.Get(), o.Certificate.IsSet()
|
|
}
|
|
|
|
// HasCertificate returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasCertificate() bool {
|
|
if o != nil && o.Certificate.IsSet() {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetCertificate gets a reference to the given NullableString and assigns it to the Certificate field.
|
|
func (o *LDAPProviderRequest) SetCertificate(v string) {
|
|
o.Certificate.Set(&v)
|
|
}
|
|
|
|
// SetCertificateNil sets the value for Certificate to be an explicit nil
|
|
func (o *LDAPProviderRequest) SetCertificateNil() {
|
|
o.Certificate.Set(nil)
|
|
}
|
|
|
|
// UnsetCertificate ensures that no value is present for Certificate, not even an explicit nil
|
|
func (o *LDAPProviderRequest) UnsetCertificate() {
|
|
o.Certificate.Unset()
|
|
}
|
|
|
|
// GetTlsServerName returns the TlsServerName field value if set, zero value otherwise.
|
|
func (o *LDAPProviderRequest) GetTlsServerName() string {
|
|
if o == nil || IsNil(o.TlsServerName) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.TlsServerName
|
|
}
|
|
|
|
// GetTlsServerNameOk returns a tuple with the TlsServerName field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetTlsServerNameOk() (*string, bool) {
|
|
if o == nil || IsNil(o.TlsServerName) {
|
|
return nil, false
|
|
}
|
|
return o.TlsServerName, true
|
|
}
|
|
|
|
// HasTlsServerName returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasTlsServerName() bool {
|
|
if o != nil && !IsNil(o.TlsServerName) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetTlsServerName gets a reference to the given string and assigns it to the TlsServerName field.
|
|
func (o *LDAPProviderRequest) SetTlsServerName(v string) {
|
|
o.TlsServerName = &v
|
|
}
|
|
|
|
// GetUidStartNumber returns the UidStartNumber field value if set, zero value otherwise.
|
|
func (o *LDAPProviderRequest) GetUidStartNumber() int32 {
|
|
if o == nil || IsNil(o.UidStartNumber) {
|
|
var ret int32
|
|
return ret
|
|
}
|
|
return *o.UidStartNumber
|
|
}
|
|
|
|
// GetUidStartNumberOk returns a tuple with the UidStartNumber field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetUidStartNumberOk() (*int32, bool) {
|
|
if o == nil || IsNil(o.UidStartNumber) {
|
|
return nil, false
|
|
}
|
|
return o.UidStartNumber, true
|
|
}
|
|
|
|
// HasUidStartNumber returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasUidStartNumber() bool {
|
|
if o != nil && !IsNil(o.UidStartNumber) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetUidStartNumber gets a reference to the given int32 and assigns it to the UidStartNumber field.
|
|
func (o *LDAPProviderRequest) SetUidStartNumber(v int32) {
|
|
o.UidStartNumber = &v
|
|
}
|
|
|
|
// GetGidStartNumber returns the GidStartNumber field value if set, zero value otherwise.
|
|
func (o *LDAPProviderRequest) GetGidStartNumber() int32 {
|
|
if o == nil || IsNil(o.GidStartNumber) {
|
|
var ret int32
|
|
return ret
|
|
}
|
|
return *o.GidStartNumber
|
|
}
|
|
|
|
// GetGidStartNumberOk returns a tuple with the GidStartNumber field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetGidStartNumberOk() (*int32, bool) {
|
|
if o == nil || IsNil(o.GidStartNumber) {
|
|
return nil, false
|
|
}
|
|
return o.GidStartNumber, true
|
|
}
|
|
|
|
// HasGidStartNumber returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasGidStartNumber() bool {
|
|
if o != nil && !IsNil(o.GidStartNumber) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetGidStartNumber gets a reference to the given int32 and assigns it to the GidStartNumber field.
|
|
func (o *LDAPProviderRequest) SetGidStartNumber(v int32) {
|
|
o.GidStartNumber = &v
|
|
}
|
|
|
|
// GetSearchMode returns the SearchMode field value if set, zero value otherwise.
|
|
func (o *LDAPProviderRequest) GetSearchMode() LDAPAPIAccessMode {
|
|
if o == nil || IsNil(o.SearchMode) {
|
|
var ret LDAPAPIAccessMode
|
|
return ret
|
|
}
|
|
return *o.SearchMode
|
|
}
|
|
|
|
// GetSearchModeOk returns a tuple with the SearchMode field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetSearchModeOk() (*LDAPAPIAccessMode, bool) {
|
|
if o == nil || IsNil(o.SearchMode) {
|
|
return nil, false
|
|
}
|
|
return o.SearchMode, true
|
|
}
|
|
|
|
// HasSearchMode returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasSearchMode() bool {
|
|
if o != nil && !IsNil(o.SearchMode) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetSearchMode gets a reference to the given LDAPAPIAccessMode and assigns it to the SearchMode field.
|
|
func (o *LDAPProviderRequest) SetSearchMode(v LDAPAPIAccessMode) {
|
|
o.SearchMode = &v
|
|
}
|
|
|
|
// GetBindMode returns the BindMode field value if set, zero value otherwise.
|
|
func (o *LDAPProviderRequest) GetBindMode() LDAPAPIAccessMode {
|
|
if o == nil || IsNil(o.BindMode) {
|
|
var ret LDAPAPIAccessMode
|
|
return ret
|
|
}
|
|
return *o.BindMode
|
|
}
|
|
|
|
// GetBindModeOk returns a tuple with the BindMode field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetBindModeOk() (*LDAPAPIAccessMode, bool) {
|
|
if o == nil || IsNil(o.BindMode) {
|
|
return nil, false
|
|
}
|
|
return o.BindMode, true
|
|
}
|
|
|
|
// HasBindMode returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasBindMode() bool {
|
|
if o != nil && !IsNil(o.BindMode) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetBindMode gets a reference to the given LDAPAPIAccessMode and assigns it to the BindMode field.
|
|
func (o *LDAPProviderRequest) SetBindMode(v LDAPAPIAccessMode) {
|
|
o.BindMode = &v
|
|
}
|
|
|
|
// GetMfaSupport returns the MfaSupport field value if set, zero value otherwise.
|
|
func (o *LDAPProviderRequest) GetMfaSupport() bool {
|
|
if o == nil || IsNil(o.MfaSupport) {
|
|
var ret bool
|
|
return ret
|
|
}
|
|
return *o.MfaSupport
|
|
}
|
|
|
|
// GetMfaSupportOk returns a tuple with the MfaSupport field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *LDAPProviderRequest) GetMfaSupportOk() (*bool, bool) {
|
|
if o == nil || IsNil(o.MfaSupport) {
|
|
return nil, false
|
|
}
|
|
return o.MfaSupport, true
|
|
}
|
|
|
|
// HasMfaSupport returns a boolean if a field has been set.
|
|
func (o *LDAPProviderRequest) HasMfaSupport() bool {
|
|
if o != nil && !IsNil(o.MfaSupport) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetMfaSupport gets a reference to the given bool and assigns it to the MfaSupport field.
|
|
func (o *LDAPProviderRequest) SetMfaSupport(v bool) {
|
|
o.MfaSupport = &v
|
|
}
|
|
|
|
func (o LDAPProviderRequest) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o LDAPProviderRequest) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
toSerialize["name"] = o.Name
|
|
if o.AuthenticationFlow.IsSet() {
|
|
toSerialize["authentication_flow"] = o.AuthenticationFlow.Get()
|
|
}
|
|
toSerialize["authorization_flow"] = o.AuthorizationFlow
|
|
toSerialize["invalidation_flow"] = o.InvalidationFlow
|
|
if !IsNil(o.PropertyMappings) {
|
|
toSerialize["property_mappings"] = o.PropertyMappings
|
|
}
|
|
if !IsNil(o.BaseDn) {
|
|
toSerialize["base_dn"] = o.BaseDn
|
|
}
|
|
if o.Certificate.IsSet() {
|
|
toSerialize["certificate"] = o.Certificate.Get()
|
|
}
|
|
if !IsNil(o.TlsServerName) {
|
|
toSerialize["tls_server_name"] = o.TlsServerName
|
|
}
|
|
if !IsNil(o.UidStartNumber) {
|
|
toSerialize["uid_start_number"] = o.UidStartNumber
|
|
}
|
|
if !IsNil(o.GidStartNumber) {
|
|
toSerialize["gid_start_number"] = o.GidStartNumber
|
|
}
|
|
if !IsNil(o.SearchMode) {
|
|
toSerialize["search_mode"] = o.SearchMode
|
|
}
|
|
if !IsNil(o.BindMode) {
|
|
toSerialize["bind_mode"] = o.BindMode
|
|
}
|
|
if !IsNil(o.MfaSupport) {
|
|
toSerialize["mfa_support"] = o.MfaSupport
|
|
}
|
|
|
|
for key, value := range o.AdditionalProperties {
|
|
toSerialize[key] = value
|
|
}
|
|
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *LDAPProviderRequest) UnmarshalJSON(data []byte) (err error) {
|
|
// This validates that all required properties are included in the JSON object
|
|
// by unmarshalling the object into a generic map with string keys and checking
|
|
// that every required field exists as a key in the generic map.
|
|
requiredProperties := []string{
|
|
"name",
|
|
"authorization_flow",
|
|
"invalidation_flow",
|
|
}
|
|
|
|
allProperties := make(map[string]interface{})
|
|
|
|
err = json.Unmarshal(data, &allProperties)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
for _, requiredProperty := range requiredProperties {
|
|
if _, exists := allProperties[requiredProperty]; !exists {
|
|
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
|
}
|
|
}
|
|
|
|
varLDAPProviderRequest := _LDAPProviderRequest{}
|
|
|
|
err = json.Unmarshal(data, &varLDAPProviderRequest)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = LDAPProviderRequest(varLDAPProviderRequest)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "name")
|
|
delete(additionalProperties, "authentication_flow")
|
|
delete(additionalProperties, "authorization_flow")
|
|
delete(additionalProperties, "invalidation_flow")
|
|
delete(additionalProperties, "property_mappings")
|
|
delete(additionalProperties, "base_dn")
|
|
delete(additionalProperties, "certificate")
|
|
delete(additionalProperties, "tls_server_name")
|
|
delete(additionalProperties, "uid_start_number")
|
|
delete(additionalProperties, "gid_start_number")
|
|
delete(additionalProperties, "search_mode")
|
|
delete(additionalProperties, "bind_mode")
|
|
delete(additionalProperties, "mfa_support")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableLDAPProviderRequest struct {
|
|
value *LDAPProviderRequest
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableLDAPProviderRequest) Get() *LDAPProviderRequest {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableLDAPProviderRequest) Set(val *LDAPProviderRequest) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableLDAPProviderRequest) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableLDAPProviderRequest) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableLDAPProviderRequest(val *LDAPProviderRequest) *NullableLDAPProviderRequest {
|
|
return &NullableLDAPProviderRequest{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableLDAPProviderRequest) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableLDAPProviderRequest) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|