I'm trying to recreate an authentication scheme (originally implemented in
ASP) using tango's objects. The original ASP code looks something like this:

Arguments: oDomain - Domain controller you're connecting to
           oUser - supplied username
           oPassword - supplied password

Set objUser = GetObject("WinNT://" & oDomain & "/" & oUser )

Select Case instr(1, objUser.Description, strTestCriteria)
Case 0, null
   'THE USER DOES NOT EXIST
Case Else
    on error resume next
    'THE USER EXISTS SO VERIFY PASSWORD
    objUser.ChangePassword  oPassword, oPassword
    'IF WE SUCCESSFULY REPLACE THE PASSWORD THEN IT MUST BE CORRECT
    if err.number = 0 then
       'SUCCESS -- DO WHAT EVER
    else
       'FAILURE -- FAIL
    end if      
End Select


I began playing with ADS objects but no luck so far.
Does anyone have any ideas on how to implement this in tango?


Thanks,

Peter Baranowski
[EMAIL PROTECTED]
________________________________________________________________________
TO UNSUBSCRIBE: send a plain text/US ASCII email to [EMAIL PROTECTED]
                with unsubscribe witango-talk in the message body

Reply via email to