A simple Powershell script to import photos from a directory into AD. The photos should be named with the format “samAccountName.jpg”, less than 10k in size, and recommended dimensions of 96×96.

To get the photos into the proper format, I used imageMagick’s “mogrify” command.

mogrify -path OUTPUT_PATH -format jpg -thumbnail 96x96 *.jpg

Embedded github “Gist”:

Follow me on social media:

Leave a comment

Your email address will not be published. Required fields are marked *