Add max_ber_size to freeipa sync ()

This commit is contained in:
Firstyear 2025-03-28 10:46:00 +10:00 committed by GitHub
parent 5edc6be51c
commit 567fe7b259
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 7 additions and 3 deletions
tools/iam_migrations
freeipa/src
ldap/src

View file

@ -16,6 +16,9 @@ pub struct Config {
pub sync_password_as_unix_password: Option<bool>,
/// Maximum LDAP message size (in kilobytes)
pub max_ber_size: Option<usize>,
// pub entry: Option<Vec<EntryConfig>>,
#[serde(flatten)]
pub entry_map: BTreeMap<Uuid, EntryConfig>,

View file

@ -306,6 +306,7 @@ async fn run_sync(
// Preflight check.
// * can we connect to ipa?
let mut ipa_client = match LdapClientBuilder::new(&sync_config.ipa_uri)
.max_ber_size(sync_config.max_ber_size)
.add_tls_ca(&sync_config.ipa_ca)
.build()
.await

View file

@ -113,11 +113,11 @@ pub struct Config {
#[serde(default)]
pub group_attr_schema: GroupAttrSchema,
#[serde(flatten)]
pub entry_map: BTreeMap<Uuid, EntryConfig>,
/// Maximum LDAP message size (in kilobytes)
pub max_ber_size: Option<usize>,
#[serde(flatten)]
pub entry_map: BTreeMap<Uuid, EntryConfig>,
}
#[derive(Debug, Deserialize, Default, Clone)]