[openssl-commits] [openssl] master update
Rich Salz
rsalz at openssl.org
Sat Apr 25 20:06:32 UTC 2015
The branch master has been updated
via f92beb98de0c8fdbf18f29642264258cc2ff05e7 (commit)
from c6724060e267f55cb5c5088b771c9ded9af0e16b (commit)
- Log -----------------------------------------------------------------
commit f92beb98de0c8fdbf18f29642264258cc2ff05e7
Author: Rich Salz <rsalz at openssl.org>
Date: Sat Apr 25 16:06:19 2015 -0400
Quote HTML entities in s_server output
Reviewed-by: Richard Levitte <levitte at openssl.org>
-----------------------------------------------------------------------
Summary of changes:
apps/s_server.c | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/apps/s_server.c b/apps/s_server.c
index 3644381..88309a6 100644
--- a/apps/s_server.c
+++ b/apps/s_server.c
@@ -2723,7 +2723,22 @@ static int www_body(char *hostname, int s, int stype, unsigned char *context)
/* BIO_puts(io,SSLeay_version(SSLEAY_VERSION));*/
BIO_puts(io, "\n");
for (i = 0; i < local_argc; i++) {
- BIO_puts(io, local_argv[i]);
+ const char *myp;
+ for (myp = local_argv[i]; *myp; myp++)
+ switch (*myp) {
+ case '<':
+ BIO_puts(io, "<");
+ break;
+ case '>':
+ BIO_puts(io, ">");
+ break;
+ case '&':
+ BIO_puts(io, "&");
+ break;
+ default:
+ BIO_write(io, myp, 1);
+ break;
+ }
BIO_write(io, " ", 1);
}
BIO_puts(io, "\n");
More information about the openssl-commits
mailing list