User locked out

Posted by stefan.lang@havilog.com on 02-Dec-2011 01:29

HI, is there any way to set the password of an user by an system admin/dba  NOT knowing the old user password?

All Replies

Posted by olivier.dunemann on 02-Dec-2011 04:14

Why not simply delete and recreate the _User record?

FIND FIRST _user WHERE _user._userid = "gst" EXCLUSIVE-LOCK NO-ERROR.
DELETE _user.

CREATE _user.

ASSIGN _user._userid = "gst"

             _user._password = ENCODE("pass").
RELEASE _user.

Posted by stefan.lang@havilog.com on 02-Dec-2011 04:31

That would be the last ressort, but the system is multi-user and defers jobs to a background queue.

To delet a user at run-time could have unwanted effects.

And I am not sure about effects to auditing and relational integetry etc.

Posted by olivier.dunemann on 02-Dec-2011 04:53

It seems obvious but, did you try the solution proposed in OE Knowledge Base P127152 (How to programmatically change another users password in _user table)?

[View:~/cfs-file.ashx/__key/communityserver-discussions-components-files/26/P127152-_2D00_-How-to-programatically-change-another-users-password-in-_5F00_user-table.pdf:550:0]

Posted by stefan.lang@havilog.com on 02-Dec-2011 05:07

The problem is the sentence:

"This solution assumes that the connected user must be an
administrator and that he has knowledge of, or access to, the user's original password."

That's not the case.

Posted by Thomas Mercer-Hursh on 02-Dec-2011 11:12

You can easily scope the delete and add to be part of the same transaction.

This thread is closed