Skip to main content

clientapi_pbs/models/
config_access_update_ldap_request.rs

1/*
2 * Proxmox Backup Server API
3 *
4 * Generated from apidoc.js. NOT an official Proxmox specification. See https://pbs.proxmox.com/docs/api-viewer/ for the upstream documentation.
5 *
6 * The version of the OpenAPI document: 9.x
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct ConfigAccessUpdateLdapRequest {
16
17    /// LDAP Domain
18    #[serde(rename = "base-dn", skip_serializing_if = "Option::is_none")]
19    pub base_dn: Option<String>,
20
21    /// LDAP Domain
22    #[serde(rename = "bind-dn", skip_serializing_if = "Option::is_none")]
23    pub bind_dn: Option<String>,
24
25    /// CA certificate to use for the server. The path can point to either a file, or a directory. If it points to a file, the PEM-formatted X.509 certificate stored at the path will be added as a trusted certificate. If the path points to a directory, the directory replaces the system's default certificate store at `/etc/ssl/certs` - Every file in the directory will be loaded as a trusted certificate.
26    #[serde(rename = "capath", skip_serializing_if = "Option::is_none")]
27    pub capath: Option<String>,
28
29    /// Comment.
30    #[serde(rename = "comment", skip_serializing_if = "Option::is_none")]
31    pub comment: Option<String>,
32
33    /// True if you want this to be the default realm selected on login.
34    #[serde(rename = "default", skip_serializing_if = "Option::is_none")]
35    pub default: Option<bool>,
36
37    /// List of properties to delete.
38    #[serde(rename = "delete", skip_serializing_if = "Option::is_none")]
39    pub delete: Option<Vec<models::PbsDeleteEnum>>,
40
41    /// Prevent changes if current configuration file has different SHA256 digest. This can be used to prevent concurrent modifications.
42    #[serde(rename = "digest", skip_serializing_if = "Option::is_none")]
43    pub digest: Option<String>,
44
45    /// Custom LDAP search filter for user sync
46    #[serde(rename = "filter", skip_serializing_if = "Option::is_none")]
47    pub filter: Option<String>,
48
49    /// LDAP connection type
50    #[serde(rename = "mode", skip_serializing_if = "Option::is_none")]
51    pub mode: Option<models::PbsModeEnum>,
52
53    /// LDAP bind password
54    #[serde(rename = "password", skip_serializing_if = "Option::is_none")]
55    pub password: Option<String>,
56
57    /// Port
58    #[serde(rename = "port", skip_serializing_if = "Option::is_none")]
59    pub port: Option<i32>,
60
61    /// LDAP server address
62    #[serde(rename = "server1", skip_serializing_if = "Option::is_none")]
63    pub server1: Option<String>,
64
65    /// Fallback LDAP server address
66    #[serde(rename = "server2", skip_serializing_if = "Option::is_none")]
67    pub server2: Option<String>,
68
69    /// Comma-separated list of key=value pairs for specifying which LDAP attributes map to which PBS user field. For example, to map the LDAP attribute ``mail`` to PBS's ``email``, write ``email=mail``.
70    #[serde(rename = "sync-attributes", skip_serializing_if = "Option::is_none")]
71    pub sync_attributes: Option<Box<models::PbsSyncAttributesField>>,
72
73    /// sync defaults options
74    #[serde(rename = "sync-defaults-options", skip_serializing_if = "Option::is_none")]
75    pub sync_defaults_options: Option<Box<models::PbsSyncDefaultsOptionsField>>,
76
77    /// Username attribute. Used to map a ``userid`` to LDAP to an LDAP ``dn``.
78    #[serde(rename = "user-attr", skip_serializing_if = "Option::is_none")]
79    pub user_attr: Option<String>,
80
81    /// Comma-separated list of allowed objectClass values for user synchronization. For instance, if ``user-classes`` is set to ``person,user``, then user synchronization will consider all LDAP entities where ``objectClass: person`` `or` ``objectClass: user``.
82    #[serde(rename = "user-classes", skip_serializing_if = "Option::is_none")]
83    pub user_classes: Option<Box<models::PbsUserClassesField>>,
84
85    /// Verify server certificate
86    #[serde(rename = "verify", skip_serializing_if = "Option::is_none")]
87    pub verify: Option<bool>,
88
89
90}
91
92impl ConfigAccessUpdateLdapRequest {
93    pub fn new() -> ConfigAccessUpdateLdapRequest {
94        ConfigAccessUpdateLdapRequest {
95            
96            base_dn: None,
97            
98            bind_dn: None,
99            
100            capath: None,
101            
102            comment: None,
103            
104            default: None,
105            
106            delete: None,
107            
108            digest: None,
109            
110            filter: None,
111            
112            mode: None,
113            
114            password: None,
115            
116            port: None,
117            
118            server1: None,
119            
120            server2: None,
121            
122            sync_attributes: None,
123            
124            sync_defaults_options: None,
125            
126            user_attr: None,
127            
128            user_classes: None,
129            
130            verify: None,
131            
132        }
133    }
134}
135
136