Just need to put your server name and if you want to not include some of the access rights (ie bes server and backup software etc… just add it to the where clause).
Get-Mailbox -server myserver | Get-MailboxPermission | where {$_.user.tostring() -ne "dontshowme" -and $_.user.tostring() -ne "NT AUTHORITY\SELF" -and $_.IsInherited -eq $false} | Select Identity,User,@{Name='Access Rights';Expression={[string]::join(', ', $_.AccessRights)}} | Export-Csv -NoTypeInformation mailboxpermissions.csv