chechpaekoldap: forwardings
This commit is contained in:
@@ -163,12 +163,12 @@ with Ldap() as ldap:
|
|||||||
ldap_forwardings = ldap.get_mail_forwardings()
|
ldap_forwardings = ldap.get_mail_forwardings()
|
||||||
for ldap_user in ldap_forwardings:
|
for ldap_user in ldap_forwardings:
|
||||||
ldap_user = ldap_user[1]
|
ldap_user = ldap_user[1]
|
||||||
paheko_entry = [x for x in membres if x["email"] == ldap_user["mail"][0].decode() or (x["emails_rattaches"] and ldap_user["mail"][0].decode() in x["emails_rattaches"])]
|
paheko_entry = [x for x in membres if x["email"] == ldap_user["mailAlias"][0].decode() or (x["forward"] and ldap_user["mailAlias"][0].decode() in x["forward"])]
|
||||||
paheko_entry = paheko_entry[0] if len(paheko_entry) else None
|
paheko_entry = paheko_entry[0] if len(paheko_entry) else None
|
||||||
if paheko_entry:
|
if paheko_entry:
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
not_in_paheko.append(ldap_user["mail"][0].decode() + " (forwarding)")
|
not_in_paheko.append(ldap_user["mailAlias"][0].decode() + " (forwarding)")
|
||||||
|
|
||||||
|
|
||||||
print("Mails dans paheko mais pas dans le LDAP :")
|
print("Mails dans paheko mais pas dans le LDAP :")
|
||||||
|
|||||||
Reference in New Issue
Block a user