-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
home directory is not created when using \OC_User::loginWithApache() #19656
Comments
I just ran into the same issue with OC_User_IMAP. Is there a work-around, other than creating a local account? |
use an onLogin hook: \OCP\Util::connectHook('OC_User', 'post_login', 'OCA\CookieSSO\User\Backend\CookieSSO', 'onLogin'); to register a hook that calls /**
* called by hook listener added in app.php
* will create the user home
* @param string[] $params
*/
public static function onLogin(array $params) {
\OC::$server->getUserFolder($params['uid']);
} hope this helps. |
cc @PVince81 please triage and assign the correct milestone |
Set to 9.0 to look into a generic solution that doesn't require a workaround. CC @cmonteroluque |
Fixed via #23903 (comment) |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
When doing a form login the home dir is created on the fly in https://github.com/owncloud/core/blob/master/lib/private/user.php#L252
When using an apache auth mechanism the home dir is not created on the fly, resulting in:
It should be possible to use the post_login hook as the only codepath for homedir / filesystem setup:
The hook in https://github.com/owncloud/core/blob/master/lib/private/user.php#L291 should be fired in https://github.com/owncloud/core/blob/master/lib/private/user.php#L252 as well.
@icewind1991 or am I wrong?
The text was updated successfully, but these errors were encountered: