-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

> On Fri, Oct 15, 2010 at 05:19:36AM -0600, [email protected] wrote:
> > 
> > fat...@nikko:~$ ls -l ~/http/fossils/
<snipped... and rearranged a little>
> > -rwxr-xr-x 1 fatman fatman      70 2010-10-12 23:57 vprint.cgi
> > -rw-rw-r-- 1 fatman www-data 67584 2010-10-12 23:58 vprint.fossil
> > fat...@nikko:~$
> 
> If you serve with a CGI not having root access, I imagine you won't
> be able to "give" the group ownership to www-data. So I imagine you
> made a root-trick to get that www-data in the group ownership.

Actually no. It's my server, so I have root. :) You're right though, I
had not considered this from the point of view of a user without root
access. Don't many online *nix hosts give root access to a virtual
machine these days?

> int main()
> {
>       return execl("/path/to/fossil",
>                       "/path/to/fossil",
>                       "cgi",
>                       "rss.ref");
> }

- From what Richard told me, I believe you can remove the "cgi" keyword.
Adding "cgi" actually caused me problems. AFAICT, to get web pages
out of Fossil you just have to feed the string
"repository: /home/viric/fossil/rss.fossil" into its standard input
somehow, which is exactly what my script and your C program do.

> Setuid does not work on scripts (#!...), that's why I had to compile
> the C program.

Ah, I was wondering if you could do this with a script.

> I hope this information is useful for someone wanting the CGI serving
> without having root access in the web server.

Should be a great benefit. Perhaps Richard could put this into the FAQ?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)

iEYEARECAAYFAky8DooACgkQSUH6dLOqvqlLfACeIiLmMr17MyQ4rHOAXnrJ8k9m
JlUAni5PkccXxi+ZXFQZ8hQIWon70f40
=vka7
-----END PGP SIGNATURE-----
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to