dotgnu-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[DotGNU]pnet example: ha'comment pre1


From: Stephen Compall
Subject: [DotGNU]pnet example: ha'comment pre1
Date: Wed, 29 Oct 2003 19:54:26 GMT

http://csserver.evansville.edu/~sc87/dotgnu/hacomment-pre1.tar.bz2
GNU/Linux only, sort of (depends on binfmt_misc, sort of)

This is a CGI library for C# and a comment system that uses it.  The
clever bit -- and most useful for me -- is that it changes existing
static pages to add comments, rather than encapsulate the page in a
CGI script itself.  I was originally going to do this for a Scheme
project of mine -- in fact, I wrote a Scheme function that parses both
GET and POST data -- then figured it would be fun for DotGNUers.

The CGI library breaks on POST in pnet-0.6.0 and earlier.  The patch
that fixes it:
http://csserver.evansville.edu/~sc87/dotgnu/pnet-StdRead-retval.patch

This is a prerelease because, though I have tested all the
functionality at the command line, and generating the comment form
through the web server, I have not tested submitting comments through
a web server, thanks to the pnet bug.  I had some problems with
permissions before switching to POST and running into the pnet bug,
which seem to have disappeared at the command line, so I'll see.
Also, there's the whole "doesn't work with current pnet release"
thing.  And finally, some of the documentation was left half-finished
while I got caught up in code, so e.g. the commentary on hacomment.cs
only offers the shallowest analysis of the structure.

There is a very important synchronization bug: Lock currently does
nothing in pnet, and I don't know its behavior anyway.  I need to
acquire an exclusive lock on the static file for its entire run to
avoid clashes with other instances.  I will write about that in my
next mail.

Finally, if you want to torture-test it, try to hack the page on which
you are commenting with JavaScript/VB/wicked HTML/large messages
(which aren't currently checked for)/whatever.  I took the easy way
out and escaped all <>&", but still.  Try to convince it to show you
or modify arbitrary files on the server.

--
Stephen Compall or s11 or sirian

I'd like MY data-base JULIENNED and stir-fried!

nuclear Albania Armani electronic surveillance codes Montenegro
satellite imagery FSF explosion warfare PLO clandestine CDC Audiotel
Elvis


reply via email to

[Prev in Thread] Current Thread [Next in Thread]