Thread: Re: AW: AW: [cgiwrap-users] RE: #!/usr/bin/php
Brought to you by:
nneul
From: Nathan N. <nn...@um...> - 2002-08-09 22:06:37
|
On Fri, 2002-08-09 at 16:55, Daniel Nolte wrote: > Hi, > > >If you can run it using: > >http://host/cgi-bin/cgiwrap/user/script > >then cgiwrap is working fine. > > http://phpmagic.de/cgi-bin/cgiwrap/cgiwrapd/k060881/phpmagic.de/test.php Have you tried that without the action/etc. rules that are not functioning properly? If so, it should work. Wait.. Why do you have cgiwrap/cgiwrapd in that link? That makes no sense. > no output of the script > if I remove the path to the domain (phpmagic.de) and place the script > into > one dir below - it works .. > > >It is a problem with the hack you are using to make cgiwrap behave like > >suexec. What you are using it not sufficient for getting the script to > >execute properly, since you are not passing the proper information to > >cgiwrap to allow it to locate the script. > > > *sigh* What are the proper informations ?:) > > bye > daniel > -- ------------------------------------------------------------ Nathan Neulinger EMail: nn...@um... University of Missouri - Rolla Phone: (573) 341-4841 Computing Services Fax: (573) 341-4216 |
From: Neulinger, N. <nn...@um...> - 2002-08-14 13:52:37
|
> You write that there is no php output. But you did not provide > in the mail the lines: >=20 > Output of script follows: > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D >=20 > Is there anything after that in yout html output, > and do you get any output, if you run: > /usr/bin/php4=20 > /var/chroot/_nossh/k060881/./htdocs/phpmagic.de/test.php > from the command line? Piotr, you probably missed part of the discussion, or I forgot to cc to list, but I had a segv in the test code for a bit, that's why no output. Current cvs is fixed. -- Nathan |
From: Jeff B. <soi...@sg...> - 2002-08-28 19:10:19
|
hello all, is there any documention for how to construct the FILE and what --with-rewrite does exactly? Jeff |
From: Daniel N. <dr...@gm...> - 2002-08-09 22:18:20
|
On Fri, 2002-08-09 at 16:55, Daniel Nolte wrote: > Hi, > > >If you can run it using: > >http://host/cgi-bin/cgiwrap/user/script > >then cgiwrap is working fine. > > http://phpmagic.de/cgi-bin/cgiwrap/cgiwrapd/k060881/phpmagic.de/test.php > Have you tried that without the action/etc. rules that are not > functioning properly? If so, it should work. Yeap, tried it. I just get no php output only: Initializing Logging Redirecting STDERR to STDOUT Setting SIGXCPU to default behaviour Environment Variables: QUERY_STRING: '' SCRIPT_NAME: '/cgi-bin/cgiwrap/cgiwrapd' SCRIPT_FILENAME: '/usr/lib/cgi-bin/cgiwrap/cgiwrapd' PATH_INFO: '/k060881/htdocs/phpmagic.de/test.php' PATH_TRANSLATED: '/var/chroot/_nossh/k060881/htdocs/phpmagic.de/k060881/htdocs/phpmagic.d e/test.php' REMOTE_USER: '<NULL>' REMOTE_HOST: '<NULL>' REMOTE_ADDR: '80.142.156.229' Trying to extract user from PATH_INFO. Retrieved User Name: 'k060881' User Data Retrieved: UserID: 'k060881' UID: '1004' GID: '2000' Home Dir: '/var/chroot/_nossh/k060881' Script Base Directory: '/var/chroot/_nossh/k060881/.' Fetching script string Trying to extract script from PATH_INFO Extracted PATH_INFO 'htdocs/phpmagic.de/test.php' Building script path Condensing slashes. Script Relative Path: 'htdocs/phpmagic.de/test.php' Script Absolute Path: '/var/chroot/_nossh/k060881/./htdocs/phpmagic.de/test.php' Checking for special interpreted script (php). Interpreter Path: '/usr/bin/php4' Fixing Environment Variables. Environment Variables: QUERY_STRING: '' SCRIPT_NAME: '/cgi-bin/cgiwrap/cgiwrapd/k060881/htdocs/phpmagic.de/test.php' SCRIPT_FILENAME: '/var/chroot/_nossh/k060881/./htdocs/phpmagic.de/test.php' PATH_INFO: '' PATH_TRANSLATED: '/var/chroot/_nossh/k060881/htdocs/phpmagic.de' REMOTE_USER: '<NULL>' REMOTE_HOST: '<NULL>' REMOTE_ADDR: '80.142.156.229' Wait.. Why do you have cgiwrap/cgiwrapd in that link? That makes no sense. cgiwrap is a subdir in cgi-bin/ luna:/usr/lib/cgi-bin# ls -al total 16 drwxr-xr-x 3 root root 4096 Aug 9 16:52 . drwxr-xr-x 32 root root 8192 Aug 9 02:51 .. drwxr-xr-x 2 root root 4096 Aug 10 00:14 cgiwrap luna:/usr/lib/cgi-bin/cgiwrap# ls -al total 536 drwxr-xr-x 2 root root 4096 Aug 10 00:14 . drwxr-xr-x 3 root root 4096 Aug 9 16:52 .. -rwsr-xr-x 6 root root 83676 Aug 10 00:14 cgiwrap -rwsr-xr-x 6 root root 83676 Aug 10 00:14 cgiwrapd -rwsr-xr-x 6 root root 83676 Aug 10 00:14 nph-cgiwrap -rwsr-xr-x 6 root root 83676 Aug 10 00:14 nph-cgiwrapd -rwsr-xr-x 6 root root 83676 Aug 10 00:14 php-cgiwrap -rwsr-xr-x 6 root root 83676 Aug 10 00:14 php-cgiwrapd |
From: Nathan N. <nn...@um...> - 2002-08-09 23:09:44
|
Do you have php build with --enable-discard-path? On Fri, 2002-08-09 at 17:18, Daniel Nolte wrote: > On Fri, 2002-08-09 at 16:55, Daniel Nolte wrote: > > Hi, > > > > >If you can run it using: > > >http://host/cgi-bin/cgiwrap/user/script > > >then cgiwrap is working fine. > > > > > http://phpmagic.de/cgi-bin/cgiwrap/cgiwrapd/k060881/phpmagic.de/test.php > > > Have you tried that without the action/etc. rules that are not > > functioning properly? If so, it should work. > Yeap, tried it. I just get no php output only: > > Initializing Logging > Redirecting STDERR to STDOUT > > Setting SIGXCPU to default behaviour > > > Environment Variables: > QUERY_STRING: '' > SCRIPT_NAME: '/cgi-bin/cgiwrap/cgiwrapd' > SCRIPT_FILENAME: '/usr/lib/cgi-bin/cgiwrap/cgiwrapd' > PATH_INFO: '/k060881/htdocs/phpmagic.de/test.php' > PATH_TRANSLATED: > '/var/chroot/_nossh/k060881/htdocs/phpmagic.de/k060881/htdocs/phpmagic.d > e/test.php' > REMOTE_USER: '<NULL>' > REMOTE_HOST: '<NULL>' > REMOTE_ADDR: '80.142.156.229' > > > Trying to extract user from PATH_INFO. > Retrieved User Name: 'k060881' > > User Data Retrieved: > UserID: 'k060881' > UID: '1004' > GID: '2000' > Home Dir: '/var/chroot/_nossh/k060881' > > Script Base Directory: '/var/chroot/_nossh/k060881/.' > Fetching script string > > Trying to extract script from PATH_INFO > Extracted PATH_INFO 'htdocs/phpmagic.de/test.php' > Building script path > > Condensing slashes. > > Script Relative Path: 'htdocs/phpmagic.de/test.php' > Script Absolute Path: > '/var/chroot/_nossh/k060881/./htdocs/phpmagic.de/test.php' > Checking for special interpreted script (php). > Interpreter Path: '/usr/bin/php4' > > Fixing Environment Variables. > > Environment Variables: > QUERY_STRING: '' > SCRIPT_NAME: > '/cgi-bin/cgiwrap/cgiwrapd/k060881/htdocs/phpmagic.de/test.php' > SCRIPT_FILENAME: > '/var/chroot/_nossh/k060881/./htdocs/phpmagic.de/test.php' > PATH_INFO: '' > PATH_TRANSLATED: '/var/chroot/_nossh/k060881/htdocs/phpmagic.de' > REMOTE_USER: '<NULL>' > REMOTE_HOST: '<NULL>' > REMOTE_ADDR: '80.142.156.229' > > > > Wait.. Why do you have cgiwrap/cgiwrapd in that link? That makes no > sense. > > cgiwrap is a subdir in cgi-bin/ > > luna:/usr/lib/cgi-bin# ls -al > total 16 > drwxr-xr-x 3 root root 4096 Aug 9 16:52 . > drwxr-xr-x 32 root root 8192 Aug 9 02:51 .. > drwxr-xr-x 2 root root 4096 Aug 10 00:14 cgiwrap > > luna:/usr/lib/cgi-bin/cgiwrap# ls -al > total 536 > drwxr-xr-x 2 root root 4096 Aug 10 00:14 . > drwxr-xr-x 3 root root 4096 Aug 9 16:52 .. > -rwsr-xr-x 6 root root 83676 Aug 10 00:14 cgiwrap > -rwsr-xr-x 6 root root 83676 Aug 10 00:14 cgiwrapd > -rwsr-xr-x 6 root root 83676 Aug 10 00:14 nph-cgiwrap > -rwsr-xr-x 6 root root 83676 Aug 10 00:14 nph-cgiwrapd > -rwsr-xr-x 6 root root 83676 Aug 10 00:14 php-cgiwrap > -rwsr-xr-x 6 root root 83676 Aug 10 00:14 php-cgiwrapd -- ------------------------------------------------------------ Nathan Neulinger EMail: nn...@um... University of Missouri - Rolla Phone: (573) 341-4841 Computing Services Fax: (573) 341-4216 |
From: Daniel N. <dr...@gm...> - 2002-08-09 23:56:14
|
Hi > Do you have php build with --enable-discard-path? Tried it now with and without :)( same result. Any other ideas? *sigh* Thanks again for the help Bye Daniel |
From: Piotr K. <ma...@ma...> - 2002-08-14 08:40:22
|
Hi, I'd like to get into the discussion. If your URL looks like: On Sat, Aug 10, 2002 at 12:18:01AM +0200, Daniel Nolte wrote: > http://phpmagic.de/cgi-bin/cgiwrap/cgiwrapd/k060881/phpmagic.de/test.php then why the PATH_INFO is /k060881/htdocs/phpmagic.de/test.php Why there is 'htdocs' in it? Maybe the your URL originally was: http://phpmagic.de/cgi-bin/cgiwrap/cgiwrapd/k060881/htdocs/phpmagic.de/test.php ? > Environment Variables: > QUERY_STRING: '' > SCRIPT_NAME: '/cgi-bin/cgiwrap/cgiwrapd' > SCRIPT_FILENAME: '/usr/lib/cgi-bin/cgiwrap/cgiwrapd' > PATH_INFO: '/k060881/htdocs/phpmagic.de/test.php' > PATH_TRANSLATED: > '/var/chroot/_nossh/k060881/htdocs/phpmagic.de/k060881/htdocs/phpmagic.d > e/test.php' > REMOTE_USER: '<NULL>' > REMOTE_HOST: '<NULL>' > REMOTE_ADDR: '80.142.156.229' > Script Base Directory: '/var/chroot/_nossh/k060881/.' It seems that your cgi-dir here is now '.' We should make it running as before (htdocs in your case, WWW in my case, and public_html in common cases). But '.' should work now, too. > Script Absolute Path: > '/var/chroot/_nossh/k060881/./htdocs/phpmagic.de/test.php' > Checking for special interpreted script (php). > SCRIPT_FILENAME: > '/var/chroot/_nossh/k060881/./htdocs/phpmagic.de/test.php' You write that there is no php output. But you did not provide in the mail the lines: Output of script follows: ===================================================== Is there anything after that in yout html output, and do you get any output, if you run: /usr/bin/php4 /var/chroot/_nossh/k060881/./htdocs/phpmagic.de/test.php from the command line? -- Piotr Klaban |