0

I tried to create an alias or virtual host to run as different user. Well below is part of apache httpd.conf that doesn't work. Or, is it even possible?

<VirtualHost blah:80>

    user DifferentUser
    group DifferentGroup

    ServerAdmin blah
    DocumentRoot blah
    ServerName blah
    ServerAlias blah
    ScriptAlias /cgi-bin/ blah
    DirectoryIndex index.html index.htm default.htm index.shtml index.php
    ErrorLog logs/blah-error_log
    CustomLog logs/blah-access_log common
    <Directory "/blah/">
      Options Indexes FollowSymLinks MultiViews ExecCGI
      AllowOverride all
      Order Deny,Allow
      Deny from none
      Allow from all
    </Directory>
</VirtualHost>
checksum
  • 1,015
  • 1
  • 11
  • 15

2 Answers2

5

You may be able to utilise the mpm-itk module which is available for some Linux distros. Failing that you can usee other technologies for privilege separation e.g. suPHP or some other things here.

user9517
  • 115,471
  • 20
  • 215
  • 297
1

It's not possible. User and group directives can be set only in server context.