[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Get Report to Manager Enabled

Posted on 2014-01-17
1
Medium Priority
?
473 Views
Last Modified: 2014-01-22
Hi experts,

Was wondering if I could have some help with a one liner PS script that I used to get the Required Sender Authentication disabled. The script I have is:

Get-DistributionGroup -ResultSize Unlimited | ? {$_.RequireSenderAuthenticationEnabled -eq $false} | select Name,GroupType,PrimarySMTPAddress | Export-Csv c:\filename

Now what I would like to find out in addition is whether the Report to manager option is enabled as well... and by whom,I tried this..

Get-DistributionGroup -ResultSize Unlimited | ? {$_.RequireSenderAuthenticationEnabled -eq $false} | select Name,GroupType,PrimarySMTPAddress |  {$_.ReportToManagerEnabled -eq $false} | Export-Csv C:\filename

though this does not work. Could someone have a look and help me sort this little script out?

Many thanks.
17-01-2014-09-44-09.png
0
Comment
Question by:damejen
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 53

Accepted Solution

by:
Will Szymkowski earned 2000 total points
ID: 39788166
"ReportToManagerEnabled" is not an attribute which is why it is not working... Use the below syntax below to accomplish this...

The Property that you are looking for is an AD Property AccessRights is WriteProperty and Property is Member.

The command needs to be separate from your previous one as they are different cmdlets...

get-distributionGroup -ResultSize "unlimited" | Get-ADPermission | ? {$_.AccessRights -like "*Write*" -and $_.Properties -like "*member*" -and $_.User -notlike "domain\*Exchange*"} | Select Identity, accessrights, properties,user

Open in new window


The above command will get all distribution groups, pipe to get-adpermission and only find objects that have AccessRights like Write as part of the vaule and have Properties like Member and not like any object that starts with Exchange, which will remove any results from Exchange Groups that have this access.

Make sure that you change "-notlike "domain\*Exchange*" to "yourdomain\*Exchange*.

Will.
0

Featured Post

Get your Disaster Recovery as a Service basics

Disaster Recovery as a Service is one go-to solution that revolutionizes DR planning. Implementing DRaaS could be an efficient process, easily accessible to non-DR experts. Learn about monitoring, testing, executing failovers and failbacks to ensure a "healthy" DR environment.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A couple of months ago we ran into an issue that necessitated re-creating our Edge Subscriptions. However, when we attempted to execute the command: New-EdgeSubscription -filename C:\NewEdgeSub_01.xml we received an error indicating that the LDAP se…
This month, Experts Exchange sat down with resident SQL expert, Jim Horn, for an in-depth look into the makings of a successful career in SQL.
In this video we show how to create a Shared Mailbox in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >> Sha…
In this video we show how to create a Contact in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >> Contact ta…
Suggested Courses

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question