summaryrefslogtreecommitdiffstats
path: root/server
diff options
context:
space:
mode:
authorAndré Malo <nd@apache.org>2004-04-10 23:44:43 +0200
committerAndré Malo <nd@apache.org>2004-04-10 23:44:43 +0200
commit74fa214f4d2225895ce139628d9be65e421aa4f0 (patch)
tree23f58aa29c8188020f987d1671a018e3fc02d180 /server
parentfix cache confusion which happens if different virtualhosts define (diff)
downloadapache2-74fa214f4d2225895ce139628d9be65e421aa4f0.tar.xz
apache2-74fa214f4d2225895ce139628d9be65e421aa4f0.zip
accept URLs as ServerAdmin contact. If it's not recognized as an URL, assume
an email address and prepend it with mailto: in server outputs. PR: 28174 git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@103339 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'server')
-rw-r--r--server/core.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/server/core.c b/server/core.c
index ff1b1afaef..36641189ef 100644
--- a/server/core.c
+++ b/server/core.c
@@ -2322,8 +2322,10 @@ AP_DECLARE(const char *) ap_psignature(const char *prefix, request_rec *r)
if (conf->server_signature == srv_sig_withmail) {
return apr_pstrcat(r->pool, prefix, "<address>",
ap_get_server_version(),
- " Server at <a href=\"mailto:",
- r->server->server_admin, "\">",
+ " Server at <a href=\"",
+ ap_is_url(r->server->server_admin) ? "" : "mailto:",
+ ap_escape_html(r->pool, r->server->server_admin),
+ "\">",
ap_escape_html(r->pool, ap_get_server_name(r)),
"</a> Port ", sport,
"</address>\n", NULL);