summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorErmal Luçi <eri@pfsense.org>2010-03-01 21:33:30 +0000
committerErmal Luçi <eri@pfsense.org>2010-03-01 21:33:30 +0000
commit81899dab04439ad680368f276edf7fae1155a18d (patch)
treeb96d420a04e5f8ad04c653e09d196b77060ab298 /etc
parentda3da9dbc83172eba2876de24176be420a2fe4a9 (diff)
downloadpfsense-81899dab04439ad680368f276edf7fae1155a18d.zip
pfsense-81899dab04439ad680368f276edf7fae1155a18d.tar.gz
Its and and not an or.
Diffstat (limited to 'etc')
-rwxr-xr-xetc/inc/openvpn.auth-ldap.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/etc/inc/openvpn.auth-ldap.php b/etc/inc/openvpn.auth-ldap.php
index 72b3374..7155972 100755
--- a/etc/inc/openvpn.auth-ldap.php
+++ b/etc/inc/openvpn.auth-ldap.php
@@ -63,7 +63,7 @@ ldap_set_option($ldap, LDAP_OPT_REFERRALS, 0);
ldap_set_option($ldap, LDAP_OPT_PROTOCOL_VERSION, (int)$ldapver);
/* ok, its up. now, lets bind as the bind user so we can search it */
-if (!($res = @ldap_bind($ldap, $username, $password)) || !($res = @ldap_bind($ldap, $usernamedn, $password))) {
+if (!($res = @ldap_bind($ldap, $username, $password)) && !($res = @ldap_bind($ldap, $usernamedn, $password))) {
syslog(LOG_WARNING, "user {$username} could not authenticate\n");
ldap_close($ldap);
exit(-3);
OpenPOWER on IntegriCloud