Setting Passwords to Never Expire in BPOS

With Microsoft’s recent announcement of the Set-MSOnlineUserPasswordNeverExpire PowerShell Command it’s now possible to set user’s passwords to never expire in your BPOS subscription.  Below is a quick script to set all user’s passwords to never expire.

Before you can use the command you’ll need to download and install the latest version of the Microsoft Online Migration Tools:

Microsoft Online Services Migration Tools (32 bit)

Microsoft Online Services Migration Tools (64 bit)

 Then open the Migration Command Shell and run the following lines:

$creds = get-credential

$users = get-msonlineuser -enabled -resultsize 20000 -Credential $creds

$users | foreach {Set-MSOnlineUserPasswordNeverExpire -Identity $_.Identity -PasswordNeverExpire $True -Credential $creds}

Note that after the first line, you’ll be prompted for your BPOS Admin credentials.  The last command should be run on a single line.

If you create new users after the script is run, you’ll need to either re-run the script, or use the Set-MSOnlineUserPassword on a one off basis:

Set-MSOnlineUserPasswordNeverExpire -Identity jane.dow@contoso.com -PasswordNeverExpire $true -Credential $companyAdminCred

 

source: http://www.messageops.com/quick-tip-setting-passwords-to-never-expire-in-bpos

 

You may also like...

Leave a Reply

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