core
core copied to clipboard
can not login, if the password change by admin
Expected behaviour
The user can login normally
Actual behaviour
At the first time to login, the browser shows a blank page, after refresh or back, it turn to the login page again, and from the second time, it stays at the login page
Steps to reproduce
- login with admin account and activate the encryption
- go to the "users" page, create a new user and set a password
- change the password for this user by admin, before this user logs in with the old password
- login with this new user and the new password
Server configuration
Operating system: ubuntu 13.10
Web server: apache 2.2
Database: SQLite
PHP version: 5.4.6
ownCloud version: 6.0.3 / master
Updated from an older ownCloud or fresh install: no
List of activated app:standard apps of owncloud 6.0.3 and encryption
The content of config/config.php: (Without the database password and passwordsalt)
'oc6d9cda6e26', 'datadirectory' => '/var/www/owncloud603/data', 'dbtype' => 'sqlite3', 'version' => '6.0.3.1', 'installed' => true, 'theme' => '', 'maintenance' => false, 'maxZipInputSize' => 838860800, 'allowZipDownload' => true, 'loglevel' => '0', 'trusted_domains' => array ( 0 => '192.168.1.80', ), ); Are you using external storage, if yes which one: no ### Client configuration Browser: chromium 34.0.1847.116/ firefox 29.0 Operating system: ubuntu 12.04 ### Logs #### Web server error log ``` [Thu May 15 18:34:29.436759 2014] [:error] [pid 11579] [client 192.168.1.4:48277] PHP Fatal error: Call to a member function getLegacyKey() on a non-object in /var/www/owncloud603/apps/files_encryption/hooks/hooks.php on line 113, referer: http://192.168.1.80/owncloud603/index.php?redirect_url=%2Fowncloud603%2Findex.php%2Fapps%2Ffiles ``` #### ownCloud log (data/owncloud.log) ``` {"app":"Encryption library","message":"User account \"z\" is not ready for encryption; configuration started","level":0,"time":"2014-05-15T16:33:51+00:00"} {"app":"PHP","message":"Undefined variable: recoveryEnabledForUser at \/var\/www\/owncloud603\/settings\/changepassword\/controller.php#71","level":0,"time":"2014-05-15T16:34:01+00:00"} {"app":"PHP","message":"mkdir(): File exists at \/var\/www\/owncloud603\/lib\/private\/util.php#121","level":0,"time":"2014-05-15T16:34:29+00:00"} {"app":"Encryption library","message":"Private key for user \"z\" is not valid! Maybe the user password was changed from outside if so please change it back to gain access","level":3,"time":"2014-05-15T16:34:29+00:00"} {"app":"Encryption library","message":"Migration status set to 0","level":1,"time":"2014-05-15T16:34:29+00:00"} {"app":"Encryption library","message":"Start migration to encryption mode for z","level":1,"time":"2014-05-15T16:34:29+00:00"} {"app":"PHP","message":"Call to a member function getLegacyKey() on a non-object at \/var\/www\/owncloud603\/apps\/files_encryption\/hooks\/hooks.php#113","level":3,"time":"2014-05-15T16:34:29+00:00"} {"app":"Encryption library","message":"Private key for user \"z\" is not valid! Maybe the user password was changed from outside if so please change it back to gain access","level":3,"time":"2014-05-15T16:39:04+00:00"} {"app":"core","message":"redirectToDefaultPage: http:\/\/192.168.1.80\/owncloud603\/index.php\/apps\/files","level":0,"time":"2014-05-15T16:39:09+00:00"} {"app":"Encryption library","message":"Private key for user \"z\" is not valid! Maybe the user password was changed from outside if so please change it back to gain access","level":3,"time":"2014-05-15T16:39:19+00:00"} {"app":"core","message":"redirectToDefaultPage: http:\/\/192.168.1.80\/owncloud603\/index.php\/apps\/files","level":0,"time":"2014-05-15T16:39:24+00:00"} egacyKey() on a non-object in /var/www/owncloud603/apps/files_encryption/hooks/hooks.php on line 113, referer: http://192.168.1.80/owncloud603/index.php?redirect_url=%2Fowncloud603%2Findex.php%2Fapps%2Ffiles ```
@schiesbn
The pull request above should fix it, @dttpy maybe you want to give it a try?