簡體   English   中英

將用戶從 SQL Server 表移動到 Active Directory

[英]Moving users from SQL Server table to Active Directory

我的 SQL Server 數據庫中有一個表,用於存儲有權訪問我的應用程序的用戶。 現在,我想將這些用戶移動到 AD 組。

一種選擇是創建 hangfire 作業並使用 LDAP 查詢將這些用戶移動到 AD 組。 但是,添加新用戶的實例非常少。

有沒有辦法僅通過 SQL 將新創建的用戶移動到 AD 組? 我試圖找到一種不使用 hangfire 工作的方法。 這甚至可能嗎?

不確定 hangfire 工作,但 SQL 不是滿足您要求的好選擇。 由於 SQL 僅適用於 RDBMS 查詢,因此將用戶從 SQL 服務器數據庫轉移到 Azure AD 聽起來不太現實。 我建議您使用標准方法。

可以使用 PowerShell 將成員添加到 Azure AD 組。

Add-AzureADGroupMember 
   -ObjectId <String> 
   -RefObjectId <String> 
   [-InformationAction <ActionPreference>] 
   [-InformationVariable <String>] 
   [<CommonParameters>]

參考: https : //docs.microsoft.com/en-us/powershell/module/azuread/add-azureadgroupmember?view=azureadps-2.0

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM