summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/examples/httpd.conf4
-rw-r--r--usr.sbin/httpd/httpd.conf.54
-rw-r--r--usr.sbin/httpd/parse.y10
3 files changed, 9 insertions, 9 deletions
diff --git a/etc/examples/httpd.conf b/etc/examples/httpd.conf
index c276797b8be..f8364fd37b9 100644
--- a/etc/examples/httpd.conf
+++ b/etc/examples/httpd.conf
@@ -1,4 +1,4 @@
-# $OpenBSD: httpd.conf,v 1.9 2014/08/05 18:01:10 reyk Exp $
+# $OpenBSD: httpd.conf,v 1.10 2014/08/06 20:29:54 reyk Exp $
#
# Macros
@@ -47,7 +47,7 @@ server "www.example.com" {
# An HTTPS server using SSL/TLS
server "secure.example.com" {
- listen on 127.0.0.1 port 443 ssl
+ listen on 127.0.0.1 ssl port 443
# Define server-specific log files relative to /logs
log { access "secure-access.log", error "secure-error.log" }
diff --git a/usr.sbin/httpd/httpd.conf.5 b/usr.sbin/httpd/httpd.conf.5
index d0c91942a7b..da9730d0b20 100644
--- a/usr.sbin/httpd/httpd.conf.5
+++ b/usr.sbin/httpd/httpd.conf.5
@@ -1,4 +1,4 @@
-.\" $OpenBSD: httpd.conf.5,v 1.28 2014/08/06 18:21:14 reyk Exp $
+.\" $OpenBSD: httpd.conf.5,v 1.29 2014/08/06 20:29:54 reyk Exp $
.\"
.\" Copyright (c) 2014 Reyk Floeter <reyk@openbsd.org>
.\"
@@ -165,7 +165,7 @@ root directory of
.Nm httpd
and defaults to
.Pa /run/slowcgi.sock .
-.It Ic listen on Ar address Ic port Ar number Op Ic ssl
+.It Ic listen on Ar address Oo Ic ssl Oc Ic port Ar number
Set the listen address and port.
.It Ic location Ar path { ... }
Specify server configuration rules for a specific location.
diff --git a/usr.sbin/httpd/parse.y b/usr.sbin/httpd/parse.y
index 532e56a394a..9a1e1221df5 100644
--- a/usr.sbin/httpd/parse.y
+++ b/usr.sbin/httpd/parse.y
@@ -1,4 +1,4 @@
-/* $OpenBSD: parse.y,v 1.33 2014/08/06 18:21:14 reyk Exp $ */
+/* $OpenBSD: parse.y,v 1.34 2014/08/06 20:29:54 reyk Exp $ */
/*
* Copyright (c) 2007 - 2014 Reyk Floeter <reyk@openbsd.org>
@@ -273,7 +273,7 @@ serveropts_l : serveropts_l serveroptsl nl
| serveroptsl optnl
;
-serveroptsl : LISTEN ON STRING port optssl {
+serveroptsl : LISTEN ON STRING optssl port {
struct addresslist al;
struct address *h;
struct server *s;
@@ -290,14 +290,14 @@ serveroptsl : LISTEN ON STRING port optssl {
YYERROR;
} else
s = srv;
- if ($4.op != PF_OP_EQ) {
+ if ($5.op != PF_OP_EQ) {
yyerror("invalid port");
free($3);
YYERROR;
}
TAILQ_INIT(&al);
- if (host($3, &al, 1, &$4, NULL, -1) <= 0) {
+ if (host($3, &al, 1, &$5, NULL, -1) <= 0) {
yyerror("invalid listen ip: %s", $3);
free($3);
YYERROR;
@@ -310,7 +310,7 @@ serveroptsl : LISTEN ON STRING port optssl {
s->srv_conf.prefixlen = h->prefixlen;
host_free(&al);
- if ($5) {
+ if ($4) {
s->srv_conf.flags |= SRVFLAG_SSL;
}
}