1
目前正致力於將舊的內部公司站點部署到Azure AD,最後的障礙是用AAD取代LDAP集成(爲此使用ActiveDirectoryClient類)。AAD缺乏權限
下面的代碼在將要取代舊的新網站,但在舊網站的失敗:
ActiveDirectoryClient adClient = General.GetADClient();
User currentUser = adClient.Users.Where(u => u.UserPrincipalName == Page.User.Identity.Name).ExecuteSingleAsync().Result as User;
...產生以下錯誤:
{"odata.error":{"code":"Authorization_RequestDenied","message":{"lang":"en","value":"Insufficient privileges to complete the operation."}}}
據我所知,這兩個網絡應用程序都具有幾乎相同的設置。 AAD應用程序註冊中顯示的應用程序也類似。
所以我的問題具體是:有沒有人知道我可能在這裏失蹤?