Skip to main content
Question

Extension attribute to see if Internet accounts -> mail app and microsoft exchange being used

  • August 24, 2022
  • 1 reply
  • 6 views

Forum|alt.badge.img+6

Hi,

 

can someone provide guidance on how i can collect data on if someone is using mail app for google or microsoft exchange setup through internet accounts. and if they are force logout.

 

thank you

1 reply

Forum|alt.badge.img+11
  • Valued Contributor
  • 201 replies
  • November 3, 2022

I just wrote an EA that will show if Mail.app is configured for Exchange.

 

#!/bin/bash loggedInUser=$( /usr/bin/who | /usr/bin/awk '/console/{ print $1 }' ) if [[ -e /Users/$loggedInUser/Library/Application\\ Support/com.apple.exchangesync/exchangesync.active ]]; then echo "<result>True</result>" else echo "<result>False</result>" fi