Posted on 09-17-2024 08:35 AM
I'm trying to find a functional EA under Sonoma that I can use to create a search for users who still have mobile accounts. Does anyone have one that works for builds later than 14.3? I'm unsure what may have changed against other EAs I've found here.
Posted on 09-17-2024 12:28 PM
It should not be too hard, you just use dscl to search users UniqueID's and the obnoxiously high ID's are mobile accounts.
Posted on 09-17-2024 02:25 PM
#!/bin/sh
NETACCLIST=$(dscl . list /Users OriginalNodeName | awk '{print $1}' 2>/dev/null)
if [ "$NETACCLIST" == "" ]; then
echo "<result>No Network Accounts</result>"
else
echo "<result>$NETACCLIST</result>"
fi
exit 0