Adldap2 / Adldap2-Laravel

LDAP Authentication & Management for Laravel
MIT License
911 stars 184 forks source link

Adldap import delete #806

Closed MarcosRLeao closed 5 years ago

MarcosRLeao commented 5 years ago

Description:

php artisan adldap:import --delete

With this I only import the active users in my laravel bank? Is there no risk of deleting anything in the active directory?

Ty!

stevebauman commented 5 years ago

Hi @MarcosRLeao,

The --delete option will only soft-delete your imported LDAP users located in your applications database, if your configured eloquent model has the SoftDeletes trait and the users LDAP account is disabled.

The import command is read only from your LDAP server. It does not write-back anything, nor delete users.

You can read more here:

https://adldap2.github.io/Adldap2-Laravel/#/auth/importing?id=delete

As well as view the source code here:

https://github.com/Adldap2/Adldap2-Laravel/blob/c2809bcca39bd51fe3fbe426c5dc32e89a868a42/src/Commands/Console/Import.php#L283-L311

I hope that answers your question!

MarcosRLeao commented 5 years ago

Ty, How do I only import active AD users? Have many disabled users in my AD

Sorry my english.