In order to see users using the ldap connection I need people login once into the drupal site, is it possible to avoid it?
I need to set group permissions and users permissions before they login the first time, so I need to choose people via ldap and assign them, is it possible?
I read a lot of topic about users import but no one give a secure solution.
Thank you in advance.
Fil

Comments

kevishie’s picture

Version: 5.x-1.3 » 6.x-1.x-dev

I am having the same problem. I need to be able to add users from LDAP before they login once because I need to setup their permissions before they login.

johnbarclay’s picture

The way I do this is:

1. Set up an LDAP group for each drupal role I use.
2. Set permissions on that drupal role.
3. Map the ldap group to a drupal role using the ldap groups module.

With this approach, you don't need to worry about creating the accounts before the user signs in.

arnoldc’s picture

Are there some ways I can map users in the same LDAP group to a different Drupal role, say, based on a custom user list.

There is a user filter function which I can use to restrict who can access the site. But since they all belong to the same LDAP group, I need to find hooks so I can assign them to a different Drupal role accordingly. Thanks.

miglius’s picture

Status: Active » Closed (won't fix)

The module provides a way to map LDAP groups to a drupal roles. From your description I see that you need a very custom solution which cannot be put in a baseline.

I can recommend to create a dedicated group in LDAP which should be mapped to a drupal role.

miglius’s picture

#396574: LDAPsync component should solve this issue.