简体   繁体   English

用于从 Azure Active Directory 检索用户信息的 VBS 脚本

[英]VBS script to retrieve user information from Azure Active Directory

This may not even be possible without powershell (or Azure Powershell), but can I use a script to retrieve user information from AZURE active directory on a Windows 10 computer?如果没有 powershell(或 Azure Powershell),这甚至可能无法实现,但是我可以使用脚本从 Windows 10 计算机上的 AZURE 活动目录中检索用户信息吗? Since the user has already provided credentials and the user name has been pulled down from Azure, is there any other information pulled down that I can reference as a system object (for eg).由于用户已经提供了凭据并且用户名已从 Azure 下拉,是否还有其他任何下拉信息可以作为系统对象引用(例如)。 Example of code to show user name:显示用户名的代码示例:

Set objSysInfo = CreateObject("ADSystemInfo") Set objSysInfo = CreateObject("ADSystemInfo")

wScript.Echo objSysInfo.UserName wScript.Echo objSysInfo.UserName

I want to see other information such as users department(ie .department , so that I can map drives by identifying the users department rather than using the user name).我想查看其他信息,例如用户部门(即 .department ,以便我可以通过标识用户部门而不是使用用户名来映射驱动器)。

If I can't use vbs then is this possible with Azure powershell without re-entering user credentials and/or re-verifying user credentials?如果我不能使用 vbs,那么在不重新输入用户凭据和/或重新验证用户凭据的情况下,Azure powershell 是否可以实现?

It's possible with Azure PowerShell commandlets:可以使用 Azure PowerShell commandlet:

Connect-MsolService -CurrentCredential
Get-MsolUser -UserPrincipalName username@domain

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在 ado 管道上运行的单个脚本中从 Azure Active Directory 和 On-Prem Active Directory 中删除用户帐户 - Removing User Account From both Azure Active Directory and On-Prem Active Directory in a single Script run on ado pipelines 提取Active Directory用户信息 - Pull Active Directory user information Azure Active Directory 用户报告 - Azure Active Directory User report Azure Active Directory - 用户导出属性 - Azure Active Directory - User export properties Powershell Active Directory 脚本导出 csv 与特定信息/属性 - Powershell Active Directory script to export csv with specific information/attributes Powershell:如何从 Azure Active Directory 用户获取名称 (Get-AzADUser) - Powershell: How do I get the name from Azure Active Directory user (Get-AzADUser) Powershell 图形用户界面。 从动态列表框中选择一个项目,随后从 Active Directory 中卸载用户信息 - Powershell GUI. Selecting an item from a dynamic ListBox with subsequent unloading of user information from Active Directory Ask a question 尝试使用PowerShell脚本从Active Directory中的所有组中删除用户 - Trying to remove user from all groups in an Active Directory using PowerShell script 从Active Directory用户对象检索RDN - Retrieving an RDN from an Active Directory User Object 从 Active Directory 获取 AD 用户属性 - Get AD user properties from Active Directory
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM