User avatar
redhawk
Posts: 3465
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1

Need basic web server SSL and password support??

Sun Jul 22, 2012 8:59 pm

I want to setup a web server on my PI I could install Apache but I want something small and less complicated and easy on the RAM to play with.
My only other 2 requirements are that it supports SSL (https) communications and has password authentication to prevent unauthorised snooping.
I found a program called thttpd which looked very promising unfortunately I cannot install it with "apt-get install thttpd" because it appears there are only i386 binaries available for download.
I might end up having to compile this myself (I hate doing this because nearly something always goes wrong) however in the meantime could anyone recommend me an alternative??

Richard S.

Julian
Posts: 15
Joined: Fri Jun 29, 2012 9:24 am

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 9:06 pm

I heard lighttpd is a good alternative to apache (I have never used it tough). It has SSL and htaccess support and it is in the official debian wheezy repository so it should also be in the raspbian repository. You could also try nginx.

User avatar
redhawk
Posts: 3465
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 9:11 pm

just as I feared: :cry:
htpasswd.c:52:12: error: conflicting types for âgetlineâ
/usr/include/stdio.h:671:20: note: previous declaration of âgetlineâ was here
make[1]: *** [htpasswd.o] Error 1
make[1]: Leaving directory `/root/thttpd-2.25b/extras'
make: *** [subdirs] Error 2

Richard S.

chrisw2
Posts: 106
Joined: Sat Apr 07, 2012 11:22 am
Location: Manchester, UK

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 9:19 pm

Hi Richard,

You might have better luck trying to build a debian package "the smart way" see:

HowTo Build a Package from Source the Smart Way - http://forums.debian.net/viewtopic.php?f=16&t=38976

I recently built a dhttpd debian package this way.

User avatar
Jim JKla
Posts: 2218
Joined: Sun Jan 29, 2012 11:15 pm
Location: Newcastle upon Tyne UK

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 10:01 pm

Or of course you could use Apache2 it does work. ;)
Noob is not derogatory the noob is just the lower end of the noob--geek spectrum being a noob is just your first step towards being an uber-geek ;)

If you find a solution please post it in the wiki the forum dies too quick

frak
Posts: 17
Joined: Sun Jul 22, 2012 9:33 pm

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 10:19 pm

What specific issues are you having with Apache that is forcing you to try another web server? You can reduce memory requirements a lot by disabling unneeded modules...

User avatar
redhawk
Posts: 3465
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 10:20 pm

I've found a .deb package complied for Ubuntu armhf, interestingly it installs and runs on the the PI - https://launchpad.net/ubuntu/precise/ar ... d/2.25b-11 :lol:
Not sure why the compiler is having problems compiler errors seems to be a regular occurrence for me and Linux.

Richard S.

User avatar
redhawk
Posts: 3465
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 10:23 pm

Nothing wrong with apache but it's quite a big package to install, thttpd on the other hand is smaller and fits my criteria for a lightweight compact web server.

Richard S.

frak
Posts: 17
Joined: Sun Jul 22, 2012 9:33 pm

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 10:25 pm

Fair enough, but in 12 years of web development it (Apache) has never done me wrong ;o)

User avatar
redhawk
Posts: 3465
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1

Re: Need basic web server SSL and password support??

Sun Jul 22, 2012 11:23 pm

I've found the fault htpasswd.c needs editing and the function getline renamed to avoid conflicts i.e. get_line and all instances of getline in the this file, after that it compiles.
Unfortunately it doesn't appear to support SSL so I guess I'll be using Apache after all. :roll:

Richard S.

Return to “Raspberry Pi OS”