Skip to content

Commit

Permalink
passwd: handle LDAP auto-bind use case as well
Browse files Browse the repository at this point in the history
Signed-off-by: Alexander Bokovoy <[email protected]>
Reviewed-By: Thomas Woerner <[email protected]>
Reviewed-By: Rob Crittenden <[email protected]>
Reviewed-By: Rafael Guterres Jeffman <[email protected]>
  • Loading branch information
abbra authored and antoniotorresm committed May 22, 2024
1 parent e386e22 commit 902c8b0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ipaserver/plugins/passwd.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ def execute(self, principal, password, current_password, **options):
DN(api.env.container_user, api.env.basedn)
)

if principal == getattr(context, 'principal') and \
if principal == getattr(context, 'principal', None) and \
current_password == MAGIC_VALUE:
# No cheating
logger.warning('User attempted to change password using magic '
Expand Down

0 comments on commit 902c8b0

Please sign in to comment.