Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 981058

Summary: openssh-ldap ignores some configuration variables
Product: [Fedora] Fedora Reporter: jakub.jedelsky
Component: opensshAssignee: Petr Lautrbach <plautrba>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 20CC: bugzilla.blk, jjelen, lyonel, mattias.ellert, mgrepl, plautrba, tmraz
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: openssh-6.4p1-8.fc20 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-02-03 12:02:37 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
fix
none
Fix LDAP extension none

Description jakub.jedelsky 2013-07-03 22:11:14 UTC
Description of problem:
Utility ssh-ldap-helper ignores some of options from its configuration file (/etc/ssh/ldap.conf). If one need to enable SSL but without checking CA, it should be configured with "tls_checkpeer" set to "allow". But ssh-ldap-helper set it into "hard" in anyway.

Same problem is with option "bind_policy".

Version-Release number of selected component (if applicable):
6.2p2-3.fc19
5.3p1-84.1.el6 (on centos 6)

How reproducible:
always

Steps to Reproduce:
1. Configure LDAP with self-signed certificate (I use Windows AD 2012 as LDAP server).
2. In SSH config file:
- enable SSL
- set tls_checkpeer to something different from "hard", eg. "allow"
3. Run ssh-ldap-helper in debug mode: `/usr/libexec/openssh/ssh-ldap-helper -dvvv -s LDAPUserName

Actual results:
Can't connect to server with self-signed certificate.
From debug mode:
(snip)
debug3: TLS_CheckPeer Hard
(snip)
ldap_simple_bind Can't contact LDAP server
(snip)

Expected results:
Is connected to server with self-signed certificate and returns sshPublicKey.
From debug mode:
(snip)
debug3: TLS_CheckPeer Allow
(snip)

Exact config options:
host <IP>
port 636
binddn cn=bind user,cn=Users,dc=test,dc=env
bindpw bind_passwd
base dc=test,dc=env
scope sub
ssl yes
tls_checkpeer allow

Comment 1 Lyonel Vincent 2014-06-03 16:10:56 UTC
Created attachment 901853 [details]
fix

fix a typo (missing line):

if (*intptr == -1)
        *intptr = value;
        break;

instead of

if (*intptr == -1)
        break;

Comment 2 Jakub Jelen 2015-01-09 17:51:44 UTC
Created attachment 978338 [details]
Fix LDAP extension

It looks like there are more than one occurrence of this error which makes these problems TLS_CheckPeer and Bind_Policy (as mentioned in original description) in ldap.patch

Here is patch of patch, which should solve this behaviour. But I'm not sure if I will be able to test it.

Also applicable for f20, f21 and rawhide.

Comment 3 Fedora End Of Life 2015-01-09 18:39:03 UTC
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 4 Fedora Update System 2015-01-15 14:34:17 UTC
openssh-6.6.1p1-11.1.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/openssh-6.6.1p1-11.1.fc21

Comment 5 Fedora Update System 2015-01-15 15:03:33 UTC
openssh-6.4p1-8.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/openssh-6.4p1-8.fc20

Comment 6 Fedora Update System 2015-01-17 05:40:08 UTC
Package openssh-6.4p1-8.fc20:
* should fix your issue,
* was pushed to the Fedora 20 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing openssh-6.4p1-8.fc20'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2015-0756/openssh-6.4p1-8.fc20
then log in and leave karma (feedback).

Comment 7 Fedora Update System 2015-01-17 23:55:33 UTC
openssh-6.6.1p1-11.1.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2015-02-03 12:02:37 UTC
openssh-6.4p1-8.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 9 IanB 2015-07-28 04:30:05 UTC
I'm having this issue on a fully patched Centos6: openssh-ldap-5.3p1-104.el6_6.1.x86_64

Comment 10 Jakub Jelen 2015-07-28 05:37:56 UTC
This is fixed in last openssh release (openssh-5.3p1-112) even in RHEL. RHEL 6.7 is out, so you will probably have to wait for CentOS folks to rebuild it.

Comment 11 IanB 2015-07-30 00:04:38 UTC
Also having this issue on fully patched Centos7: openssh-ldap-6.6.1p1-12.el7_1.x86_64

Comment 12 Jakub Jelen 2015-07-30 06:14:19 UTC
Yes, fix for RHEL 7 is also on its way out.