Welcome Guest, Not a member yet? Register   Sign In
Keeping People from Accessing Controller Methods
#3

[eluser]cornofstarch[/eluser]
I don't want to make the method private as it will create a whole new set of problems down the road.

To clarify, I've read the slew of forum posts where people have the same problem. I don't want to make the method private, protected or private from CI's view using the underscore. I don't want to route everything with catchall (:any), I don't need to separate the methods from logged in or not logged in views with a Public_Controller or an Admin_Controller of my own. I'm not using POST for every method nor do I want to check POST for every method.

Is the only other way of controlling access is to use htaccess? This is Pyro's htaccess and I haven't a clue as to what it does:

Code:
<IfModule mod_rewrite.c>

    # Make sure directory listing is disabled
    Options +FollowSymLinks -Indexes
    RewriteEngine on

    # Keep people out of codeigniter directory and Git/Mercurial data
    RedirectMatch 403 ^/(system\/pyrocms\/cache|system\/codeigniter|\.git|\.hg).*$

    # Send request via index.php (again, not if its a real file or folder)
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d

    <IfModule mod_php5.c>
        RewriteRule ^(.*)$ index.php/$1 [L]
    </IfModule>

    <IfModule !mod_php5.c>
        RewriteRule ^(.*)$ index.php?/$1 [L]
    </IfModule>

</IfModule>

I know it's probably better to ask on Pyro forums but sadly, it appears to be a dead or dying forum. Maybe everyone is on IRC...


Messages In This Thread
Keeping People from Accessing Controller Methods - by El Forum - 01-23-2011, 01:01 PM
Keeping People from Accessing Controller Methods - by El Forum - 01-23-2011, 01:36 PM
Keeping People from Accessing Controller Methods - by El Forum - 01-23-2011, 02:16 PM
Keeping People from Accessing Controller Methods - by El Forum - 01-23-2011, 07:12 PM
Keeping People from Accessing Controller Methods - by El Forum - 01-24-2011, 01:20 AM
Keeping People from Accessing Controller Methods - by El Forum - 01-24-2011, 02:41 AM



Theme © iAndrew 2016 - Forum software by © MyBB