SuperAdmin where 2svEnrolled=FALSE

124 views
Skip to first unread message

Craig Harper

unread,
Mar 1, 2022, 10:52:24 AM3/1/22
to GAM for Google Workspace
Has anyone played with user "gam print" or "gam report" to display all SuperAdmin users who don't have 2svEnrolled?

Trying to find the initial list to pipe into another command to disable these accounts, then schedule this on a daily / weekly or so basis.

Thanks in advance for any pointers on the gam print / gam report line.

Ross Scroggs

unread,
Mar 1, 2022, 11:11:58 AM3/1/22
to google-ap...@googlegroups.com
Craig,

With Advanced GAM you could do the following:
gam print admins role _SEED_ADMIN_ROLE | gam redirect csv ./SuperAdmin2FA.csv multiprocess csv - gam user "~assignedToUser" print user fields isenrolledin2sv,isenforcedin2sv

Ross

--
You received this message because you are subscribed to the Google Groups "GAM for Google Workspace" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/d3054625-2b69-4621-a2f9-3e4a12156bcfn%40googlegroups.com.

Jay Lee

unread,
Mar 1, 2022, 11:17:57 AM3/1/22
to google-ap...@googlegroups.com
It's quicker and cleaner to let Google do all the hard work:

gam print users query "isAdmin=true isEnforcedIn2Sv=false"

Jay Lee


Jay Lee

unread,
Mar 1, 2022, 11:19:13 AM3/1/22
to google-ap...@googlegroups.com
Sorry, that should be:

gam print users query "isAdmin=true isEnrolledIn2Sv=false"

See:


for help with user queries.

Jay Lee

Reply all
Reply to author
Forward
0 new messages