Shorter timeout for LogonUser?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • John

    #1

    Shorter timeout for LogonUser?

    I'm writing an application that will often be used in situations when the
    application can not see the network. I'm authenticating the user when the
    application starts up using LogonUser. This functions properly, using
    cached credentials when the app can't find a domain controller, but it takes
    way too long for it to timeout. Is there a way to instruct LogonUser to
    give up and use the cached credentials sooner (or immediately if I know the
    network is not available) ?

    Thanks,

    John


  • Jeffrey Tan[MSFT]

    #2
    RE: Shorter timeout for LogonUser?

    Hi John,

    We are currently researching on this issue, we will reply to you ASAP.
    Thanks for your understanding.

    Best regards,
    Jeffrey Tan
    Microsoft Online Partner Support
    Get Secure! - www.microsoft.com/security
    This posting is provided "as is" with no warranties and confers no rights.

    Comment

    • John

      #3
      Re: Shorter timeout for LogonUser?

      > We are currently researching on this issue, we will reply to you ASAP.[color=blue]
      > Thanks for your understanding.[/color]

      I've also noticed that the WindowsPrincipa l.IsInRole method also has a very
      long timout if the machine is disconnected.

      Thanks,

      John


      Comment

      • John

        #4
        Re: Shorter timeout for LogonUser?

        > I've also noticed that the WindowsPrincipa l.IsInRole method also has a
        very[color=blue]
        > long timout if the machine is disconnected.[/color]

        (BTW, this is a client application running on Windows XP SP2, and I need to
        get it to work with windows domains (NT-2003) )
        Upon further review, I have found that if I disable the network connection
        (or keep it enabled, but unplug the ethernet cable) on the client computer,
        both LogonUser and IsInRole return immediately with expected results.
        However, if I keep the client machine on the network, but unplug the only
        domain controller, both the LogonUser and IsInRole methods take over 30
        seconds to execute, each finally resorting to cached information. I hope
        these clues may shed some light. - John


        Comment

        • Kevin Yu [MSFT]

          #5
          Re: Shorter timeout for LogonUser?

          Hi John,

          First of all, I would like to confirm my understanding of your issue. From
          your description, I understand that you need to set the timeout value for
          LogonUser method. If there is any misunderstandin g, please feel free to let
          me know.

          As far as I know, this timeout value cannot be changed. This value is not a
          definite value and it depends on the network connections. The LogonUser
          method will be very slow when looking for the domain controller on the
          network. If there is no network connection available, it will be much
          faster.

          HTH.

          Kevin Yu
          =======
          "This posting is provided "AS IS" with no warranties, and confers no
          rights."

          Comment

          • Kevin Yu [MSFT]

            #6
            Re: Shorter timeout for LogonUser?

            Hi John,

            First of all, I would like to confirm my understanding of your issue. From
            your description, I understand that you need to set the timeout value for
            LogonUser method. If there is any misunderstandin g, please feel free to let
            me know.

            As far as I know, this timeout value cannot be changed. This value is not a
            definite value and it depends on the network connections. The LogonUser
            method will be very slow when looking for the domain controller on the
            network. If there is no network connection available, it will be much
            faster.

            HTH.

            Kevin Yu
            =======
            "This posting is provided "AS IS" with no warranties, and confers no
            rights."

            Comment

            Working...