Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed Ldap sync field clear bug #13391

Merged
merged 3 commits into from
Aug 17, 2023

Conversation

Godmartinz
Copy link
Collaborator

Description

If an LDAP settings field was left blank for a sync it would null the existing users' matching fields. This applies a check on the ldap settings options itself.

Fixes #13373

Type of change

Please delete options that are not relevant.

  • [ x] Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Test A
  • Test B

Test Configuration:

  • PHP version:
  • MySQL version
  • Webserver version
  • OS version

Checklist:

@what-the-diff
Copy link

what-the-diff bot commented Aug 1, 2023

PR Summary

  • Enhancements in Data Handling
    The update enforces checks for empty data before feeding user information from LDAP server into our system. This results in cleaner data management, by preventing potential interruptions due to missing or null values.

@Godmartinz Godmartinz changed the title Ldap sync field clear bug Fixed Ldap sync field clear bug Aug 1, 2023
@snipe
Copy link
Owner

snipe commented Aug 9, 2023

Thanks for this :) Two quick things - looks like we have a merge conflict here - can you handle that? Second, is it a possible scenario that we'd end up with a blank value vs null?

@snipe
Copy link
Owner

snipe commented Aug 15, 2023

Ping @Godmartinz

@Godmartinz
Copy link
Collaborator Author

Godmartinz commented Aug 15, 2023

Ah! sorry, Conflicts are fixed. You brought up a good point about blank space. there shouldn't be any spaces allowed, before, in between, or after. going to add some validation for this in another PR against the livewire changes.

@Godmartinz
Copy link
Collaborator Author

@snipe as mentioned in the dev meet yesterday, i posted a separate PR that trims whitespace off an values for the ldap attributes. You could technically put a blank in for any field, but it would not sync anything if you did.

@snipe snipe merged commit 0ee032a into snipe:develop Aug 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants