git: 327c682e4676 - main - security/openvpn-auth-ldap: Fix crash/update MAINTAINER/bump PORTREVISION
Date: Wed, 17 Aug 2022 17:51:30 UTC
The branch main has been updated by zi:
URL: https://cgit.FreeBSD.org/ports/commit/?id=327c682e46761e2a9c06507dafb8fac49f564ce6
commit 327c682e46761e2a9c06507dafb8fac49f564ce6
Author: Ryan Steinmetz <zi@FreeBSD.org>
AuthorDate: 2022-08-17 17:49:46 +0000
Commit: Ryan Steinmetz <zi@FreeBSD.org>
CommitDate: 2022-08-17 17:51:13 +0000
security/openvpn-auth-ldap: Fix crash/update MAINTAINER/bump PORTREVISION
Approved by: mandree@ (maintainer)
---
security/openvpn-auth-ldap/Makefile | 4 ++--
.../openvpn-auth-ldap/files/patch-src_auth-ldap.m | 21 +++++++++++++++++++--
2 files changed, 21 insertions(+), 4 deletions(-)
diff --git a/security/openvpn-auth-ldap/Makefile b/security/openvpn-auth-ldap/Makefile
index da959b439e44..5266a44d142e 100644
--- a/security/openvpn-auth-ldap/Makefile
+++ b/security/openvpn-auth-ldap/Makefile
@@ -1,10 +1,10 @@
PORTNAME= openvpn-auth-ldap
PORTVERSION= 2.0.4
-PORTREVISION= 1
+PORTREVISION= 2
DISTVERSIONPREFIX= auth-ldap-
CATEGORIES= security net-vpn
-MAINTAINER= mandree@FreeBSD.org
+MAINTAINER= zi@FreeBSD.org
COMMENT= LDAP authentication plugin for OpenVPN
LICENSE= BSD3CLAUSE
diff --git a/security/openvpn-auth-ldap/files/patch-src_auth-ldap.m b/security/openvpn-auth-ldap/files/patch-src_auth-ldap.m
index 80e8c794b66e..d811948af304 100644
--- a/security/openvpn-auth-ldap/files/patch-src_auth-ldap.m
+++ b/security/openvpn-auth-ldap/files/patch-src_auth-ldap.m
@@ -1,8 +1,8 @@
Fix crash on close if there is no ctx.
---- src/auth-ldap.m.orig 2012-08-15 13:55:46 UTC
+--- src/auth-ldap.m.orig 2018-07-26 20:17:21 UTC
+++ src/auth-ldap.m
-@@ -245,6 +245,9 @@ OPENVPN_EXPORT void
+@@ -247,6 +247,9 @@ OPENVPN_EXPORT void
{
ldap_ctx *ctx = handle;
@@ -12,3 +12,20 @@ Fix crash on close if there is no ctx.
/* Clean up the configuration file */
[ctx->config release];
+@@ -545,7 +548,6 @@ openvpn_plugin_func_v1(openvpn_plugin_ha
+ pool = [[TRAutoreleasePool alloc] init];
+
+ username = get_env("username", envp);
+- TRString *userName=[[TRString alloc]initWithCString: username];
+ password = get_env("password", envp);
+ remoteAddress = get_env("ifconfig_pool_remote_ip", envp);
+
+@@ -556,6 +558,8 @@ openvpn_plugin_func_v1(openvpn_plugin_ha
+ goto cleanup;
+ }
+
++ TRString *userName=[[TRString alloc]initWithCString: username];
++
+ /* Create an LDAP connection */
+ if (!(ldap = connect_ldap(ctx->config))) {
+ [TRLog error: "LDAP connect failed."];