You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When querying users I see many errors from the Transform module in relation to the proxyAddresses attribute of contact objects.
To Reproduce
Query the directory for mail objects that have a proxyAddresses value that contains something like this:
SMTP:[email protected]; NOTES:John Amith1/Certifier@ICEB; X400:c=GB;a= ;p=IB;o=ICAO;s=Smith2;g=John;;
Note the empty/blank value at the end (between the two semi-colons)
Expected behavior
For consideration - in my case there are three valid and one invalid entries in the proxyAddresses attribute. This is the account forest, Exchange existed in the resource forest. I don't think you should spew red errors to the console. I think an orange warning saying there's some rubbish in the proxyAddresses would be better. Take the values, handle the "error" (bad data really - I have no idea how we got into this state).
Or better yet, if there's more than one value in proxyAddresses why bother the user at all - just ignore/bin the empty value. Is it even worth outputting that there's rubbish there?
Environment (please complete the following information):
OS: Windows Server 2022
PowerShell version 5.1.20348.2849
S.DS.P Module version 2.2.1
The target AD environment is older though :) -- Server 2012 R2 AD DS, Exchange Server 8.3 and 15.0 don't complain when calling Get-MailUser or Get-Mailbox
The text was updated successfully, but these errors were encountered:
Well, I looked at the code and: when invalid entry in multival attr --> transform logic throws and nothing returned in the attr. This is something I wanted to improve.
However, I did not want to just silently ignore invalid entries, not telling caller that something is wrong.
So I went the way of design intention of PowerShell engine and added better support for ErrorActionPreference in Find-LdapObject:
Stop just throws on first invalid entry
Continue writes errors but continues processing
SilentlyContinue just swallows the errors and ignores invalid entries
What I'm still thinking about is the scope of ErrorActionPreference as I feel it might be too wide - setting to SilentlyContinue will just hide all errors encountered when querying, not only invalid attribute errors, which might not be suitable for every scenario.
Thoughts?
Anyway, experimental handling for proxyAddress transform is in 2.2.2-beta1 - please test / play with it
Describe the bug
When querying users I see many errors from the Transform module in relation to the proxyAddresses attribute of contact objects.
To Reproduce
Query the directory for mail objects that have a proxyAddresses value that contains something like this:
SMTP:[email protected]; NOTES:John Amith1/Certifier@ICEB; X400:c=GB;a= ;p=IB;o=ICAO;s=Smith2;g=John;;
Note the empty/blank value at the end (between the two semi-colons)
Expected behavior
For consideration - in my case there are three valid and one invalid entries in the proxyAddresses attribute. This is the account forest, Exchange existed in the resource forest. I don't think you should spew red errors to the console. I think an orange warning saying there's some rubbish in the proxyAddresses would be better. Take the values, handle the "error" (bad data really - I have no idea how we got into this state).
Or better yet, if there's more than one value in proxyAddresses why bother the user at all - just ignore/bin the empty value. Is it even worth outputting that there's rubbish there?
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: