Close Menu
Altcoinvest
    What's Hot

    ‘Highly Sophisticated,’ AI-Powered Hackers Behind Vercel Breach: CEO

    April 20, 2026

    BIP-361 Proposal Akin to Seizing Bitcoin From Users: Expert ⋆ ZyCrypto

    April 20, 2026

    Bitcoin Pulls Back Below Key Levels As Iran Tensions Rise Again

    April 20, 2026
    Facebook X (Twitter) Instagram
    Altcoinvest
    • Bitcoin
    • Altcoins
    • Exchanges
    • Youtube
    • Crypto Wallets
    • Learn Crypto
    • bitcoinBitcoin(BTC)$75,447.00-0.26%
    • ethereumEthereum(ETH)$2,315.78-0.69%
    • tetherTether(USDT)$1.000.00%
    • rippleXRP(XRP)$1.42-0.75%
    • binancecoinBNB(BNB)$626.750.59%
    • usd-coinUSDC(USDC)$1.000.00%
    • solanaSolana(SOL)$85.26-0.60%
    • tronTRON(TRX)$0.328838-0.29%
    • Figure HelocFigure Heloc(FIGR_HELOC)$1.040.00%
    • dogecoinDogecoin(DOGE)$0.094824-0.17%
    Altcoinvest
    Home»Exchange»How to Block Soft and Hard Match in Microsoft Entra ID
    How to Block Soft and Hard Match in Microsoft Entra ID
    Exchange

    How to Block Soft and Hard Match in Microsoft Entra ID

    April 7, 2026
    Share
    Facebook Twitter LinkedIn Pinterest Email

    Microsoft recommends that all customers disable hard matching and soft matching in Microsoft Entra ID unless they need it to take over cloud-only accounts. By default, both settings are not blocked in the tenants, so you must set it yourself. In this article, you will learn how to block soft and hard match in Microsoft Entra ID.

    Before you start

    Sometimes you want to soft or hard match users, and that’s completely fine. However, this means that you need to enable soft and hard match. In other words, revert the change from this article. After that, you can proceed and soft or hard match the users. Once it’s done, you must block both soft and hard match in the tenant.

    Note: Soft and hard matching should be blocked in your Microsoft tenant for security purposes.

    Step 1. Install Microsoft Graph PowerShell

    Run Windows PowerShell as administrator and Install Microsoft Graph PowerShell.

    Install-Module Microsoft.Graph -Force

    Important: Always update to the latest Microsoft Graph PowerShell module version before you run a cmdlet or script to prevent errors and incorrect results.

    Step 2. Connect to Microsoft Graph PowerShell

    Connect to Microsoft Graph PowerShell with the required scopes.

    Connect-MgGraph -Scopes "OnPremDirectorySynchronization.ReadWrite.All" -NoWelcome

    Step 3. Check soft and hard match status

    Run the Get-MgDirectoryOnPremiseSynchronization cmdlet to get the properties and their values.

    Get-MgDirectoryOnPremiseSynchronization | Select-Object -ExpandProperty Features | Format-List

    A list of properties with their values appears. The property that we will look for is Block Cloud Object Takeover Through Hard Match Enabled and Block Soft Match Enabled.

    BlockCloudObjectTakeoverThroughHardMatchEnabled  : False
    BlockSoftMatchEnabled                            : False
    BypassDirSyncOverridesEnabled                    : False
    CloudPasswordPolicyForPasswordSyncedUsersEnabled : False
    ConcurrentCredentialUpdateEnabled                : False
    ConcurrentOrgIdProvisioningEnabled               : True
    DeviceWritebackEnabled                           : False
    DirectoryExtensionsEnabled                       : False
    FopeConflictResolutionEnabled                    : False
    GroupWriteBackEnabled                            : False
    PasswordSyncEnabled                              : True
    PasswordWritebackEnabled                         : False
    QuarantineUponProxyAddressesConflictEnabled      : True
    QuarantineUponUpnConflictEnabled                 : True
    SoftMatchOnUpnEnabled                            : True
    SynchronizeUpnForManagedUsersEnabled             : True
    UnifiedGroupWritebackEnabled                     : True
    UserForcePasswordChangeOnLogonEnabled            : False
    UserWritebackEnabled                             : False
    AdditionalProperties                             : {}

    To get only the soft and hard match properties and their value.

    Get-MgDirectoryOnPremiseSynchronization | Select-Object -ExpandProperty Features | Select-Object BlockCloudObjectTakeoverThroughHardMatchEnabled, BlockSoftMatchEnabled | Format-List

    If both properties show True, everything is already correct. If either one shows False, you need to change it to True.

    BlockCloudObjectTakeoverThroughHardMatchEnabled : False
    BlockSoftMatchEnabled                           : False

    Step 4. Block soft and hard match

    To block soft match in Microsoft Entra ID, run the command below.

    $config = @{
        'Features' =
        @{
            'BlockSoftMatchEnabled' = $true
        }
    }
    
    Update-MgDirectoryOnPremiseSynchronization -BodyParameter $config -OnPremisesDirectorySynchronizationId (Get-MgDirectoryOnPremiseSynchronization).Id

    To block hard match (cloud object takeover through hard matching) in Microsoft Entra ID, run the command below.

    $config = @{
        'Features' =
        @{
            'BlockCloudObjectTakeoverThroughHardMatchEnabled' = $true
        }
    }
    
    Update-MgDirectoryOnPremiseSynchronization -BodyParameter $config -OnPremisesDirectorySynchronizationId (Get-MgDirectoryOnPremiseSynchronization).Id

    To block the soft and hard match at once in Microsoft Entra ID, run the command below.

    $config = @{
        'Features' =
        @{
            'BlockCloudObjectTakeoverThroughHardMatchEnabled' = $true
            'BlockSoftMatchEnabled'                           = $true
        }
    }
    
    Update-MgDirectoryOnPremiseSynchronization -BodyParameter $config -OnPremisesDirectorySynchronizationId (Get-MgDirectoryOnPremiseSynchronization).Id

    Run the command below to get the property value and confirm that the change is applied successfully.

    Get-MgDirectoryOnPremiseSynchronization | Select-Object -ExpandProperty Features | Select-Object BlockCloudObjectTakeoverThroughHardMatchEnabled, BlockSoftMatchEnabled | Format-List

    Verify that both properties have the value True.

    BlockCloudObjectTakeoverThroughHardMatchEnabled : True
    BlockSoftMatchEnabled                           : True

    That’s it!

    Read more: Configure Microsoft Entra Password Protection for on-premises »

    Conclusion

    You learned how to block soft and hard match in Microsoft Entra ID. Blocking both settings strengthens your security posture by preventing unintended or unauthorized account takeovers. Every organization must apply this security change to its tenants.

    Remember that if you need to use soft or hard match, you must first set the block soft and hard match values to False, and then set them back to True afterward.

    Did you enjoy this article? You may also like How to Compare Microsoft Entra Connect Configuration. Don’t forget to follow us and share this article.

    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email

    Related Posts

    How to connect to Microsoft 365 with Microsoft Graph PowerShell

    March 27, 2026

    February 2026 Exchange Server Security Updates

    March 5, 2026

    How to Fix 550 5.1.10 RESOLVER.ADR.RecipientNotFound in Exchange Server

    March 5, 2026

    Exchange SE :- Auto installation

    February 23, 2026
    Add A Comment
    Leave A Reply Cancel Reply

    Tweets by InfoAltcoinvest

    Top Posts

    How to connect to Microsoft 365 with Microsoft Graph PowerShell

    March 27, 2026

    February 2026 Exchange Server Security Updates

    March 5, 2026

    How to Fix 550 5.1.10 RESOLVER.ADR.RecipientNotFound in Exchange Server

    March 5, 2026

    Koma Inu, Layer3, and DAR Open Network Dominate Daily Crypto Gainers

    April 6, 2026

    XRP’s April Momentum Builds as ETFs Breathe In Fresh Cash

    April 17, 2026

    Shiba Inu coin dies slowly as new rival Based Eggman reclaims memecoin momentum, GGs vs SHIB

    February 17, 2026

    Scheduled Maintenance: Platform Downtime – March 25, 2026

    March 24, 2026

    Altcoinvest is a leading platform dedicated to providing the latest news and insights on the dynamic world of cryptocurrencies.

    We're social. Connect with us:

    Facebook X (Twitter)
    Top Insights

    ‘Highly Sophisticated,’ AI-Powered Hackers Behind Vercel Breach: CEO

    April 20, 2026

    BIP-361 Proposal Akin to Seizing Bitcoin From Users: Expert ⋆ ZyCrypto

    April 20, 2026

    Bitcoin Pulls Back Below Key Levels As Iran Tensions Rise Again

    April 20, 2026
    Get Informed

    Subscribe to Updates

    Get the latest creative news from FooBar about art, design and business.


    Facebook X (Twitter)
    • Home
    • About us
    • Contact Us
    • Privacy Policy
    • Terms & Conditions
    © 2026 altcoinvest.com

    Type above and press Enter to search. Press Esc to cancel.