Tags:
create new tag
view all tags

SID-02026: Restricting access to all webs but allow user registration

Status: Answered Answered TWiki version: 6.0.0 Perl version: 5.14.2
Category: CategoryAccessControl Server OS: Debian Linux 7.8 Last update: 10 years ago

What I'm trying to achieve: Authentication is required to view any web, but new users can still register.

What I've done: TWiki web has ALLOWWEBVIEW set to a specific group; TWikiRegistration has

   * Set ALLOWTOPICVIEW = Main.AllUsersGroup

What I expect to happen: Non-logged in users can access the TWikiRegistration page

What happens: Non-logged in users get redirected to the login page.

What do I need to do to achieve my objective?

Thanks, Keith

-- Keith Edmunds - 2015-02-17

Discussion and Answer

As soon as you add an access control setting you tell TWiki to authenticate the user. So this is not the way to exclude the TWikiRegistration topic.

The easiest way is to keep the TWiki web open to all, and to lock down all webs of interest using ALLOWWEBVIEW in the web's WebPreferences. If you lock down the Main web make sure to add the TWikiRegistrationAgent to ALLOWTOPICVIEW in your Main.WebPreferences.

You could also try to create a static HTML page with the content of the TWikiRegistration topic. You might need to disable {Register}{NeedVerification}, or create a static HTML page of the confirm registration page, and patch the e-mail template to point to the static confirm registration page.

-- Peter Thoeny - 2015-02-17

Thanks Peter, that's helpful (but see below). According to the documentation (TWikiAccessControl), TWikiRegistrationAgent needs ALLOWWEBCHANGE on Main, not ALLOWTOPICVIEW (so either there's a typo above or in the doco).

I now have a different problem: I can't display the TWikiRegistration page to unauthenticated users. If I click on the TWikiRegistration link in the "Please enter your username and password" box, it redisplays that same box. Once authenticated, I can get to the TWikiRegistration page. I have removed all ALLOWWEB* and DENYWEB* settings for TWiki and Main, but this issue persists. Is there a debug technique to find out why TWiki thinks it shouldn't display the TWikiRegistration page?

-- Keith Edmunds - 2015-02-26

Yes, the TWikiRegistrationAgent is needed in ALLOWWEBCHANGE in the Main web.

Make sure that the Main.TWikiPreferences and TWiki.TWikiPreferences do not have any view restriction.

-- Peter Thoeny - 2015-02-27

Closing this question after more than 30 days of inactivity. Feel free to reopen if needed. Consider engaging one of the TWiki consultants if you need timely help. We invite you to get involved with the community, it is more likely you get community support if you support the open source project!

-- Peter Thoeny - 2015-12-03

      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 Answered
Title Restricting access to all webs but allow user registration
SupportCategory CategoryAccessControl
TWiki version 6.0.0
Server OS Debian Linux 7.8
Web server Apache 2.2.22
Perl version 5.14.2
Browser & version Google Chrome 40.0.2214.111 (64-bit)
Edit | Attach | Watch | Print version | History: r6 < r5 < r4 < r3 < r2 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r6 - 2015-12-03 - PeterThoeny
 
  • 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-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.