パスワードリセット(Graph)
注意クラウドユーザーのPW初期化
Invoke-MgGraphRequest -Method POST -Uri "/v1.0/users/<upn>/authentication/methods/<id>/resetPassword" -Body @{newPassword='<temp>'}
Graph経由でパスワードを初期化。ヘルプデスク最頻の依頼だが、本人確認の厳格化とセットでなければ攻撃の入口になる点を肝に銘じる。
実行例
Get-MgUserAuthenticationMethod -UserId [email protected]リセット対象methodのIDを確認
書式
Invoke-MgGraphRequest POST /users/{id}/authentication/methods/{id}/resetPassword (要UserAuthenticationMethod.ReadWrite.All)
実行前の注意
本人確認手順を必ず経る。仮PWは初回変更必須に。
関連コマンド
- Get-MgUserAuthenticationMethodMFA認証方法の確認
- サインインのブロックアカウントの即時停止