ASP.NET and LDAP Connection

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • schtroumfps@hotmail.com

    ASP.NET and LDAP Connection

    Hi,
    I have developed an internal application in ASP.NET 2.0/C# that is
    using an LDAP connection. Basically, I am getting the LDAP users to
    match some user’s roles and rights that I have in SQL 2005 tables.

    When I am testing the application locally this is working perfectly. I
    have place the application on an internal test server (inside the same
    domain) and we found out that we needed to unchecked the “Enable
    anonymous access” option in the Authentication Methods in IIS to make
    it work. Otherwise, it was not loading the website.

    My next step was to create a deployed the application in a production
    environment using the same LDAP connection and SQL database with the
    “enable anonymous access” unchecked. The application is working
    perfectly except that we needed to add a port number to the alias name
    created to make it works.

    I.e.: Our NT Server name is http://AAA/BBB/234.aspx and the DNS alias
    name is http://Production/234.aspx.
    But to make it work in that environment we need to created the alias
    like this http://Production:555/234.aspx.

    There are already 3 applications on that server and 2 of them need to
    have the port number in the alias.

    Anybody have an idea why we need to add that information to run the
    website? And how could we resolved that minor problem?

    Thanks in advance
  • Alexey Smirnov

    #2
    Re: ASP.NET and LDAP Connection

    On Oct 22, 10:26 pm, schtroum...@hot mail.com wrote:
    Hi,
    I have developed an internal application in ASP.NET 2.0/C# that is
    using an LDAP connection. Basically, I am getting the LDAP users to
    match some user’s roles and rights that I have in SQL 2005 tables.
    >
    When I am testing the application locally this is working perfectly. I
    have place the application on an internal test server (inside the same
    domain) and we found out that we needed to unchecked the “Enable
    anonymous access” option in the Authentication Methods in IIS to make
    it work. Otherwise, it was not loading the website.
    The anonymous access option enabled the IIS do not perform any
    authentication check and the token represents the anonymous user
    IUSR_MACHINENAM E (IUSR account on IIS7) which probably has no access
    to LDAP.

    >
    My next step was to create a deployed the application in a production
    environment using the same LDAP connection and SQL database with the
    “enable anonymous access” unchecked. The application is working
    perfectly except that we needed to add a port number to the alias name
    created to make it works.
    >
    I.e.: Our NT Server name ishttp://AAA/BBB/234.aspxand the DNS alias
    name ishttp://Production/234.aspx.
    But to make it work in that environment we need to created the alias
    like thishttp://Production:555/234.aspx.
    >
    There are already 3 applications on that server and 2 of them need to
    have the port number in the alias.
    I think I am not really understand the problem. Do you mean that the
    first server is http://production and each new site has to have a port
    number in the url? This can be solved by using host headers. Isn't it?

    >
    Anybody have an idea why we need to add that information to run the
    website? And how could we resolved that minor problem?
    >
    Thanks in advance

    Comment

    • schtroumfps@hotmail.com

      #3
      Re: ASP.NET and LDAP Connection

      On 22 oct, 20:17, Alexey Smirnov <alexey.smir... @gmail.comwrote :
      On Oct 22, 10:26 pm, schtroum...@hot mail.com wrote:
      >
      Hi,
      I have developed an internal application in ASP.NET 2.0/C# that is
      using an LDAP connection. Basically, I am getting the LDAP users to
      match some user’s roles and rights that I have in SQL 2005 tables.
      >
      When I am testing the application locally this is working perfectly. I
      have place the application on an internal test server (inside the same
      domain) and we found out that we needed to unchecked the “Enable
      anonymous access” option in the Authentication Methods in IIS to make
      it work. Otherwise, it was not loading the website.
      >
      The anonymous access option enabled the IIS do not perform any
      authentication check and the token represents the anonymous user
      IUSR_MACHINENAM E (IUSR account on IIS7) which probably has no access
      to LDAP.
      >
      >
      >
      My next step was to create a deployed the application in a production
      environment using the same LDAP connection and SQL database with the
      “enable anonymous access” unchecked. The application is working
      perfectly except that we needed to add a port number to the alias name
      created to make it works.
      >
      I.e.: Our NT Server name ishttp://AAA/BBB/234.aspxandthe DNS alias
      name ishttp://Production/234.aspx.
      But to make it work in that environment we need to created the alias
      like thishttp://Production:555/234.aspx.
      >
      There are already 3 applications on that server and 2 of them need to
      have the port number in the alias.
      >
      I think I am not really understand the problem. Do you mean that the
      first server ishttp://productionand each new site has to have a port
      number in the url? This can be solved by using host headers. Isn't it?
      >
      >
      >
      Anybody have an idea why we need to add that information to run the
      website? And how could we resolved that minor problem?
      >
      Thanks in advance
      Thanks for your answer but we finally find out what was our problem.
      The LDAP was not communicating because some guys just unchecked the
      enabled HTTP Keep-Alives Options in the Connections panel in the
      Website properties of the website.

      Comment

      Working...