Forum OpenACS Q&A: Re: Unable to login after upgrade to OpenACS 5.1

Collapse
Posted by Jade Rubick on
Okay, here's the evil way to fix this:

cd packages/acs-authentication
emacs patch-file

copy this into the file:

Index: tcl/authentication-procs.tcl
===================================================================
RCS file: /var/cvs/ibr/packages/acs-authentication/tcl/authentication-procs.tcl,v
retrieving revision 1.6
diff -u -r1.6 authentication-procs.tcl
--- tcl/authentication-procs.tcl        8 Nov 2004 23:08:31 -0000      1.6
+++ tcl/authentication-procs.tcl        10 Nov 2004 21:42:15 -0000
@@ -204,10 +204,14 @@
    }

    with_catch errmsg {
-        array set result [auth::authentication::Authenticate \
-                                -username $username \
-                                -authority_id $authority_id \
-                                -password $password]
+        # HACK:
+        set result(auth_status) ok
+        set result(account_status) ok
+
+        #array set result [auth::authentication::Authenticate \
+        #                        -username $username \
+        #                        -authority_id $authority_id \
+        #                        -password $password]

        # We do this so that if there aren't even the auth_status and account_s
tatus that need be
        # in the array, that gets caught below
@@ -332,6 +336,9 @@
            set result(account_message) $remote_account_message
        }
    }
+
+    # HACK:
+    set result(auth_status) ok

    # Issue login cookie if login was successful
    if { [string equal $result(auth_status) "ok"] && !$no_cookie_p && [exists_and_not_null result(user_id)] } {

+++++++++++++++++++++

Make sure you are not plugged into the internet at large, because this allows all login attempts to succeed!

svc -t /service/yourservicename

Log in.
Upgrade your site to OpenACS 5.1.2

Revert the file back to how it was (if it's in cvs, then rm tcl/authentication-procs.tcl; cvs update tcl/authentication-procs.tcl)

It should work now.