diff options
Diffstat (limited to 'httpd.c')
| -rw-r--r-- | httpd.c | 8 |
1 files changed, 8 insertions, 0 deletions
| @@ -243,6 +243,14 @@ int server_get_handler(xs_dict *req, const char *q_path, | |||
| 243 | *body = xs_str_new("User-agent: *\n" | 243 | *body = xs_str_new("User-agent: *\n" |
| 244 | "Disallow: /\n"); | 244 | "Disallow: /\n"); |
| 245 | } | 245 | } |
| 246 | else | ||
| 247 | if (strcmp(q_path, "/.well-known/host-meta") == 0) { | ||
| 248 | status = 200; | ||
| 249 | *ctype = "application/xrd+xml"; | ||
| 250 | *body = xs_str_new("<XRD>" | ||
| 251 | "<Link rel=\"lrdd\" type=\"application/xrd+xml\" template=\"%s/.well-known/webfinger?resource={uri}\"/>" | ||
| 252 | "</XRD>"); | ||
| 253 | } | ||
| 246 | 254 | ||
| 247 | if (status != 0) | 255 | if (status != 0) |
| 248 | srv_debug(1, xs_fmt("server_get_handler serving '%s' %d", q_path, status)); | 256 | srv_debug(1, xs_fmt("server_get_handler serving '%s' %d", q_path, status)); |