Problem with OLEDB and passwords - IBM AS400

This is a discussion on Problem with OLEDB and passwords - IBM AS400 ; Hi, Sorry if it is the wrong group, please redirect me to another more appropriate if any. I am experiencing problems with something that worked earlier. I am connecting to an AS400 (V4R5M0) using OLEDB provider IBMDA400 (Client Access currently ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: Problem with OLEDB and passwords

  1. Problem with OLEDB and passwords

    Hi,

    Sorry if it is the wrong group, please redirect me to another more
    appropriate if any.

    I am experiencing problems with something that worked earlier.

    I am connecting to an AS400 (V4R5M0) using OLEDB provider IBMDA400 (Client
    Access currently at SF67276, MDAC on the PCs are at 2.7sp1 or 2.8).

    The offending code (which obviously is in a shared applet) reads
    Set cn = New ADODB.Connection
    cn.Open "OLEDB;Provider=IBMDA400;Data Source=MOVEX"

    The "MOVEX" DSN is pretty standard (and it is shared too): the connection
    options (seen through the ODBC administrator) are set up to "Use Operation
    Navigator setup" (4th option of 4), or in another case "Use default userID
    [local user], ask when necessary" (2nd option of 4).

    When the Operation Navigator client site connection is set up as "use name
    and password of Windows, don't ask" (1st option of 3 there), everything goes
    well, earlier and now.

    However, for security/paranoid reasons, some have it set up as the 2nd
    option, "use default userID, ask when necessary" (that is, I have to enter
    the password twice, once to log on in Windows, and another the first time I
    want to log on the AS/400; perhaps with a different password).
    This setup used to work, but now it does not.
    While intenting connecting, instead of displaying the 3 boxes dialog asking
    for the password (as it used to do), Client Access suspends operations for
    some seconds, then aborts with message (translated) "Password is incorrect,
    password length=0, prompt mode=PROMPT_NEVER"; another client have
    additionally the indication of error 80040E4D (which is also related to
    passwords.)

    I have traced down what happens under the hood, but I did not spot the place
    where there is the problem: CA looks into cache, WNetGetCachedPassword etc.,
    finds nothing, then goes to Comm-base to get the sign on, does socket stuff
    to establish IP@ and port (8476), successfully establish TCP, makes some
    unbearable dialog (within Comm-base), ends with
    Client Access Security PiSySecurity::validateSignonInfo Exit rc=8002
    (looks bad news to me), and then disconnects and release all resources.


    What should I do to keep it working, without asking the user every time for
    her password inside the shared app?


    Antoine


  2. Re: Problem with OLEDB and passwords

    On Wed, 13 Dec 2006 11:24:37 +0100, "Antoine Leca" wrote:

    >While intenting connecting, instead of displaying the 3 boxes dialog asking
    >for the password (as it used to do), Client Access suspends operations for
    >some seconds, then aborts with message (translated) "Password is incorrect,
    >password length=0, prompt mode=PROMPT_NEVER"; another client have
    >additionally the indication of error 80040E4D (which is also related to
    >passwords.)


    ....add this to your connection sting: "prompt=2"

    So: cn.Open "OLEDB;Provider=IBMDA400;Data Source=MOVEX;prompt=2"

    --
    Mark.


+ Reply to Thread