Commands › Exchange Online

Set-ImapSettings

Exchange Online ExchangeOnlineManagement Set-*

Modify the settings of the Microsoft Exchange IMAP4 service on Exchange servers. This service exists on Exchange servers that have the Client Access server role installed, and is used by IMAP4 clients to connect to Exchange.

Quick start script

# Set-ImapSettings — quick start (serv365.ai)
# 1. Connect (app-only shown; interactive: omit the certificate parameters)
Connect-ExchangeOnline -CertificateThumbprint $thumb -AppId $appId -Organization $org

# 2. Capture the current state first — you cannot roll back what you never recorded
$before = Get-ImapSettings
$before | Format-List

# 3. Make the change (dry run first)
Set-ImapSettings  -WhatIf
Set-ImapSettings

# 4. Verify and diff
$after = Get-ImapSettings
Compare-Object ($before | Out-String) ($after | Out-String)

Syntax

Set-ImapSettings [-AuthenticatedConnectionTimeout <EnhancedTimeSpan>]
 [-Banner <String>]
 [-CalendarItemRetrievalOption <CalendarItemRetrievalOptions>]
 [-Confirm]
 [-DomainController <Fqdn>]
 [-EnableExactRFC822Size <Boolean>]
 [-EnableGSSAPIAndNTLMAuth <Boolean>]
 [-EnforceCertificateErrors <Boolean>]
 [-ExtendedProtectionPolicy <ExtendedProtectionTokenCheckingMode>]
 [-ExternalConnectionSettings <MultiValuedProperty>]
 [-InternalConnectionSettings <MultiValuedProperty>]
 [-LogFileLocation <String>]
 [-LogFileRollOverSettings <LogFileRollOver>]
 [-LoginType <LoginOptions>]
 [-LogPerFileSizeQuota <Unlimited>]
 [-MaxCommandSize <Int32>]
 [-MaxConnectionFromSingleIP <Int32>]
 [-MaxConnections <Int32>]
 [-MaxConnectionsPerUser <Int32>]
 [-MessageRetrievalMimeFormat <MimeTextFormat>]
 [-OwaServerUrl <Uri>]
 [-PreAuthenticatedConnectionTimeout <EnhancedTimeSpan>]
 [-ProtocolLogEnabled <Boolean>]
 [-ProxyTargetPort <Int32>]
 [-Server <ServerIdParameter>]
 [-ShowHiddenFoldersEnabled <Boolean>]
 [-SSLBindings <MultiValuedProperty>]
 [-SuppressReadReceipt <Boolean>]
 [-UnencryptedOrTLSBindings <MultiValuedProperty>]
 [-WhatIf]
 [-X509CertificateName <String>]
 [<CommonParameters>]

Parameters (31)

ParameterTypeRequiredWhat it controls
-AuthenticatedConnectionTimeout EnhancedTimeSpan The AuthenticatedConnectionTimeout parameter specifies the period of time to wait before closing an idle authenticated connection.
-Banner String The Banner parameter specifies the text string that's displayed to connecting IMAP4 clients. The default value is: The Microsoft Exchange IMAP4 service is ready.
-CalendarItemRetrievalOption CalendarItemRetrievalOptions The CalendarItemRetrievalOption parameter specifies how calendar items are presented to IMAP4 clients. Valid values are:
-Confirm SwitchParameter The Confirm switch specifies whether to show or hide the confirmation prompt. How this switch affects the cmdlet depends on whether the cmdlet requires confirmation before proceeding.
-DomainController Fqdn The DomainController parameter specifies the domain controller that's used by this cmdlet to read data from or write data to Active Directory. You identify the domain controller by its fully qualified domain name...
-EnableExactRFC822Size Boolean The EnableExactRFC822Size parameter specifies how message sizes are presented to IMAP4 clients. Valid values are:
-EnableGSSAPIAndNTLMAuth Boolean The EnableGSSAPIAndNTLMAuth parameter specifies whether connections can use Integrated Windows authentication (NTLM) using the Generic Security Services application programming interface (GSSAPI). This setting...
-EnforceCertificateErrors Boolean The EnforceCertificateErrors parameter specifies whether to enforce Transport Layer Security (TLS) certificate validation failures. Valid values are:
-ExtendedProtectionPolicy ExtendedProtectionTokenCheckingMode The ExtendedProtectionPolicy parameter specifies how Extended Protection for Authentication is used. Valid values are:
-ExternalConnectionSettings MultiValuedProperty The ExternalConnectionSettings parameter specifies the host name, port, and encryption method that's used by external IMAP4 clients (IMAP4 connections from outside your corporate network).
-InternalConnectionSettings MultiValuedProperty The InternalConnectionSettings parameter specifies the host name, port, and encryption method that's used by internal IMAP4 clients (IMAP4 connections from inside your corporate network). This setting is also used...
-LogFileLocation String The LogFileLocation parameter specifies the location for the IMAP4 protocol log files. The default location is %ExchangeInstallPath%Logging\\Imap4.
-LogFileRollOverSettings LogFileRollOver The LogFileRollOverSettings parameter specifies how frequently IMAP4 protocol logging creates a new log file. Valid values are:
-LoginType LoginOptions The LoginType parameter specifies the authentication method for IMAP4 connections. Valid values are:
-LogPerFileSizeQuota Unlimited The LogPerFileSizeQuota parameter specifies the maximum size of a IMAP4 protocol log file.
-MaxCommandSize Int32 The MaxCommandSize parameter specifies the maximum size in bytes of a single IMAP4 command. Valid values are from 1024 through 16384. The default value is 10240.
-MaxConnectionFromSingleIP Int32 The MaxConnectionFromSingleIP parameter specifies the maximum number of IMAP4 connections that are accepted by the Exchange server from a single IP address. Valid values are from 1 through 2147483647. The default...
-MaxConnections Int32 The MaxConnections parameter specifies the maximum number of IMAP4 connections that are accepted by the Exchange server. Valid values are from 1 through 2147483647. The default value is 2147483647.
-MaxConnectionsPerUser Int32 The MaxConnectionsPerUser parameter specifies the maximum number of IMAP4 connections that are allowed for each user. Valid values are from 1 through 2147483647. The default value is 16.
-MessageRetrievalMimeFormat MimeTextFormat The MessageRetrievalMimeFormat parameter specifies the MIME encoding of messages. Valid values are:
-OwaServerUrl Uri The OwaServerUrl parameter specifies the URL that's used to retrieve calendar information for instances of custom Outlook on the web calendar items.
-PreAuthenticatedConnectionTimeout EnhancedTimeSpan The PreAuthenticatedConnectionTimeout parameter specifies the period of time to wait before closing an idle IMAP4 connection that isn't authenticated.
-ProtocolLogEnabled Boolean The ProtocolLogEnabled parameter specifies whether to enable protocol logging for IMAP4. Valid values are:
-ProxyTargetPort Int32 The ProxyTargetPort parameter specifies the port on the Microsoft Exchange IMAP4 Backend service that listens for client connections that are proxied from the Microsoft Exchange IMAP4 service. The default value is 1993.
-Server ServerIdParameter The Server parameter specifies the Exchange server where you want to run this command. You can use any value that uniquely identifies the server. For example:
-ShowHiddenFoldersEnabled Boolean The ShowHiddenFoldersEnabled parameter specifies whether hidden mailbox folders are visible. Valid values are:
-SSLBindings MultiValuedProperty The SSLBindings parameter specifies the IP address and TCP port that's used for IMAP4 connection that's always encrypted by SSL/TLS. This parameter uses the syntax `IPv4OrIPv6Address:Port`.
-SuppressReadReceipt Boolean The SuppressReadReceipt parameter specifies whether to stop duplicate read receipts from being sent to IMAP4 clients that have the Send read receipts for messages I send setting configured in their IMAP4 email...
-UnencryptedOrTLSBindings MultiValuedProperty The UnencryptedOrTLSBindings parameter specifies the IP address and TCP port that's used for unencrypted IMAP4 connections, or IMAP4 connections that are encrypted by using opportunistic TLS (STARTTLS) after the...
-WhatIf SwitchParameter The WhatIf switch shows what the command does without making any changes. You don't need to specify a value with this switch.
-X509CertificateName String The X509CertificateName parameter specifies the certificate that's used for encrypting IMAP4 client connections.

Reference facts derived from Microsoft documentation, © Microsoft, licensed CC BY 4.0; restructured with original guidance by serv365.ai.