CodeIgniter Forums

Full Version: Possible to use mod_auth to protect a mod_rewrite directory?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

Generally you can drop and .htaccess file into a directory to protect that directory with additional security.

I'd like to do that with codeigniter. The problem is, the directories don't exist, they are mod_rewrites, so for example:

/admin/ is really:


For peace of mind, I want 2 levels of login. Apache mod_auth and then the current CI authorization I have. Reason being, if someone screws up and forgets to check for the session in the code and it goes unnoticed I'm hosed. This will at least prevent that for now

El Forum

Putting authentification on mod_rewrite is a bad idea. Except for a serious specific reasons, use some proper redirection instead mod_auth!