Results 1 to 4 of 4
-
11-24-2004, 05:40 AM #1Junior Guru Wannabe
- Join Date
- Oct 2004
- Location
- Farmington, UT
- Posts
- 42
Serve a page without a webserver, using a port number?
I'm interested in serving one page on my server without having to run a webserver. How would I make it so someone can access the one page by going to http://123.456.78.90:1234? Is there some sort of program I can use to do this or is a webserver a must?
Also, does anyone know how Webmin is authenticating users without MySQL on the server? I'd like to do something like that. Webmin uses port 10000 so I access it using http://123.456.78.90:10000, the same way I'd like to serve my one page to the public.
Thanks
Last edited by DOS|Proton; 11-24-2004 at 05:45 AM.
-
11-24-2004, 06:07 AM #2Web Hosting Master
- Join Date
- Jul 2002
- Location
- Manchester, UK
- Posts
- 779
Re: Serve a page without a webserver, using a port number?
Originally posted by DOS|Proton
I'm interested in serving one page on my server without having to run a webserver. How would I make it so someone can access the one page by going to http://123.456.78.90:1234? Is there some sort of program I can use to do this or is a webserver a must?
Also, does anyone know how Webmin is authenticating users without MySQL on the server? I'd like to do something like that. Webmin uses port 10000 so I access it using http://123.456.78.90:10000, the same way I'd like to serve my one page to the public.
Thanks
As for Webmin, it uses PAM authentication, which allows it to authenticate users as normal unix users (i.e. against /etc/shadow, or /etc/passwd on older systems). I'm pretty sure there's PAM modules available for Perl. Webmin itself is written entirely in Perl so it's certainly possible to create pretty sophisticated server programs in it.
-
11-24-2004, 06:16 AM #3Junior Guru Wannabe
- Join Date
- Oct 2004
- Location
- Farmington, UT
- Posts
- 42
Ah, thanks for the prompt reply. Do you know of any pre-made scripts that do something similar to that, preferably Perl? I'm not good enough to write a Perl program but I'm capable of interpreting and adding on/editing already made scripts. If not, do you know if Apache would take up alot of resources? I woldn't mind running a webserver but I'm just worried that even if it's only serving one page, that it would take up a considerably large amount of cpu & memory for my likings.
-
11-24-2004, 07:20 AM #4Web Hosting Evangelist
- Join Date
- Mar 2004
- Location
- New Zealand
- Posts
- 532
Re: Serve a page without a webserver, using a port number?
Any time you serve anything to a web browser you are by definition using a web server.
Webmin has it's own built in web server.
What I think you mean is, "is there a very very simple webserver I can use to serve one static page of content over a given port?".
Well, aside from writing your own (all you need do is accept connections and respond to a GET request with the appropriate headers and content), you could look at something like http://www.acme.com/software/thttpd/