Skip to content

Commit 1cb8e5b

Browse files
authored
Merge pull request #6 from MicrosoftDocs/master
Merge latest to own fork
2 parents a53fa73 + 51e47a5 commit 1cb8e5b

File tree

1,473 files changed

+9495
-2261
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,473 files changed

+9495
-2261
lines changed

.openpublishing.publish.config.json

Lines changed: 40 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,9 @@
8888
]
8989
},
9090
{
91-
"docset_name": "teams-ps",
92-
"build_source_folder": "teams",
93-
"build_output_subfolder": "teams-ps",
91+
"docset_name": "staffhub-ps",
92+
"build_source_folder": "staffhub",
93+
"build_output_subfolder": "staffhub-ps",
9494
"locale": "en-us",
9595
"monikers": [],
9696
"moniker_ranges": [],
@@ -117,9 +117,38 @@
117117
]
118118
},
119119
{
120-
"docset_name": "staffhub-ps",
121-
"build_source_folder": "staffhub",
122-
"build_output_subfolder": "staffhub-ps",
120+
"docset_name": "exchange-ps",
121+
"build_source_folder": "exchange",
122+
"build_output_subfolder": "exchange-ps",
123+
"locale": "en-us",
124+
"monikers": [],
125+
"moniker_ranges": [],
126+
"open_to_public_contributors": true,
127+
"type_mapping": {
128+
"Conceptual": "Content",
129+
"ManagedReference": "Content",
130+
"RestApi": "Content",
131+
"AzurePsModulePage": "Content"
132+
},
133+
"build_entry_point": "docs",
134+
"template_folder": "_themes",
135+
"version": 0,
136+
"customized_template_paths": [
137+
"_dependentPackages/azurecli.plugins/azurecli"
138+
],
139+
"customized_tasks": {
140+
"docset_prebuild": [
141+
"_dependentPackages/CommonPlugins/tools/PowerShellReference.ps1"
142+
]
143+
},
144+
"monikerPath": [
145+
"mapping/monikerMapping.json"
146+
]
147+
},
148+
{
149+
"docset_name": "teams-ps",
150+
"build_source_folder": "teams",
151+
"build_output_subfolder": "teams-ps",
123152
"locale": "en-us",
124153
"monikers": [],
125154
"moniker_ranges": [],
@@ -173,11 +202,11 @@
173202
]
174203
},
175204
"need_generate_pdf_url_template": true,
176-
"Targets": {
177-
"Pdf": {
178-
"template_folder": "_themes.pdf"
179-
}
180-
},
205+
"targets": {
206+
"Pdf": {
207+
"template_folder": "_themes.pdf"
208+
}
209+
},
181210
"need_generate_pdf": false,
182211
"need_generate_intellisense": false,
183212
"dependent_packages": [

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ When you contribute your work will go directly into the Microsoft Office product
2525
**Note** that since you are likely not a maintainer of the Git repository GitHub will automatically 'Fork' the project into your personal GitHub account. A fork is just an exact copy of the repository in your own account so that you have total access to make edits. You are now 'editing' a copy of the project in your own GitHub account. You can always find it again by looking at your GitHub Repositories in your GitHub Profile (drop-down from your name in top right).
2626
![Image of Automatic Fork message on Github](images/auto_fork.png)
2727

28-
5. You can click the Preview changes link to see what the changes will look like.
28+
5. You can click the Preview changes link to see what the changes will look like.
2929

3030
**IMPORTANT** The layout of headings and subheadings must follow a very specific schema that is required for PowerShell Get-Help.
3131
Any deviation will throw errors in the Pull Request. The schema can be found here: https://github.com/PowerShell/platyPS/blob/master/platyPS.schema.md

exchange/docfx.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
"**/*.png",
4040
"**/*.jpg"
4141
],
42+
"version": "exchange-ps",
4243
"exclude": [
4344
"**/obj/**",
4445
"**/includes/**"
@@ -59,10 +60,13 @@
5960
"ms.date" : "09/25/2017",
6061
"ms.topic" : "reference",
6162
"ms.service" : "exchange-powershell",
62-
"ms.devlang" : "powershell"
63+
"ms.devlang" : "powershell",
64+
"feedback_system": "GitHub",
65+
"feedback_github_repo": "MicrosoftDocs/office-docs-powershell",
66+
"feedback_product_url": "https://github.com/MicrosoftDocs/office-docs-powershell/issues"
6367
},
6468
"fileMetadata": {},
6569
"template": [],
6670
"dest": "exchange-ps"
6771
}
68-
}
72+
}
Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
---
2+
title: "Connect to Exchange Online Protection PowerShell"
3+
ms.author: chrisda
4+
author: chrisda
5+
manager: serdars
6+
ms.date: 7/10/2017
7+
ms.audience: Admin
8+
ms.topic: article
9+
ms.service: eop
10+
localization_priority: Normal
11+
ms.assetid: 054e0fd7-d465-4572-93f8-a00a9136e4d1
12+
description: "Use remote PowerShell to connect to an Exchange Online Protection organization"
13+
---
14+
15+
# Connect to Exchange Online Protection PowerShell
16+
17+
Exchange Online Protection PowerShell allows you to manage your Exchange Online Protection settings from the command line. You use Windows PowerShell on your local computer to create a remote PowerShell session to Exchange Online Protection. It's a simple three-step process where you enter your Office 365 credentials, provide the required connection settings, and then import the Exchange Online Protection cmdlets into your local Windows PowerShell session so that you can use them.
18+
19+
## What do you need to know before you begin?
20+
21+
- Estimated time to complete: 5 minutes
22+
23+
- You can use the following versions of Windows:
24+
25+
- Windows 10
26+
27+
- Windows 8.1
28+
29+
- Windows Server 2016
30+
31+
- Windows Server 2012 or Windows Server 2012 R2
32+
33+
- Windows 7 Service Pack 1 (SP1)\*
34+
35+
- Windows Server 2008 R2 SP1\*
36+
37+
\* You need to install the Microsoft.NET Framework 4.5 or later and then either the Windows Management Framework 3.0 or the Windows Management Framework 4.0. For more information, see [Installing the .NET Framework](https://go.microsoft.com/fwlink/p/?LinkId=257868) and [Windows Management Framework 3.0](https://go.microsoft.com/fwlink/p/?LinkId=272757) or [Windows Management Framework 4.0](https://go.microsoft.com/fwlink/p/?LinkId=391344).
38+
39+
- Windows PowerShell needs to be configured to run scripts, and by default, it isn't. You get the following error when you try to connect:
40+
41+
`Files cannot be loaded because running scripts is disabled on this system. Provide a valid certificate with which to sign the files.`
42+
43+
To enable Windows PowerShell to run signed scripts, run the following command in an elevated Windows PowerShell window (a Windows PowerShell window you open by selecting **Run as administrator**):
44+
45+
```
46+
Set-ExecutionPolicy RemoteSigned
47+
```
48+
49+
You need to configure this setting only once on your computer, not every time you connect.
50+
51+
> [!TIP]
52+
> Having problems? Ask for help in the Exchange forums. Visit the forums at: [Exchange Server](https://go.microsoft.com/fwlink/p/?linkId=60612), [Exchange Online](https://go.microsoft.com/fwlink/p/?linkId=267542), or [Exchange Online Protection](https://go.microsoft.com/fwlink/p/?linkId=285351).
53+
54+
## Connect to Exchange Online Protection
55+
56+
1. On your local computer, open Windows PowerShell and run the following command.
57+
58+
```
59+
$UserCredential = Get-Credential
60+
```
61+
62+
In the **Windows PowerShell Credential Request** dialog box, type your work or school account and password, and then click **OK**.
63+
64+
2. Run the following command.
65+
66+
```
67+
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.protection.outlook.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
68+
```
69+
70+
**Notes**:
71+
72+
- For Office 365 Germany, use the _ConnectionUri_ value: `https://ps.protection.outlook.de/powershell-liveid/`
73+
74+
- For Exchange Online Protection subscriptions that are Exchange Enterprise CAL with Services (includes data loss prevention (DLP) and reporting using web services), use the _ConnectionUri_ value: `https://outlook.office365.com/powershell-liveid/`
75+
76+
3. Run the following command.
77+
78+
```
79+
Import-PSSession $Session
80+
```
81+
82+
[!NOTE]
83+
Be sure to disconnect the remote PowerShell session when you're finished. If you close the Windows PowerShell window without disconnecting the session, you could use up all the remote PowerShell sessions available to you, and you'll need to wait for the sessions to expire. To disconnect the remote PowerShell session, run the following command:
84+
85+
```
86+
Remove-PSSession $Session
87+
```
88+
89+
## How do you know this worked?
90+
91+
After Step 3, the Exchange Online Protection cmdlets are imported into your local Windows PowerShell session and tracked by a progress bar. If you don't receive any errors, you connected successfully. A quick test is to run an Exchange Online Protection cmdlet, for example, **Get-TransportRule**, and see the results.
92+
93+
If you receive errors, check the following requirements:
94+
95+
- A common problem is an incorrect password. Run the three steps again and pay close attention to the user name and password you enter in Step 1.
96+
97+
- To help prevent denial-of-service (DoS) attacks, you're limited to three open remote PowerShell connections to your Exchange Online Protection organization.
98+
99+
- TCP port 80 traffic needs to be open between your local computer and Office 365. It's probably open, but it's something to consider if your organization has a restrictive Internet access policy.
100+
101+
## See also
102+
103+
The cmdlets that you use in this topic are Windows PowerShell cmdlets. For more information about these cmdlets, see the following topics.
104+
105+
- [Get-Credential](https://go.microsoft.com/fwlink/p/?LinkId=389618)
106+
107+
- [New-PSSession](https://go.microsoft.com/fwlink/p/?LinkId=389621)
108+
109+
- [Import-PSSession](https://go.microsoft.com/fwlink/p/?LinkId=389619)
110+
111+
- [Remove-PSSession](https://go.microsoft.com/fwlink/p/?LinkId=389620)
112+
113+
- [Set-ExecutionPolicy](https://go.microsoft.com/fwlink/p/?LinkId=389623)
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
---
2+
title: "Exchange Online Protection PowerShell"
3+
ms.author: chrisda
4+
author: chrisda
5+
manager: serdars
6+
ms.date: 2/20/2018
7+
ms.audience: Admin
8+
ms.topic: article
9+
ms.service: eop
10+
localization_priority: Normal
11+
ms.assetid: f7918a88-774a-405e-945b-bc2f5ee9f748
12+
description: "Learn about using PowerShell in Exchange Online Protection"
13+
---
14+
15+
# Exchange Online Protection PowerShell
16+
17+
Exchange Online Protection PowerShell is the administrative interface that enables you to manage your Exchange Online Protection (EOP) organization from the command line. For example, you can use Exchange Online Protection PowerShell to configure mail flow rules (also known as transport rules) and connectors. The following topics provide information about using Exchange Online Protection PowerShell:
18+
19+
- To create a remote PowerShell session to your Exchange Online Protection organization, see [Connect to Exchange Online Protection PowerShell](connect-to-exchange-online-protection-powershell.md).
20+
21+
- For a sample script that lets admins who manage multiple tenants (companies) apply configuration settings to their tenants, see [Sample script for applying EOP settings to multiple tenants](http://technet.microsoft.com/library/e87e84e1-7be0-44bf-a414-d91d60ed8817.aspx).
22+
23+
- The following introductory video shows you how to connect to and use Exchange Online Protection PowerShell.
24+
25+
**Note:** This video applies to Exchange Online and EOP organizations. When you connect to your organization, be careful to specify the correct URL (_ConnectionUri_ value). The required URL is different for Exchange Online and EOP organizations.
26+
27+
[Use Remote PowerShell in EOP](https://videoplayercdn.osi.office.net/hub/?csid=ux-cms-en-us-msoffice&uuid=9cb28006-c2cb-45b6-b72e-eeed8767dee7&AutoPlayVideo=false)
28+
29+
Loading
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,120 @@
1+
---
2+
title: "Connect to Exchange Online PowerShell"
3+
ms.author: chrisda
4+
author: chrisda
5+
manager: serdars
6+
ms.date: 7/10/2017
7+
ms.audience: Admin
8+
ms.topic: article
9+
ms.service: exchange-online
10+
localization_priority: Normal
11+
ms.custom: Strat_EX_Admin
12+
ms.assetid: c8bea338-6c1a-4bdf-8de0-7895d427ee5b
13+
description: "Learn how to use remote PowerShell to connect to Exchange Online."
14+
---
15+
16+
# Connect to Exchange Online PowerShell
17+
Exchange Online PowerShell allows you to manage your Exchange Online settings from the command line. You use Windows PowerShell on your local computer to create a remote PowerShell session to Exchange Online. It's a simple three-step process where you enter your Office 365 credentials, provide the required connection settings, and then import the Exchange Online cmdlets into your local Windows PowerShell session so that you can use them.
18+
19+
> [!IMPORTANT]
20+
> If you want to use multi-factor authentication (MFA) to connect to Exchange Online PowerShell, you need to download and use the Exchange Online Remote PowerShell Module. For more information, see [Connect to Exchange Online PowerShell using multi-factor authentication](mfa-connect-to-exchange-online-powershell.md). If you're an Exchange Online Protection (EOP) standalone customer, and you're using the service to protect on-premises mailboxes, use the connection instructions in the topic [Connect to Exchange Online Protection PowerShell](../../exchange-eop/connect-to-exchange-online-protection-powershell.md). If your EOP subscription is Exchange Enterprise CAL with Services (includes data loss prevention (DLP) and reporting using web services), the connection instructions in this topic will work for you.
21+
22+
## What do you need to know before you begin?
23+
24+
- Estimated time to complete: 5 minutes
25+
26+
- You can use the following versions of Windows:
27+
28+
- Windows 10
29+
30+
- Windows 8.1
31+
32+
- Windows Server 2016
33+
34+
- Windows Server 2012 or Windows Server 2012 R2
35+
36+
- Windows 7 Service Pack 1 (SP1)\*
37+
38+
- Windows Server 2008 R2 SP1\*
39+
40+
\* You need to install the Microsoft.NET Framework 4.5 or later and then either the Windows Management Framework 3.0 or the Windows Management Framework 4.0. For more information, see [Installing the .NET Framework](https://go.microsoft.com/fwlink/p/?LinkId=257868) and[Windows Management Framework 3.0](https://go.microsoft.com/fwlink/p/?LinkId=272757) or[Windows Management Framework 4.0](https://go.microsoft.com/fwlink/p/?LinkId=391344).
41+
42+
- Windows PowerShell needs to be configured to run scripts, and by default, it isn't. You get the following error when you try to connect:
43+
44+
`Files cannot be loaded because running scripts is disabled on this system. Provide a valid certificate with which to sign the files.`
45+
46+
To enable Windows PowerShell to run signed scripts, run the following command in an elevated Windows PowerShell window (a Windows PowerShell window you open by selecting **Run as administrator**):
47+
48+
```
49+
Set-ExecutionPolicy RemoteSigned
50+
```
51+
52+
You need to configure this setting only once on your computer, not every time you connect.
53+
54+
55+
> [!TIP]
56+
> Having problems? Ask for help in the Exchange forums. Visit the forums at: [Exchange Online](https://go.microsoft.com/fwlink/p/?linkId=267542), or [Exchange Online Protection](https://go.microsoft.com/fwlink/p/?linkId=285351).
57+
58+
## Connect to Exchange Online PowerShell
59+
60+
1. On your local computer, open Windows PowerShell and run the following command.
61+
62+
```
63+
$UserCredential = Get-Credential
64+
```
65+
In the **Windows PowerShell Credential Request** dialog box, type your work or school account and password, and then click **OK**.
66+
67+
2. Run the following command.
68+
69+
```
70+
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $UserCredential -Authentication Basic -AllowRedirection
71+
```
72+
73+
**Notes**:
74+
75+
- For Office 365 operated by 21Vianet, use the _ConnectionUri_ value: `https://partner.outlook.cn/PowerShell`
76+
77+
- For Office 365 Germany, use the _ConnectionUri_ value: `https://outlook.office.de/powershell-liveid/`
78+
79+
3. Run the following command.
80+
81+
```
82+
Import-PSSession $Session
83+
```
84+
85+
> [!NOTE]
86+
> Be sure to disconnect the remote PowerShell session when you're finished. If you close the Windows PowerShell window without disconnecting the session, you could use up all the remote PowerShell sessions available to you, and you'll need to wait for the sessions to expire. To disconnect the remote PowerShell session, run the following command.
87+
88+
```
89+
Remove-PSSession $Session
90+
```
91+
92+
## How do you know this worked?
93+
94+
After Step 3, the Exchange Online cmdlets are imported into your local Windows PowerShell session and tracked by a progress bar. If you don't receive any errors, you connected successfully. A quick test is to run an Exchange Online cmdlet, for example, **Get-Mailbox**, and see the results.
95+
96+
If you receive errors, check the following requirements:
97+
98+
- A common problem is an incorrect password. Run the three steps again and pay close attention to the user name and password you enter in Step 1.
99+
100+
- To help prevent denial-of-service (DoS) attacks, you're limited to three open remote PowerShell connections to your Exchange Online organization.
101+
102+
- The account you use to connect to Exchange Online must be enabled for remote PowerShell. For more information, see [Enable or disable access to Exchange Online PowerShell](../disable-access-to-exchange-online-powershell.md).
103+
104+
- TCP port 80 traffic needs to be open between your local computer and Office 365. It's probably open, but it's something to consider if your organization has a restrictive Internet access policy.
105+
106+
## See also
107+
108+
The cmdlets that you use in this topic are Windows PowerShell cmdlets. For more information about these cmdlets, see the following topics.
109+
110+
- [Get-Credential](https://go.microsoft.com/fwlink/p/?LinkId=389618)
111+
112+
- [New-PSSession](https://go.microsoft.com/fwlink/p/?LinkId=389621)
113+
114+
- [Import-PSSession](https://go.microsoft.com/fwlink/p/?LinkId=389619)
115+
116+
- [Remove-PSSession](https://go.microsoft.com/fwlink/p/?LinkId=389620)
117+
118+
- [Set-ExecutionPolicy](https://go.microsoft.com/fwlink/p/?LinkId=389623)
119+
120+

0 commit comments

Comments
 (0)