Skip to main content

WEBfactory 2010

Enabling the web service documentation

Abstract

Check out this article and learn how to enable the web service documentation when working with the WEBfactory 2010.

To enable the web service documentation, the <remove name="Documentation"/> tag must be commented in the web.config files of the WEBfactory 2010 ASMX and SVC web services.

It is highly recommended to un-comment the <remove name="Documentation"/> tag once the application is published.

If having the web services documentation enabled while developing can be helpful, when the application is published, the accessible web services documentation can become a security risk. This is why disabling the web services documentation is recommended when the application is published.

When the web services documentation is enabled, it can be accessed from a web browser:

withDocumentation.png

The web service documentation in a web browser

When the web service documentation is disabled, it can not be accessed from a web browser:

withoutDocumentation.png

The web service disabled documentation

While the documentation is disabled, the web service can still be accessed from code

Enabling the documentation for the ASMX web services
  1. Open the web.config file located in the C:\inetpub\wwwroot\_Services\WEBservices folder.

  2. Find and comment the <remove name="Documentation"/> tag from the line 75.

    Capture303.jpg

    The <remove name="Documentation" /> tag from line 75

  3. Find and comment the <remove name="Documentation"/> tag from the line 81.

    Capture304.jpg

    The <remove name="Documentation" /> tag from line 75

    To comment a tag in the web.config files, add the begin comment mark <!-- before the tag and the end comment mark --> after the tag.

    • Uncommented tag: <remove name="Documentation" />

    • Commented tag: <!-- <remove name="Documentation" /> -->

  4. To disable the documentation, remove the comment marks before and after the tag.

Enabling the documentation for the SVC web services
  1. Open the web.config file located in the C:\inetpub\wwwroot\_Services\WEBservices\WCF folder.

  2. Find and comment the <remove name="Documentation"/> tag from the line 43.

    Capture305.jpg

    The <remove name="Documentation" /> tag from line 43

    To comment a tag in the web.config files, add the begin comment mark <!-- before the tag and the end comment mark --> after the tag.

    • Uncommented tag: <remove name="Documentation" />

    • Commented tag: <!-- <remove name="Documentation" /> -->

  3. To disable the documentation, remove the comment marks before and after the tag.