1

I'm running IIS7 and I have fastCGI installed and php code works just fine normally.

Today I added a php file that contained only code an no html to the bin directory. And when I try to access it via http, i get a 404 back.

I've verified the file is on the server, and I've verified that the problem goes away if I move the file out of the bin directory.

My question is why does the bin directory hide php files? (and html files too, incidentally.) Is it some IIS security precaution? If so, what's the risk?

thanks.

robertpateii
  • 113
  • 3

2 Answers2

0

404 means IIS couldn't find the file.

To get more specific information I would look at the IIS error log. See iis 7 log file directory

RedGrittyBrick
  • 3,832
  • 1
  • 17
  • 23
0

The /bin directory is normally protected by IIS by default (well, not by IIS, but by ASP.NET technically). This is done because ASP.NET apps store their dlls in that folder.

Here's a post with some more details and a workaround:

http://www.eggheadcafe.com/software/aspnet/30510465/iis-60-generating-4041-error-for-bin-subdirectory.aspx

Eric Petroelje
  • 771
  • 6
  • 12
  • thanks. that makes sense. dlls are only used on the server side so why expose it to the web and let people download your dlls willy nilly. – robertpateii Oct 14 '10 at 21:28