libldap-common missing in beanbag/reviewboard:6.0 and above

57 views
Skip to first unread message

Florian Miedniak

unread,
Mar 5, 2024, 6:33:57 AMMar 5
to Review Board Community
I just stumbled upon this: libldap-common missing in beanbag/reviewboard:6.0 and above.

This has a nasty consequence: Verification of LDAPS servers with non-public certificates is not possible anymore! Instead, RB will just report the very unspecific error:
 Error authenticating with LDAP: {'result': -1, 'desc': "Can't contact LDAP server", 'ctrls': [], 'info': '(unknown error code)'}

Back-trace down to root-cause:
  1. Certificate of LDAP server can't be verified -> No connection possible
  2. LDAP client library is not configured to access system-wide certificates as located in /etc/ssl/certs (Should be configured in /etc/ldap/ldap.conf, but whole directory is missing)
  3. Directory is missing, because package libldap-common is not installed
  4. Chain of dependencies leading to installation:
    1. RB 5.0 image: curl -> libcurl4 -> libldap-2.4-2 -DEPENDS-> libldap-common 
    2. RB 6.0 image:  curl -> libcurl4 -> libldap-2.5-0 -RECOMMENDS-> libldap-common
      => Package libldap-common is not installed because its relationship changed from "dependents" to "recommends": Before: https://packages.ubuntu.com/focal/libldap-2.4-2 Now: https://packages.ubuntu.com/jammy-updates/libldap-2.5-0  
      and  OS packages are installed with --no-install-recommends
For now, I'll live with explicitly installing libldap-common in my own image that is derived from beanbag/reviewboard:6.0. But IMO it would be better to solve this in the base image.

Possible solutions:
(a) Remove the --no-install-recommends from call to apt-get
+ No explicit installation of libldap-common necessary, reduces risk of similar issues with other packages in future
- May bloat the image with other packages that are neither wanted nor needed
(b) Explicitly install package libldap-common
+ Reduces risk of bloating the image and minimizes change in images

Any opinions on that? Anyway, is https://github.com/reviewboard/reviewboard/blob/release-6.0.2/contrib/docker/Dockerfile the correct file to look at and may I open  a pull request for this right away or is it usual to discuss it first in this group?

-Florian

Florian Miedniak

unread,
Mar 6, 2024, 11:25:31 AMMar 6
to Review Board Community

Christian Hammond

unread,
Mar 6, 2024, 1:33:26 PMMar 6
to revie...@googlegroups.com
Thanks for the report and the patch! We’ve deployed new images with this library installed, so hopefully that sorts things out.

Christian

--
Christian Hammond
President/CEO of Beanbag
Makers of Review Board


--
Supercharge your Review Board with Power Pack: https://www.reviewboard.org/powerpack/
Want us to host Review Board for you? Check out RBCommons: https://rbcommons.com/
Happy user? Let us know! https://www.reviewboard.org/users/
---
You received this message because you are subscribed to the Google Groups "Review Board Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to reviewboard...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/reviewboard/2f969746-ffc1-45aa-9985-e81b0c38350dn%40googlegroups.com.
Message has been deleted

Florian Miedniak

unread,
Mar 6, 2024, 1:45:53 PMMar 6
to Review Board Community

Christian Hammond

unread,
Mar 6, 2024, 8:43:35 PMMar 6
to revie...@googlegroups.com
Hmm, that should have been picked up. Let me take another look.

Christian


--
Christian Hammond
President/CEO of Beanbag
Makers of Review Board

Florian Miedniak

unread,
Mar 7, 2024, 3:12:34 AMMar 7
to Review Board Community
Seems that change in Dockerfile didn't make it into the image:

$ docker images --digests | grep beanbag
beanbag/reviewboard                                              latest      sha256:b74f9efcb53d5ed106fcfedc0d3cdd54128d3c6e6ad9ec565c99e5247813b4d9   61f6fb5c47b3   5 hours ago    737MB  -> Image from second attempt
beanbag/reviewboard                                              6.0         sha256:e3a1cb8da75bbb505a6c134d1407deddd71507886f41a9e1b56cc537b576f0ae   b497c4569450   27 hours ago   737MB -> Image from first attempt

$ container-diff diff daemon://beanbag/reviewboard:6.0 daemon://beanbag/reviewboard:latest --type=apt

-----Apt-----
Packages found only in beanbag/reviewboard:6.0: None
Packages found only in beanbag/reviewboard:latest: None

Version differences: None

I don't really know your branching concept, but is the docker image really made from branch release-6.x, where the commit has been done?

-Florian

Christian Hammond

unread,
Mar 7, 2024, 4:48:11 AMMar 7
to revie...@googlegroups.com
It's built from this branch. The problem has to do with when the libldap-common is being installed. That install is happening in stage 1 of the build, but that only applies to compilation and initial setup. The problem is that stage 2 never installs this, so it doesn't end up in the final image. Stage 2 copies built Python packages and other state out of stage 1, but doesn't inherit the installed packages, as many of them aren't necessary beyond compilation.

We'll correct it within the next couple of days.

Christian

Florian Miedniak

unread,
Mar 21, 2024, 4:01:42 AMMar 21
to revie...@googlegroups.com

Any news on update of the docker image?

 

From: revie...@googlegroups.com <revie...@googlegroups.com> On Behalf Of Christian Hammond
Sent: Donnerstag, 7. März 2024 10:48
To: revie...@googlegroups.com
Subject: Re: libldap-common missing in beanbag/reviewboard:6.0 and above

 

BeSecure!

This email comes from outside of ABB. Make sure you verify the sender before clicking any links or downloading/opening attachments.
If this email looks suspicious, report it by clicking 'Report Phishing' button in Outlook or raising a ticket on MyIS.

 

Christian Hammond

unread,
Mar 21, 2024, 8:27:26 PMMar 21
to revie...@googlegroups.com
This honestly slipped by, as we’ve all been busy trying to make a deadline. We’ll aim to get new images by this weekend.

Christian

--
Christian Hammond
President/CEO of Beanbag
Makers of Review Board

Reply all
Reply to author
Forward
0 new messages