03 Jul Contact Adder – Part 1
This month we would like to provide you with a small tool, which we have developed for internal use.
The problem
We use Office 365 for collaboration. Each of our employees has a mobile phone, either IOS or Android. Unfortunately, even when using the Outlook app on the phone, newly created Office 365 users are not automatically synchronized to the phone book of the phones. Telephone number changes are of course not automatically taken over either.
We wanted to change that.
Our solution
As a workaround for this problem, we wrote a small PowerShell script that synchronizes the Office 365 users with the local contacts of Outlook on the notebook. These contacts in turn are automatically synchronized by the Outlook App on the phone.
Implementation details
- Only contacts that are not empty and Exchange users and have a mobile phone number are exported.
- Since we had problems with the comparison of the email address field (partly the x500 address is listed there) we write the email address additionally into the field “User Field 1” and compare this.
- The script does not delete contacts. When someone leaves the company, the remaining employees can decide whether to delete the contact or update it with new and, if necessary, private contact information.
The script
You can find the script in our repository https://github.com/teal-technology-consulting/ContactAdder. It is licensed under the MIT license.
What‘s up next?
In the next step we will write a small setup, which creates a scheduled task for the script and we improve the logging a bit.
We would like to take this opportunity to thank some of the authors whose work and information we used during the development:
http://jamilpremji.com/post/157169397930/using-powershell-to-get-your-global-address-list [not available anymore at the time of the writing]
https://github.com/ITMicaH/Powershell-functions/tree/master/Office/Outlook
Source: freepik.com
LATEST POSTS
-
“Logging In Instead of Breaking In”: Why Your Identities Are the Biggest Security Risk
Attackers no longer “simply” break in, they LOG in. If you’re still relying on traditional defenses in 2026, we believe you’ve probably already lost the battle for your data....
01 April, 2026 -
Bye-bye RC4: Your guide to the Kerberos transition in April 2026
The clock is ticking for one of the longest-lasting (and most insecure) ciphers in our networks. Microsoft is getting serious and pushing for the shutdown of RC4 encryption in the Kerberos protocol....
29 January, 2026 -
Bye-bye, password frustration: Why TEAL is now going passwordless
As security consultants, we see every day that passwords are not only a security risk, but also slow you down massively in your everyday work. That's why we at TEAL have decided: ...
03 March, 2026

























