Require all denied don't work


Hello Lucee Community

We use Lucee latest release with apache 2.4

now i can’t whitelist some ip’s over .htaccess i tryed it with “require all denied” and with “Order Allow,Deny”
but it dosen’t work for .cfm/cfc files. (if i add a .jpg to the folder, the jpg is blocked) but .cfm / .cfc files are still reachable. Same issue if i add “requiere all denied” to the apache conf.

Someone has a fix for this problem?

Thank you


Mod_JK and Mod_Proxy roughly do the same thing, which is they take a listener at the localhost and match them up with session requests from Apache.

Either one of these directives only see ColdFusion running at the local system.

You could in ColdFusion check the remote IP and take action
You could firewall all systems out except those that are whitelisted


i supposed some like this. okay thank you. then we will handle it with CFM.


If you using mod_proxy you can:

<proxy *>
  Order Deny,Allow
  Deny from all
  Allow from


hey david thank you.

this is working!

but is it possible to do this for a specific folder? or multiple folders. Thanks!


Mhh i dont know.
I checked the docs and this should be possible:

<Proxy "*">

If that dont work, you can try to put a location-block around it.


hmm don’t work for me

lucee need this entry i guess:

<Proxy *>

if i wrap a <directory> outside or inside i get a apache error on start.

if i add a second entry. like:

<Proxy *>
<proxy /folder/xyz>
  Order Deny,Allow
  Deny from all
  Allow from

nothing happend.


Your doing this in a server-context or a vhost?
I guess if you are in the server-context, you have to add the domain like the example above.


i tryed with url and local path.


Ah got it. Use ProxyMatch instead of Proxy :slight_smile:

<ProxyMatch /folder/>
    Order Deny,Allow
    Deny from all
    Allow from


after the

<Proxy *>



What excatly you want to do?

If you just want to whitelist a folder and nothing else, you just have to use the proxymatch-directive without the proxy-directive.


i want allow from all, for my entry /project/ folder.
but for one specific folder “/project/xyz/system/”
i want deny all and whistelist some ip’s


Than you just have to do:

<ProxyMatch /project/xyz/system/>
    Order Deny,Allow
    Deny from all
    Allow from

You dont have to use the proxy-directive in this case.
But i have set this in the vhost and not in the server-context.


i tryed to use this in the vhost, i get an apache error. Can’t start the server. did ProxyMatch not require regex?


Yes it uses regex and it should work.
Its working fine for me.

Can you show me the vhost.conf?
What does apache says on startup, you should be able to see the error why its not starting.


i added a * at the end, now it works fine!! Thank you man you are the hero of the day :smiley:


No Problem :slight_smile:
I am glad that i could help you.