microsoft / AADConnectConfigDocumenter

AAD Connect configuration documenter is a tool to generate documentation of an AAD Connect installation.
Other
243 stars 49 forks source link

Documenter crashes when using Directory Extensions Attribute Sync #4

Closed chris-graves closed 7 years ago

chris-graves commented 7 years ago

Hi I'm having a problem running the Documenter against a configuration that has Directory Extension Attribute sync enabled.

In the protected void FillConnectorSelectedAttributesDataSet(bool pilotConfig) method - (line 951 of ConnectorDocumentor.cs) the following code is executed

var attributeInfo = connector.XPathSelectElement(".//dsml:attribute-type[dsml:name = '" + attributeName + "']", Documenter.NamespaceManager);

This return a NULL which causes an exception when trying to set the row value later in the method, causing the program to terminate without creating a report.

The attribute name causing an error in our configuration is extension_7b47cfcf830741a8a8f2c7c15d21a18d_adminDescription. I can forward a set of configuration files for the environment if required.

Kind regards

Chris

NileshGhodekar commented 7 years ago

It will be faster if you could send the files. nileshg at microsoft.com

NileshGhodekar commented 7 years ago

It looks like somehow the config file is in inconsistent state. The only valid config is for extension_7b47cfcf830741a8a8f2c7c15d21a18d_extensionAttribute8, ...11 , ...15 while it's invalid for extension7b47cfcf830741a8a8f2c7c15d21a18dadminDescription, ...description and ...wWWHomePage. These should not be present in the config any more, but they are there. I'll have this misconfig handled in the next build, but for now the report will run if you delete the later three attributes from the Connector_{b891884f-051e-4a83-95af-2544101c9083}.xml file before running the tool.

chris-graves commented 7 years ago

Thanks Nilesh

That's interesting. I just ran through the configuration wizard again and found that we only have extensionAttributes 8,11 and 15 enabled as directory extensions.

However, we had adminDescription, description and wWWHomePage selected as directory extensions at some point in the past when trying to work out why the description attribute was not accessible via Graph API.

I guess that adding a Directory extension attribute and then removing it leaves some traces in the configuration files? Or maybe the fact that the attribute names remain in the metaverse is causing them to appear in our configuration file?

Anyway, thanks for adding code to handle the misconfiguration issue.

Chris


From: Nilesh Ghodekar notifications@github.com Sent: 05 May 2017 15:30:33 To: Microsoft/AADConnectConfigDocumenter Cc: Chris Graves; Author Subject: Re: [Microsoft/AADConnectConfigDocumenter] Documenter crashes when using Directory Extensions Attribute Sync (#4)

It looks like somehow the config file is in inconsistent state. The only valid config is for extension_7b47cfcf830741a8a8f2c7c15d21a18d_extensionAttribute8, ...11 , ...15 while it's invalid for extension_7b47cfcf830741a8a8f2c7c15d21a18dadminDescription, ...description and ...wWWHomePage. These should not be present in the config any more, but they are there. I'll have this misconfig handled in the next build, but for now the report will run if you delete the later three attributes from the Connector{b891884f-051e-4a83-95af-2544101c9083}.xml file before running the tool.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/Microsoft/AADConnectConfigDocumenter/issues/4#issuecomment-299480391, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AbIE2iz6d6H58wjbfm2RKiqGlPfihnvXks5r2zKJgaJpZM4NR6ug.

Oxford Computer Group Ltd is a company registered in England and Wales (number 04574934) whose new registered office is at 6th Floor, Seacourt Tower, West Way, Oxford, OX2 0JJ.

NileshGhodekar commented 7 years ago

fix checked in. Closing the issue now. Formal release will be along with few other changes.