FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum Development » Plugins and Code Hacks » Deny Anonymous Access
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
icon1.gif  Deny Anonymous Access [message #21113] Sun, 14 November 2004 22:27 Go to next message
robb is currently offline  robb   United States
Messages: 3
Registered: November 2004
Karma: 0
Junior Member
While evaluating forum software I found FUD! YEA! To make it fit the needs of my client I needed to disable anonymous logins. My solution follows. Please forgive the PHP coding and FUDforum hacking as my total PHP/FUDforum programing experience is now 4 hours (5 years of Perl so that helps).

Once the 'Deny Anonymous Access' setting in the GLobal Administration section is set to yes all accesses to FUDforum will genertae the default login screen (as if the user clicked on login) until a sucessful login is completed.

The changes are being uploaded in patch style, hope that works for all.

Some notes:

Mostly untested. I made these changes to demonstrate FUDforum's capabilities and lack the time to fully test the patches. Use at your own risk!

I used $FUD_OPT_4 for my bit flag to avoid stomping on other options (although at this time FUD_OPT_3, 512 appears available). This requires you to add '$FUD_OPT_4 = 0;' to your GLOBALS.php otherwise things will not work properly.

My data volume is in ./data (not the best place but a requirement for my testing). If your data/ is located elsewher erelative to FUDforum you may need to edit the patch file.

If you are uncomfortable applying patches please find someone hat is familiar with this process to help you.

3 files are modified
- GLOBALS.php (manual edit needed, see below!!)
- data/include/GLOBALS_HELP
- adm/admglobal.php
- data/src/users.inc.t

Steps to apply patch
- BACKUP current installation. I do not take repsonsible for any havic caused by these changes.
- Edit GLOBALS.php and add the line
$FUD_OPT_4 = 0;
- Save the patch file someplace
- Execute the following from the FUDforum directory, requires a Linux or Linux like system
- patch -p1 < {path-to-file}/deny-anoymous-user.txt
- Log in as administrator
- Select admin functions
- Scroll down to General and set the Deny Anonymous User flag appropiatly, defualt is NO
- Save changes
- After modifications all themes must be rebuilt with the theme manager.

Alternative method
- Examine patch file and make code changes manually. Be very sure to use TABS in the GLOBALS_HELP file as spaces will case no end of grief.

(I really hope someone else has not already done this, but I could not find any such modification on the board).

[Updated on: Mon, 15 November 2004 00:35]

Report message to a moderator

Re: Deny Anonymous Access [message #21125 is a reply to message #21113] Mon, 15 November 2004 20:41 Go to previous messageGo to next message
Abraxa is currently offline  Abraxa   Germany
Messages: 72
Registered: August 2004
Location: Germany
Karma: 0
Member
Quote:

To make it fit the needs of my client I needed to disable anonymous logins.


Personally I'm a little confused as about what you mean with "anonymous logins". If you mean that no one else should be able to see/use the forums but registered and validated members then I'd think it would've been easier to just enforce the validation of accounts by the administrator and use the the group manager to remove anonymous access rights from all forums. Smile

-Abraxa
Re: Deny Anonymous Access [message #21126 is a reply to message #21125] Mon, 15 November 2004 20:52 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
I think what the purpose of the change was that instead of showing an "empty" front page anon users will be automatically sent to the login page.

FUDforum Core Developer
Re: Deny Anonymous Access [message #21128 is a reply to message #21126] Mon, 15 November 2004 21:30 Go to previous messageGo to next message
robb is currently offline  robb   United States
Messages: 3
Registered: November 2004
Karma: 0
Junior Member
In this particular installation it was important to demonstrate that no private data leaked and to make it very obvious that a login was required.

The other problem was in securing forums properly. It took me a while to get the hang of group management and I am working on a tutorial that covers my particular circumstances. I will try and upload soon.
Re: Deny Anonymous Access - UPDATE 2004-11-17 [message #21169 is a reply to message #21113] Thu, 18 November 2004 00:50 Go to previous messageGo to next message
robb is currently offline  robb   United States
Messages: 3
Registered: November 2004
Karma: 0
Junior Member
Attached is an updated patch file. This one fixes a bug that prevented RESETing of a password. Basically it just extended the exception checking to include 'reset' in the users.inc.t file.

Sorry if that mucked anyone up.

Note that the patch adds another option tot he Global configuration allowing you to enable/disable Deny Anonymous for a forum easily.


[Updated on: Thu, 18 November 2004 00:50]

Report message to a moderator

Re: Deny Anonymous Access [message #22433 is a reply to message #21113] Thu, 03 February 2005 14:19 Go to previous message
filo is currently offline  filo   Poland
Messages: 5
Registered: February 2005
Location: Poznan/Poland
Karma: 0
Junior Member

This hack lacks allowing registration.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Email Participation patch
Next Topic: FudForum & PHPList
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Dec 22 03:29:28 GMT 2024

Total time taken to generate the page: 0.02351 seconds