nicolonsky / IntuneDriveMapping

Generate PowerShell scripts to map network drives on Intune managed Windows 10 devices
https://intunedrivemapping.azurewebsites.net/
MIT License
148 stars 17 forks source link

Can the Script handle Nested AD Groups? #23

Open DJITS-NL opened 3 years ago

DJITS-NL commented 3 years ago

Hi,

First of all Thanx a lot for your solution. I do have a question though.

I created the script for a specific AD group that has nested groups in it and it seems to only works if my user is in the main group itself. Is this correct? And if so would this be easy to change it to also check nested groups?

Regards, DJITS

RefleCs commented 3 years ago

I think it should work it does a query via LDAP to AD. But that would be a simple test I recon.

DJITS-NL commented 3 years ago

I did some more testing and it seems that the Default group Domain Users is not working. Any idea why?

Boss-man commented 3 years ago

The "Domain Users" group is probably set as the primary group for the user in AD and not assigned directly as an AD group.