SuEXEC patch to work FastCGI with PHP

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Adam Szendzielorz

    #1

    SuEXEC patch to work FastCGI with PHP

    Hello!

    I'm searching patch for Apache SuEXEC (1.3.*) which get me gate to work PHP
    (compiled with --enable-fastcgi) with mod_fastcgi. SuEXEC check owner/group
    of script before run script, i don't want this! I have this configuration:

    httpd.conf:

    [...]
    LoadModule fastcgi_module libexec/mod_fastcgi.so
    [...]
    FastCgiWrapper /usr/local/apache/bin/suexec
    FastCgiServer /usr/local/apache/php/php -user www -group www
    AddHandler php-fastcgi .php
    <Location /f-php-cgi/php>
    SetHandler fastcgi-script
    </Location>
    Action php-fastcgi /f-php-cgi/php
    AddType application/x-httpd-php .php
    Alias /f-php-cgi /usr/local/apache/php
    [...]


    script: /usr/local/apache/php/php is:

    #!/bin/sh
    PHPRC="/usr/local/lib/php.ini"
    export PHPRC
    PHP_FCGI_CHILDR EN=4
    export PHP_FCGI_CHILDR EN
    exec /usr/local/bin/php

    (script and his parent directory are owned by www/www).

    I want to run php scripts with rights of user which are set (User and
    Groups) in virtualhost using FastCGI.

    Can You help me ?:)
    Thank You.
    Best regards.

    --
    Adam Szendzielorz
  • Adam Szendzielorz

    #2
    Re: SuEXEC patch to work FastCGI with PHP

    Adam Szendzielorz <adam@nospam-konta.nospam.pl > wrote in
    news:Xns95D5D4C 7EE3BBadamnospa mkontapl@193.11 0.122.97:
    [color=blue]
    > I want to run php scripts with rights of user which are set (User and
    > Groups) in virtualhost using FastCGI.[/color]

    OK I now got it - run perfectly:))
    Best regards!!

    --
    Adam Szendzielorz

    Comment

    Working...