On Fri, 25 Feb 2000, Patrick Robinson wrote:

> I get a syntax error from "httpd -t" (or "apachectl configtest") when
> I use SSLRequireSSL inside a <Directory>, like this:
>

You have to enable the mod_ssl stuff. Use: httpd -DSSL -t

I have posted a patch to this list some time ago which
adds a -ssl option to apachectl. This allows you to
SSL-ify any apachectl command by using:

apachectl -ssl configtest 
apachectl -ssl start
apachectl -ssl graceful
...

For your convenience, the patch is attached to this reply.
 

> On the other hand, I can start apache (apachectl startssl), and it runs.
> If I try to access http://my.server.name:8443/, I get a "Forbidden, You
> don't have permission to access /mod_ssl:error:HTTP-request on this
> server." (a strange error message, which makes me think something is
> wrong).  I can only access this particular virtual host with https://
> So... other than that strange error message, it all seems to work
> correctly.
> 

This is what you asked for by specifying SSLRequireSSL. If you leave it
out, you will get a "400 Bad Request" and complaints about using HTTP on
a HTTPS port.


Regards,
Stefan

--
90% of all software is crap. That's because 90% of everything is crap.
--- apachectl.orig      Thu Nov 25 16:41:01 1999
+++ apachectl   Thu Nov 25 18:17:58 1999
@@ -39,6 +39,13 @@
 # --------------------                              --------------------
 # ||||||||||||||||||||   END CONFIGURATION SECTION  ||||||||||||||||||||
 
+case $1 in
+-ssl|-SSL|-DSSL)
+    HTTPD="$HTTPD -DSSL"
+    shift
+    ;;
+esac
+
 ERROR=0
 ARGV="$@"
 if [ "x$ARGV" = "x" ] ; then 
@@ -161,11 +168,12 @@
        fi
        ;;
     *)
-       echo "usage: $0 
(start|stop|restart|fullstatus|status|graceful|configtest|help)"
+       echo "usage: $0 [-ssl] 
+(start|stop|restart|fullstatus|status|graceful|configtest|help)"
        cat <<EOF
 
+-ssl       - enable SSL for subsequent command(s)
 start      - start httpd
-startssl   - start httpd with SSL enabled
+startssl   - start httpd with SSL enabled (obsolete)
 stop       - stop httpd
 restart    - restart httpd if running by sending a SIGHUP or start if 
              not running

Reply via email to