1

I want to disable every form of scripting (PHP, ASP.NET, CGI) for a specific vhost in my Apache2 setup. Only plain old HTML pages.

Scripting must remain enabled for all other vhosts in the server.

It's not a security concern, it's a commercial concern (customer pays less for hosting)

Is it possible and how can I do that?

[Edit] From what I've found around the web, I'm going to try the following

RemoveHandler .php .phtml .php3
RemoveType .php .phtml .php3
RemoveHandler .aspx .ascx .ashx .asmx .asax .soap .rem axd .cs .vb .master .sitemap .resources. skin .browser .webinfo $
RemoveType .aspx .ascx .ashx .asmx .asax .soap .rem axd .cs .vb .master .sitemap .resources. skin .browser .webinfo .re$
php_flag engine off

This selectively disables PHP and .NET which are the only scripting runtimes installed

usr-local-ΕΨΗΕΛΩΝ
  • 2,359
  • 7
  • 34
  • 52

1 Answers1

0

Try SetHandler default-handler in the vhosts in question.

Compare: Apache Handler documentation.

Alexander Janssen
  • 2,607
  • 16
  • 21