- Leave the `view` script non authenticated in the `.htaccess` file.
- Enable the `$doRememberRemoteUser` flag in `wikicfg.pm` as described in [TWiki Authentication](TWikiDocumentation#authentication). %WIKITOOLNAME% will now remember the IP address of an authenticated user.
- Copy the `view` script to `viewauth` (or better, create a symbolic link)
- - Enable authentication for the `viewauth` script in the `.htaccess` file.
+ - Add `viewauth` to the list of authenticated scripts in the .htaccess file.
- When a user accesses a web where you enabled view restriction, %WIKITOOLNAME% will redirect from the `view` script to the `viewauth` script once (this hapens only if the user has never edited a topic). Doing so will ask for authentication. The `viewauth` script shows the requested topic if the user could log on and if the user is authorized to see that web.
- If you enable view restriction for a web, it is recommended to restrict search "all webs" from searching this web. Enable this restriction with the `NOSEARCHALL` variable in its [[WebPreferences]], like:
- Set NOSEARCHALL = on