summaryrefslogtreecommitdiff
path: root/content/fetchers/about.c
diff options
context:
space:
mode:
authorDaniel Silverstone <dsilvers@digital-scurf.org>2020-05-22 10:37:15 +0100
committerDaniel Silverstone <dsilvers@digital-scurf.org>2020-05-22 10:37:27 +0100
commitb28d3c267510d2e80e4730f71ff1fa5f61795499 (patch)
treebd44fbb5d2810cb46169ba3f8fea47d11dc5d998 /content/fetchers/about.c
parentc2f73310d011a7e6b02f6dbedf96826c21a1b88f (diff)
downloadnetsurf-b28d3c267510d2e80e4730f71ff1fa5f61795499.tar.gz
netsurf-b28d3c267510d2e80e4730f71ff1fa5f61795499.tar.bz2
query/ssl: Include link to view certificate details
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
Diffstat (limited to 'content/fetchers/about.c')
-rw-r--r--content/fetchers/about.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/content/fetchers/about.c b/content/fetchers/about.c
index d7c1f7e7e..532223fbb 100644
--- a/content/fetchers/about.c
+++ b/content/fetchers/about.c
@@ -2199,6 +2199,7 @@ static bool fetch_about_query_privacy_handler(struct fetch_about_context *ctx)
const char *title;
struct nsurl *siteurl = NULL;
char *description = NULL;
+ const char *chainurl = "";
const struct fetch_multipart_data *curmd; /* mutipart data iterator */
/* extract parameters from multipart post data */
@@ -2211,6 +2212,8 @@ static bool fetch_about_query_privacy_handler(struct fetch_about_context *ctx)
}
} else if (strcmp(curmd->name, "reason") == 0) {
reason = curmd->value;
+ } else if (strcmp(curmd->name, "chainurl") == 0) {
+ chainurl = curmd->value;
}
curmd = curmd->next;
}
@@ -2258,7 +2261,12 @@ static bool fetch_about_query_privacy_handler(struct fetch_about_context *ctx)
goto fetch_about_query_ssl_handler_aborted;
}
}
- res = ssenddataf(ctx, "<div><p>%s</p></div>", reason);
+ res = ssenddataf(ctx,
+ "<div><p>%s</p></div>"
+ "<div><p><a href=\"%s\" target=\"_blank\">%s</a></p></div>",
+ reason,
+ chainurl,
+ messages_get("ViewCertificates"));
if (res != NSERROR_OK) {
goto fetch_about_query_ssl_handler_aborted;
}