summaryrefslogtreecommitdiff
path: root/httpd.c
diff options
context:
space:
mode:
Diffstat (limited to 'httpd.c')
-rw-r--r--httpd.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/httpd.c b/httpd.c
index 0bdd9bc..b956dcb 100644
--- a/httpd.c
+++ b/httpd.c
@@ -235,6 +235,14 @@ int server_get_handler(xs_dict *req, const char *q_path,
*body = xs_str_new("User-agent: *\n"
"Disallow: /\n");
}
+ else
+ if (strcmp(q_path, "/.well-known/host-meta") == 0) {
+ status = 200;
+ *ctype = "application/xrd+xml";
+ *body = xs_str_new("<XRD>"
+ "<Link rel=\"lrdd\" type=\"application/xrd+xml\" template=\"%s/.well-known/webfinger?resource={uri}\"/>"
+ "</XRD>");
+ }
if (status != 0)
srv_debug(1, xs_fmt("server_get_handler serving '%s' %d", q_path, status));