Remove duplicate '+' in comparison string
Signed-off-by: Agathiyan Bragadeesh <agathiyan.bragadeesh2@arm.com>
diff --git a/library/x509.c b/library/x509.c
index e2bb2fd..b487b43 100644
--- a/library/x509.c
+++ b/library/x509.c
@@ -910,7 +910,7 @@
c = name->val.p[i];
// Special characters requiring escaping, RFC 4514 Section 2.4
if (c) {
- if (strchr(",=+<>;\"\\+", c) ||
+ if (strchr(",=+<>;\"\\", c) ||
((i == 0) && strchr("# ", c)) ||
((i == name->val.len-1) && (c == ' '))) {
if (j + 1 >= sizeof(s) - 1) {
diff --git a/library/x509_create.c b/library/x509_create.c
index a666e2d..4c52611 100644
--- a/library/x509_create.c
+++ b/library/x509_create.c
@@ -197,7 +197,7 @@
hexpair = 1;
*(d++) = n;
c++;
- } else if (c == end || !strchr(" ,=+<>#;\"\\+", *c)) {
+ } else if (c == end || !strchr(" ,=+<>#;\"\\", *c)) {
return MBEDTLS_ERR_X509_INVALID_NAME;
}
}