Skip to content

typing username wrong creates new user #4616

Closed

Description

@TwoPhased

Hi there!

I ran in to a serious problem with my owncloud installation. Each time I log in to the webbased side of owncloud with an ipad, it automaticly types my name with a capital letter, however, my username in owncloud is all lowercase. What happens when I log in with a capital letter in front of my username, is that al my files seem gone. But after digging around in my data folder, I noticed there was now another folder with the same username I have, but starting with a capital letter. The original folder, containing all my files, still sits there, but it is the content of the capital letter folder I get to see when I log in to the webbased version AND webdav/clientsync

To solve it, I screwed around a lot in the config file etc, probably from blind panic :) , and after deleting the newer folder and changing the config.php datadir from a symlink sitting in my owncloud folder on the webserver, to the original datadir of the oc datafolder, wich I have placed on another drive. Last night the same happend, but now I didn't have to change the datadir back to the symlink again, like I had to do last time. Perpaps later today I will run in to a snag that will force me to do that after all.

Anyway, I hope someone, probably and preferbly the one who can fix this, is able to make heads and tail from my post, or at least point me in the right direction. Cause I think this qualifies as a serious problem.

Thanks in advance

update:
I have uploaded a file to my owncloud folder on my system to see if syncing was affected by all of this, but the file went straight to the datadir on oc, the same was true for uploading via the webinterface. So I can only conclude that changing the datadir and telling config.php the original path, in stead of the symlink, to the datadir, is now somehow permitted. Or am wrong? (sew me for not reading entire forum later)

Now before you start asking me all sorts of questions, wich have been asked before, I suggest you read up on what I have posted on oc forum. That would save me the trouble of repeating myself. So here is the post:

http://forum.owncloud.org/viewtopic.php?f=23&t=15220&p=38941#p38941

Activity

  1. DeepDiver1975 commented on Aug 28, 2013

    @DeepDiver1975
    Contributor
  2. TwoPhased commented on Aug 28, 2013

    @TwoPhased
    Author

    What does this (@karlitchek) mean? Sorry for being a moron.

    Op 29 aug. 2013 om 00:13 heeft Thomas Müller [email protected] het volgende geschreven:

    @karlitschek

    —
    Reply to this email directly or view it on GitHub.

  3. MTGap commented on Aug 29, 2013

    @MTGap
    Contributor

    I just had this happen to me as well. For me the initial login worked correctly, but after restarting my computer it created a new data directory for a different case username that I had logged in with last time. This was with remember login checked.

    The problem is probably that username stored in the cookie is not the correct case. See https://github.com/owncloud/core/blob/master/lib/base.php#L801

  4. TwoPhased commented on Aug 29, 2013

    @TwoPhased
    Author

    Thank you very much for your reply, but the link you showed me doesn't tell me anything, mainly because I do not understand the code, let alone seeing what is wrong with it.. All I like to know is:

    1. Is it related to owncloud, or to some underlying server component?
    2. Is it something I can fix myself, or do I wait until oc comes up with a fix?
    3. How to fix ( if at all possible)?

    Regards, TwoPhased

    Op 29 aug. 2013 om 04:11 heeft Michael Gapczynski [email protected] het volgende geschreven:

    I just had this happen to me as well. For me the initial login worked correctly, but after restarting my computer it created a new data directory for a different case username that I had logged in with last time. This was with remember login checked.

    The probably is that username stored in the cookie is not the correct case. See https://github.com/owncloud/core/blob/master/lib/base.php#L801

    —
    Reply to this email directly or view it on GitHub.

  5. karlitschek commented on Aug 29, 2013

    @karlitschek
    Contributor

    Wow. This sounds like a bad error. @blizzz Can you have a look?

  6. blizzz commented on Aug 29, 2013

    @blizzz
    Contributor

    It's stored in the PHP session file (on Ubuntu 13.04 in /var/lib/php5/). To Reproduce it, you need to delete them, relogin or deleting cookies won't work. Working on a fix.

  7. blizzz commented on Aug 29, 2013

    @blizzz
    Contributor

    And delayed (fix in place, but cannot test) because of #4613 (comment)

  8. Takuto88 commented on Aug 29, 2013

    @Takuto88
    Contributor

    @blizzz Could these issues be related?
    #1314
    #3293
    #3939 <- PR related to 3293

    @TwoPhased: First of all: Thank you for reporting this. To answer your questions: the @githubusername notation causes a notification being send by mail to that user. In addition, it is also clear that this comment addresses someone directly. This is also similar to mentions on Twitter if you are familiar with that.

    Regarding your other questions I can say that this is likely an issue with ownCloud itself, there is nothing you should try to do as of now yourself unless you know what you are doing and that this will be fixed from our side. Stay put and see what's happening here in this issue. Everything is going to be OK.

  9. TwoPhased commented on Aug 29, 2013

    @TwoPhased
    Author

    @Takuto
    You're welcome, and I am now sitting on my hands to prevent them from messing with stuff ;) Im already glad to hear it aint my fault and that the issue is being dealt with. I am truly happy with OC and I would like to continue using it like I did.
    Thanks for the help y'all!!

  10. TwoPhased commented on Aug 29, 2013

    @TwoPhased
    Author

    oops, now I know what this button does

  11. blizzz commented on Aug 29, 2013

    @blizzz
    Contributor

    Yes, #1314 and #3293 sound like the same issue. I am not sure whether the PR is, at least the fix can be done more easily.

  12. Takuto88 commented on Aug 29, 2013

    @Takuto88
    Contributor

    @blizzz Would it be safe in your opinion for @TwoPhased to test the new base.php it this fixes his problem? From my point of view this should be safe but then again I am just starting to get the feeling for the server core ;-)

  13. blizzz commented on Aug 30, 2013

    @blizzz
    Contributor

    It's merged now, but sure @TwoPhased can test it. He possibly needs to delete the PHP session files before.

  14. blizzz commented on Aug 30, 2013

    @blizzz
    Contributor

    Fixed by #4654 → ownCloud 5.0.11

  15. Takuto88 commented on Aug 30, 2013

    @Takuto88
    Contributor

    @TwoPhased: Please test if the PR #4654 fixes your problem. If you don't know how to do that, just write me a message and I will be happy to help.

  16. TwoPhased commented on Aug 30, 2013

    @TwoPhased
    Author

    Yes, I would like some help please! Although I generally pick up things fast, I am not that familiar with php stuff. Had to teach myself most of what I know, and that is mostly enough to keep my linux ubuntu server up. But if you can tell me what I have to do, with what (ssh/webmin/texteditor) where and in what capacity (root/sudo), I think I will manage. If it's something that will be patched relatively soon in 5.0.11 , I can always wait and avoid logging in from a system that puts a capital in front of my username.

    Thanks in advance
    TwoPhased

    p.s.
    If you like i can give you a IM address so that you can speak to me in private. Just tell me where to send it.

    Op 30 aug. 2013 om 12:26 heeft Lennart Rosam [email protected] het volgende geschreven:

    @TwoPhased: Please test if the PR #4654 fixes your problem. If you don't know how to do that, just write me a message and I will be happy to help.

    —
    Reply to this email directly or view it on GitHub.

  17. Takuto88 commented on Aug 30, 2013

    @Takuto88
    Contributor

    It's relatively simple actually.

    1. Take this file and put it into [owncloud-root]/lib/base.php
    2. Log out of ownCloud, delete all your cookies to be save and delete all PHP Session files from your server. On your system they are most likely under /var/lib/php5. They are named like "sess_nve1spca542oo1239bf9iqsr35" or similar.
    3. Try logging into ownCloud with an incorrectly cased username (e.g. "Testuser" instead of "testuser") and see if your problem persists. It should no longer create a new folder for the incorrectly cased user.

    If you have any further questions please contact me directly trough my public email found here.

  18. TwoPhased commented on Aug 30, 2013

    @TwoPhased
    Author

    I have done like you said, overwritten /myserver/owncloud/lib/base with the file I've downloaded, removed sessions from /var/lib/php5 and cleared all cookies, from my ipad's safari -from wich I ran in to this snag in the first place-, even gave apache a reboot for good measure. I logged in with my username starting with a capital letter and saw my regular files, I then logged out to log in again, this time with my regular name, and that also worked like it aught to. Gave my server a reboot, and tried it twice again, that also went well :) Thanks guys! I'ma happy camper.

    On a sidenote: could it be that this base.php file has changed between versions of oc? Because I use it for rather a long time, and I can imagine this hapening lot's of times before (loggin in from ipad with username starting with capital letter). But this "flaw" came much later.

    Also, am I correct in assuming that this fix for issue 4616 will be part of oc 5.0.11? And, lastly, How come virgin LAMP systems (like my virtual sys, and another one that I set up for a friend in sweden) don't seem to suffer from this flaw (yet)?

    Anyway, Again, thank you very much dudes, this was something that shook my faith a little, so I'm glad it's solved :)

  19. Takuto88 commented on Aug 30, 2013

    @Takuto88
    Contributor

    Glad to hear that. This will be in 5.0.11 so don't worry about the next update. Take care.

  20. locked as resolved and limited conversation to collaborators on Aug 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions