opnsense-ports/security/ipsec-tools/files/wildcard-psk.diff
Franco Fichtner a737ce6b05 */*: sync previously available, but unused ports
Taken from: FreeBSD
2015-04-22 06:45:04 +02:00

12 lines
431 B
Diff

--- src/racoon/localconf.c 9 Sep 2006 16:22:09 -0000 1.4
+++ src/racoon/localconf.c 11 Jul 2008 20:58:55 -0000
@@ -211,7 +211,8 @@ getpsk(str, len)
if (*p == '\0')
continue; /* no 2nd parameter */
p--;
- if (strncmp(buf, str, len) == 0 && buf[len] == '\0') {
+ if (strcmp(buf, "*") == 0
+ || (strncmp(buf, str, len) == 0 && buf[len] == '\0')) {
p++;
keylen = 0;
for (q = p; *q != '\0' && *q != '\n'; q++)