默认Exchange 2013中没有单独为上传修改头像图片定义Management Role,所以如果既想让用户修改头像图片,又不想用户拥有全部的MyContactInformation角色的权限,可以自定义一个用于上传头像图片的角色,并应用于Default Role Assignment Policy,具体步骤如下:
1. 增加新的管理角色:
New-ManagementRole -Name “MyPhotoInformation” -Parent MyContactInformation -Description “This role enables individual users to upload and change their photo where show on Outlook client and OWA (Outlook Web Access) App. This is a custom role created from the ‘My ContactInformation’ parent role by Nile Jiang on 2012-11-11.”
2. 确认当前角色中的命令是否正确:
PS C:> (Get-ManagementRole MyPhotoInformation).roleentries
(Microsoft.Exchange.Management.PowerShell.E2010) Get-Mailbox -Identity
(Microsoft.Exchange.Management.PowerShell.E2010) Get-UserPhoto -Identity -Preview
(Microsoft.Exchange.Management.PowerShell.E2010) Remove-UserPhoto -Identity
(Microsoft.Exchange.Management.PowerShell.E2010) Set-User -City -CountryOrRegion -Fax -GeoCoordinates -HomePhone -Identity -MobilePhone -Office -Pager -Phone -PostalCode -PostOfficeBox -StateOrProvince -StreetAddress -WebPage(Microsoft.Exchange.Management.PowerShell.E2010) Set-UserPhoto -Cancel -Confirm -Identity -PictureData -PictureStream -Save
3. 删除多余的命令: Set-user
Remove-ManagementRoleEntry -Identity “MyPhotoInformationSet-User”
4. 再次确认”Set-User”命令已经从新的角色中删除:
(Get-ManagementRole MyPhotoInformation).roleentries
5. 把新的角色指派到默认策略,确保每个用户都有权限:
New-ManagementRoleAssignment -Name “MyPhotoInformation Add to Default Role Assignment Policy” -Role MyPhotoInformation -Policy “Default Role Assignment Policy”
6. 登录ECP,在Default Role Assignment Policy中可以看到自定义的MyPhotoInformation;登录OWA,点击帐户下面的“更改”即可上传更改帐户头像,该头像是上传到AD中,会更改所有从AD中读取头像数据的应用。
声明: 此文观点不代表本站立场;转载须要保留原文链接;版权疑问请联系我们。