You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: exchange/docs-conceptual/app-only-auth-powershell-v2.md
+8-7Lines changed: 8 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,7 @@ author: chrisda
5
5
manager: dansimp
6
6
ms.date:
7
7
ms.audience: Admin
8
+
audience: Admin
8
9
ms.topic: article
9
10
ms.service: exchange-online
10
11
ms.reviewer: navgupta
@@ -53,15 +54,15 @@ The following examples show how to use the Exchange Online PowerShell V2 module
53
54
>
54
55
> - In the **Connect-ExchangeOnline** commands, be sure to use an `.onmicrosoft.com` ___domain in the _Organization_ parameter value. Otherwise, you might encounter cryptic permission issues when you run commands in the app context.
55
56
>
56
-
> - App-only authentication does not support delegation. Unattended scripting in delegation scenarios is supported with the Secure App Model. For more information, go [here](https://docs.microsoft.com/powershell/partnercenter/multi-factor-auth#exchange).
57
+
> - App-only authentication does not support delegation. Unattended scripting in delegation scenarios is supported with the Secure App Model. For more information, go [here](/powershell/partnercenter/multi-factor-auth#exchange).
57
58
58
59
## How does it work?
59
60
60
61
The EXO V2 module uses the Active Directory Authentication Library to fetch an app-only token using the application Id, tenant Id (organization), and certificate thumbprint. The application object provisioned inside Azure AD has a Directory Role assigned to it, which is returned in the access token. Exchange Online configures the session RBAC using the directory role information that's available in the token.
61
62
62
63
## Set up app-only authentication
63
64
64
-
An initial onboarding is required for authentication using application objects. Application and service principal are used interchangeably, but an application is like a class object while a service principal is like an instance of the class. You can learn more about this at [Application and service principal objects in Azure Active Directory](https://docs.microsoft.com/azure/active-directory/develop/app-objects-and-service-principals).
65
+
An initial onboarding is required for authentication using application objects. Application and service principal are used interchangeably, but an application is like a class object while a service principal is like an instance of the class. You can learn more about this at [Application and service principal objects in Azure Active Directory](/azure/active-directory/develop/app-objects-and-service-principals).
65
66
66
67
For a detailed visual flow about creating applications in Azure AD, see <https://aka.ms/azuread-app>.
67
68
@@ -100,7 +101,7 @@ For a detailed visual flow about creating applications in Azure AD, see <https:/
100
101
101
102
## Step 1: Register the application in Azure AD
102
103
103
-
**Note**: If you encounter problems, check the [required permissions](https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal#required-permissions) to verify that your account can create the identity.
104
+
**Note**: If you encounter problems, check the [required permissions](/azure/active-directory/develop/howto-create-service-principal-portal#required-permissions) to verify that your account can create the identity.
104
105
105
106
1. Open the Azure AD portal at <https://portal.azure.com/>.
106
107
@@ -124,7 +125,7 @@ For a detailed visual flow about creating applications in Azure AD, see <https:/
124
125
125
126
- **Redirect URI (optional)**: In the first box, verify that **Web** is selected. In the second box, enter the URI where the access token is sent.
126
127
127
-
Note that you can't create credentials for [native applications](https://docs.microsoft.com/azure/active-directory/manage-apps/application-proxy-configure-native-client-application), because you can't use that type for automated applications.
128
+
Note that you can't create credentials for [native applications](/azure/active-directory/manage-apps/application-proxy-configure-native-client-application), because you can't use that type for automated applications.
128
129
129
130

130
131
@@ -185,14 +186,14 @@ For a detailed visual flow about creating applications in Azure AD, see <https:/
185
186
186
187
Create a self-signed x.509 certificate using one of the following methods:
187
188
188
-
- (Recommended) Use the [New-SelfSignedCertificate](https://docs.microsoft.com/powershell/module/pkiclient/new-selfsignedcertificate), [Export-Certificate](https://docs.microsoft.com/powershell/module/pkiclient/export-certificate) and [Export-PfxCertificate](https://docs.microsoft.com/powershell/module/pkiclient/export-pfxcertificate) cmdlets in an elevated (run as administrator) Windows PowerShell session to request a self-signed certificate and export it to `.cer` and `.pfx` (SHA1 by default).
189
+
- (Recommended) Use the [New-SelfSignedCertificate](/powershell/module/pkiclient/new-selfsignedcertificate), [Export-Certificate](/powershell/module/pkiclient/export-certificate) and [Export-PfxCertificate](/powershell/module/pkiclient/export-pfxcertificate) cmdlets in an elevated (run as administrator) Windows PowerShell session to request a self-signed certificate and export it to `.cer` and `.pfx` (SHA1 by default). For example:
@@ -250,7 +251,7 @@ Azure AD has more than 50 admin roles available. For app-only authentication in
250
251
- Exchange administrator
251
252
- Global Reader
252
253
253
-
For general instructions about assigning roles in Azure AD, see [View and assign administrator roles in Azure Active Directory](https://docs.microsoft.com/azure/active-directory/roles/manage-roles-portal).
254
+
For general instructions about assigning roles in Azure AD, see [View and assign administrator roles in Azure Active Directory](/azure/active-directory/roles/manage-roles-portal).
254
255
255
256
1. On the Azure AD portal at <https://portal.azure.com/>, under **Manage Azure Active Directory**, click **View**.
Copy file name to clipboardExpand all lines: exchange/docs-conceptual/basic-auth-connect-to-eop-powershell.md
+10-9Lines changed: 10 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,7 @@ author: chrisda
5
5
manager: dansimp
6
6
ms.date:
7
7
ms.audience: Admin
8
+
audience: Admin
8
9
ms.topic: article
9
10
ms.service: exchange-powershell
10
11
localization_priority: Normal
@@ -32,7 +33,7 @@ The following introductory video shows you how to connect to and use Exchange On
32
33
33
34
- **The procedures in this article are only for EOP organizations that don't have Exchange Online mailboxes** (for example, you have a standalone EOP subscription that protects your on-premises email environment). If you have a Microsoft 365 subscription includes Exchange Online mailboxes, you can't connect to Exchange Online Protection PowerShell. The same features are available in [Exchange Online PowerShell](exchange-online-powershell.md).
34
35
35
-
- After you connect, the cmdlets and parameters that you have or don't have access to is controlled by role-based access control (RBAC). For more information, see [Permissions in standalone EOP](https://docs.microsoft.com/microsoft-365/security/office-365-security/feature-permissions-in-eop).
36
+
- After you connect, the cmdlets and parameters that you have or don't have access to is controlled by role-based access control (RBAC). For more information, see [Permissions in standalone EOP](/microsoft-365/security/office-365-security/feature-permissions-in-eop).
36
37
37
38
- You can use the following versions of Windows:
38
39
@@ -44,7 +45,7 @@ The following introductory video shows you how to connect to and use Exchange On
44
45
- Windows 7 Service Pack 1 (SP1)<sup>\*</sup>
45
46
- Windows Server 2008 R2 SP1<sup>\*</sup>
46
47
47
-
<sup>\*</sup> This version of Windows has reached end of support, and is now supported only in Azure virtual machines. To use this version of Windows, you need to install the Microsoft .NET Framework 4.5 or later and then an updated version of the Windows Management Framework: 3.0, 4.0, or 5.1 (only one). For more information, see [Install the .NET Framework](https://docs.microsoft.com/dotnet/framework/install/on-windows-7), [Windows Management Framework 3.0](https://aka.ms/wmf3download), [Windows Management Framework 4.0](https://aka.ms/wmf4download), and [Windows Management Framework 5.1](https://aka.ms/wmf5download).
48
+
<sup>\*</sup> This version of Windows has reached end of support, and is now supported only in Azure virtual machines. To use this version of Windows, you need to install the Microsoft .NET Framework 4.5 or later and then an updated version of the Windows Management Framework: 3.0, 4.0, or 5.1 (only one). For more information, see [Install the .NET Framework](/dotnet/framework/install/on-windows-7), [Windows Management Framework 3.0](https://aka.ms/wmf3download), [Windows Management Framework 4.0](https://aka.ms/wmf4download), and [Windows Management Framework 5.1](https://aka.ms/wmf5download).
48
49
49
50
- Windows PowerShell needs to be configured to run scripts, and by default, it isn't. You'll get the following error when you try to connect:
50
51
@@ -56,7 +57,7 @@ The following introductory video shows you how to connect to and use Exchange On
56
57
Set-ExecutionPolicy RemoteSigned
57
58
```
58
59
59
-
For more information about execution policies, see [About Execution Policies](https://docs.microsoft.com/powershell/module/microsoft.powershell.core/about/about_execution_policies).
60
+
For more information about execution policies, see [About Execution Policies](/powershell/module/microsoft.powershell.core/about/about_execution_policies).
60
61
61
62
- WinRM needs to allow Basic authentication (it's enabled by default). We don't send the username and password combination, but the Basic authentication header is required to send the session's OAuth token, since the client-side WinRM implementation has no support for OAuth.
62
63
@@ -130,7 +131,7 @@ If you receive errors, check the following requirements:
130
131
131
132
- TCP port 80 traffic needs to be open between your local computer and Microsoft 365. It's probably open, but it's something to consider if your organization has a restrictive Internet access policy.
132
133
133
-
- The account you use to connect to Exchange Online Protection PowerShell must be represented as a [mail user in EOP](https://docs.microsoft.com/microsoft-365/security/office-365-security/manage-mail-users-in-eop) (created manually or by directory synchronization). If the account is not visible in the Exchange admin center (EAC) as a mail user at **Recipients** \> **Contacts**, you'll receive the following error when you try to connect:
134
+
- The account you use to connect to Exchange Online Protection PowerShell must be represented as a [mail user in EOP](/microsoft-365/security/office-365-security/manage-mail-users-in-eop) (created manually or by directory synchronization). If the account is not visible in the Exchange admin center (EAC) as a mail user at **Recipients** \> **Contacts**, you'll receive the following error when you try to connect:
134
135
135
136
> Import-PSSession : Running the Get-Command command in a remote session reported the following error: Processing data for a remote command failed with the following error message: The request for the Windows Remote Shell with ShellId <GUID> failed because the shell was not found on the server. Possible causes are: the specified ShellId is incorrect or the shell no longer exists on the server. Provide the correct ShellId or create a new shell and retry the operation.
136
137
@@ -144,8 +145,8 @@ If you receive errors, check the following requirements:
144
145
145
146
The cmdlets that you use in this article are Windows PowerShell cmdlets. For more information about these cmdlets, see the following articles.
Copy file name to clipboardExpand all lines: exchange/docs-conceptual/basic-auth-connect-to-exo-powershell.md
+11-10Lines changed: 11 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,7 @@ author: chrisda
5
5
manager: dansimp
6
6
ms.date:
7
7
ms.audience: Admin
8
+
audience: Admin
8
9
ms.topic: article
9
10
ms.service: exchange-powershell
10
11
localization_priority: Priority
@@ -33,7 +34,7 @@ The following introductory video shows you how to connect to and use Exchange On
33
34
34
35
- Estimated time to complete: 5 minutes
35
36
36
-
- After you connect, the cmdlets and parameters that you have or don't have access to is controlled by role-based access control (RBAC). For more information, see [Permissions in Exchange Online](https://docs.microsoft.com/exchange/permissions-exo/permissions-exo).
37
+
- After you connect, the cmdlets and parameters that you have or don't have access to is controlled by role-based access control (RBAC). For more information, see [Permissions in Exchange Online](/exchange/permissions-exo/permissions-exo).
37
38
38
39
- If your on-premises Exchange organization has Exchange Enterprise CAL with Services licenses, you can use the instructions in this article to connect to your EOP organization.
39
40
@@ -47,7 +48,7 @@ The following introductory video shows you how to connect to and use Exchange On
47
48
- Windows 7 Service Pack 1 (SP1)<sup>*</sup>
48
49
- Windows Server 2008 R2 SP1<sup>*</sup>
49
50
50
-
<sup>\*</sup> This version of Windows has reached end of support, and is now supported only in Azure virtual machines. To use this version of Windows, you need to install the Microsoft .NET Framework 4.5 or later and then an updated version of the Windows Management Framework: 3.0, 4.0, or 5.1 (only one). For more information, see [Install the .NET Framework](https://docs.microsoft.com/dotnet/framework/install/on-windows-7), [Windows Management Framework 3.0](https://aka.ms/wmf3download), [Windows Management Framework 4.0](https://aka.ms/wmf4download), and [Windows Management Framework 5.1](https://aka.ms/wmf5download).
51
+
<sup>\*</sup> This version of Windows has reached end of support, and is now supported only in Azure virtual machines. To use this version of Windows, you need to install the Microsoft .NET Framework 4.5 or later and then an updated version of the Windows Management Framework: 3.0, 4.0, or 5.1 (only one). For more information, see [Install the .NET Framework](/dotnet/framework/install/on-windows-7), [Windows Management Framework 3.0](https://aka.ms/wmf3download), [Windows Management Framework 4.0](https://aka.ms/wmf4download), and [Windows Management Framework 5.1](https://aka.ms/wmf5download).
51
52
52
53
- Windows PowerShell needs to be configured to run scripts, and by default, it isn't. You'll get the following error when you try to connect:
53
54
@@ -59,7 +60,7 @@ The following introductory video shows you how to connect to and use Exchange On
59
60
Set-ExecutionPolicy RemoteSigned
60
61
```
61
62
62
-
For more information about execution policies, see [About Execution Policies](https://docs.microsoft.com/powershell/module/microsoft.powershell.core/about/about_execution_policies).
63
+
For more information about execution policies, see [About Execution Policies](/powershell/module/microsoft.powershell.core/about/about_execution_policies).
63
64
64
65
- WinRM needs to allow Basic authentication (it's enabled by default). We don't send the username and password combination, but the Basic authentication header is required to send the session's OAuth token, since the client-side WinRM implementation has no support for OAuth.
65
66
@@ -113,7 +114,7 @@ The following introductory video shows you how to connect to and use Exchange On
113
114
114
115
Then, add the following parameter and value to the end of the $Session = ... command: `-SessionOption $ProxyOptions`.
115
116
116
-
For more information, see [New-PSSessionOption](https://docs.microsoft.com/powershell/module/microsoft.powershell.core/new-pssessionoption).
117
+
For more information, see [New-PSSessionOption](/powershell/module/microsoft.powershell.core/new-pssessionoption).
117
118
118
119
3. Run the following command:
119
120
@@ -148,10 +149,10 @@ If you receive errors, check the following requirements:
148
149
149
150
The cmdlets that you use in this article are Windows PowerShell cmdlets. For more information about these cmdlets, see the following articles.
0 commit comments