Tags:
create new tag
, view all tags

SID-02197: User Registration gets error message on login

Status: Asked Asked TWiki version: 6.0.2 Perl version:
Category: CategoryRegistration Server OS: Last update: 1 year ago

Hello,

I've been trying to see how user registration works, and when I create a new user through the registration form without a problem, but when it's finished, it takes the new user to a login screen which says that they are already registered when they try to log in. So, I select Reset Password, but when I try to do that, I get a "Can't get an e-mail address for..." that user.

Help?

Thanks, Andy

-- Andrew Schwartz - 2016-05-05

Discussion and Answer

TWiki's registration is controlled by a couple of configuration values, and it interacts with both the login manager and email. A wild guess:In configure, section "Security setup": Is {Register}{NeedVerification} checked? In that case, a new user needs to visit a link which is sent to his email address before he can successfully login, but I guess that TWiki already has created a few data so that the error message says "already registered". If not, can you help narrow it down by providing some of your settings:

  • In configure, section "Mail and Proxies": Is {EnableEmail} checked?
  • Does the user's topic exist in the Main web? Does it have a mail address in the metadata?
  • Is the user's name listed in the TWikiUsers topic?
  • Are you using TWiki's template login or Apache's authentication?

-- Harald Jörg - 2016-05-05

Hello Harald:

In configure, section "Mail and Proxies": Is {EnableEmail} checked? YES

Does the user's topic exist in the Main web? Does it have a mail address in the metadata? NO, none of them do

Is the user's name listed in the TWikiUsers topic? YES

Are you using TWiki's template login or Apache's authentication? TWiki's template

-- Andrew Schwartz - 2016-05-06

Thanks for the info! I just saw SID-02188 and guess that these are related issues...

In that other topic you write that the users don't receive their welcome message. It is not unusual that they are immediately taken to a login screen: The welcome message doesn't need to be acted upon by the user (unless {Register}{NeedVerification} is set). The welcome message is sent to make sure that bad guys can't surreptitiously register with other people's mail addresses. But this observation may help to find the root cause. In addition to the welcome mails sent to the user, the wiki admin should also receive an informational mail that someone has registered. Did you receive these mails?

Regarding to the missing mail address in meta data: I have to apologize, that question was nonsense. Current TWiki versions don't store user mail addresses in the user topics to fight off spammers. Instead, TWiki writes them to the file where passwords are stored, and this might indeed be a clue: I guess that you didn't fiddle with TWiki configuration more than necessary, so please look at the file data/.htpasswd in your installation. For registration, user email and login to work, this file must exist and be writeable by the web server's user id (like the data directory and all the other files and directory in it). So these are the things to check:

  • Is the data directory writeable by the web server's user id?
  • Does data/.htpasswd exist?
    • If yes: Does it contain entries for the registered users, including their mail addresses?
      • If yes: Does your mail setup work at all? You need either Perl's Net::SMTP installed plus a SMTP server, or a standalone mail tool like sendmail for that.
      • If no: Check the permission of the file. It needs to be writeable by the web server's user id.
    • If no: Check the configuration variable {Htpasswd}{FileName}. Maybe it points to nirvana instead of the absolute path of data/.htpasswd?

-- Harald Jörg - 2016-05-06

      Change status to:
ALERT! If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.
SupportForm
Status Asked
Title User Registration gets error message on login
SupportCategory CategoryRegistration
TWiki version 6.0.2
Server OS

Web server

Perl version

Browser & version

Edit | Attach | Watch | Print version | History: r4 < r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r4 - 2016-05-06 - HaraldJoerg
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.