create a smart group based on User Account Type?

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on
08-26-2020
02:02 PM
- last edited on
03-04-2025
09:28 AM
by
kh-richa_mig
I'm trying to determine which computers have a Mobile LDAP account that are Jamf enrolled. For example in a Computer's inventory record under Local User Accounts it has the UID, Account Type, Admin Yes/No.
Is there any way to pull the Type: Mobile LDAP into a smart group or some sort of reporting?
Labels:
- Labels:
-
Jamf Pro
1 REPLY 1
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on 08-26-2020 07:06 PM
@walt The following Extension Attribute code may prove helpful:
#!/bin/sh
loggedInUser=$(stat -f%Su /dev/console)
if [[ $( /usr/bin/dscl . read /Users/${loggedInUser} OriginalAuthenticationAuthority 2>/dev/null) ]]; then
echo "<result>$loggedInUser is an Active Directory Mobile account</result>"
else
echo "<result>$loggedInUser is a Local Directory account</result>"
fi
exit 0
Reply
