Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 266
  • Last Modified:

How can I create a Regex for this DirectoryMatch directive?

Hello all,

I am trying to protect all my coldfusion administrator directories that looks like this: "CFIDE/administrator" in their path.
I thought that using DirectoryMatch with regex.  What would the Regular Expression look like?

<DirectoryMatch CFIDE/administrator>
  #Other directive here...
</DirectoryMatch>

How would I so this.

Thanks,
Troy
0
tdsimpso
Asked:
tdsimpso
  • 2
1 Solution
 
umbraeCommented:
<DirectoryMatch "^/CFIDE/administrator/.*">
[stuff]
</DirectoryMatch>

Would probably work.

-Umbrae
0
 
umbraeCommented:
Addendum: You could probably just as easily accomplish this with a directory tag, of the format:

<Directory /absolute/path/to/CFIDE/administrator>
[stuff]

</Directory>

-Umbrae
0
 
tdsimpsoAuthor Commented:
umbrae,

Thanks for you input.

Troy
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now