Share via

ErrorOnlyAllowInEopException

Anonymous
2018-10-12T08:16:06+00:00

When I try to run "Get-DlpSensitiveInformationTypeRulePackage" in powershell, I'm getting the below error:

PS C:\Powershell> Get-DlpSensitiveInformationTypeRulePackage

This command is only allowed to run in Exchange Online Protection environment.

    + CategoryInfo          : NotSpecified: (:) [Get-DlpSensitiv...TypeRulePackage], ErrorOnlyAllowInEopException

    + FullyQualifiedErrorId : [Server=KL1PR03MB1462,RequestId=5d308fdf-ae6d-4a3d-8c59-f5492c999201,TimeStamp=12-10-2018 08:01:23] [FailureCategory=Cmdlet-ErrorOnlyAllowInEopException] 55635B

   18,Microsoft.Office.CompliancePolicy.Tasks.GetDlpSensitiveInformationTypeRulePackage

    + PSComputerName        : outlook.office365.com

We have Exchange online protection in our environment.

I have Office 365 E5 license and I'm able to access security & compliance centre in portal. I'm able to run mailbox, msol cmdlets in powershell. Only for this DLP cmdlet I'm getting error.

Microsoft 365 and Office | Subscription, account, billing | For business | Other

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2018-10-24T09:20:48+00:00

Hi, 

Issue was resolved after adding my account to compliance management in "Exchange admin center". Earlier I added in compliance administrator from security and compliance center, it didn't worked. 

Anyway, Thanks for the support.

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

2 additional answers

Sort by: Most helpful
  1. Anonymous
    2018-10-16T14:52:11+00:00

    Hi ElangambanM 

    Do you have any update? 

    Moreover, make sure that you have connect to Office 365 Security & Compliance Center PowerShell. Note that the connection instructions are different from Exchange Online or Exchange Online Protection (the ConnectionUri value is different).See Connect to Office 365 Security & Compliance Center PowerShell

    For your reference: Get-DlpSensitiveInformationTypeRulePackage

    Best regards, 

    Shyamal

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2018-10-12T19:15:28+00:00

    Hi ElangambanM,

    Would you please help check if you can get the related information in the Office 365 admin center? By doing so, we can clarify the if it is related to the permission of the account used to connect to Exchange Online PowerShell. I suggest that use  Global administrator  account to connect to PowerShell and run this cmdlet again to see how it goes.

    Best regards,

    Coldwell

    Was this answer helpful?

    0 comments No comments