Created attachment 197984 [details] Fix OpenSSL 1.1.x build mail/pop3proxy: Fix OpenSSL build PR: 231931 Submitted by: Nathan <ndowens@yahoo.com> Approved by: portmgr (unmaintained port)
This doesn't look good, EVP_DigestInit is used on uninitialized memory.
(In reply to Antoine Brodin from comment #1) I don’t understand as I haven’t changed that part of the code
You changed mdctx from EVP_MD_CTX to an unallocated pointer to EVP_MD_CTX
EVP_DigestInit() behaves in the same way as EVP_DigestInit_ex() except the passed context ctx does not have to be initialized, and it always uses the default digest implementation As long as I’m not misunderstanding it seems digest init doesn’t have to be initialized
:-/ The port will crash at runtime.
(In reply to Antoine Brodin from comment #5) It does look that way, has any run time testing been done?
Sorry guys I’m no programmer. I’m still figuring out some of things and trying to be of use
Created attachment 198028 [details] Fix openssl I think i understand now. i hope this patch looks good. This kind of stuff is new to me.
I tried running it but I get service error with or without patch as I’m not sure exactly how this port works
Unless this port is no longer failing to build, it should remain open.
Created attachment 200241 [details] pop3proxy-fix-build-with-openssl111.patch This is another try to fix the build with OpenSSL 1.11+. The patch also does following items: - fix the wrong default location for the configuration file which prevented the start via rc script (was "/docsis/etc/pop3proxyd.conf", now: $PREFIX/etc/pop3proxyd.conf"). This resided probably a very long time in the port. - pet portlint a bit (not all items were covered, see further below for a reason) - fix the installation of the configuration files which were installed with the execute bit set - improve pkg-descr a bit to inform about pop3proxy's origin Because mail/pop3proxy is derived from an earlier version of mail/up-imapproxy the SSL patch was taken from there with some small modifications. I assume the origin of the patch would be still Debian in that case. I also went through the code and did some runtime tests after the issue with the wrong configuration path was fixed. Interestingly pop3proxy doesn't seem to support and initiate any SSL/TLS connections, it only worked properly when the traffic was unencrypted. Given those facts the port isn't really useful for actual use-cases because there are more modern and secure solutions to setup a POP3 proxy if required. QA: ~~~ poudriere (11.2-, 12.-RELEASE, 13.0-CURRENT@r341993 amd64 + i386) -> OK portlint -> OK (with some warnings)
A commit references this bug: Author: tobik Date: Mon Jan 28 19:24:52 UTC 2019 New revision: 491513 URL: https://svnweb.freebsd.org/changeset/ports/491513 Log: mail/pop3proxy: Fix build with OpenSSL 1.1.1 - Add license - Fix config file location - Reorder some things to pet portlint - Mark it deprecated too as it appears to have no upstream anymore and only works properly with unencrypted traffic PR: 232134 Submitted by: freebsd_ports@k-worx.org MFH: 2019Q1 Changes: head/mail/pop3proxy/Makefile head/mail/pop3proxy/files/patch-Makefile.in head/mail/pop3proxy/files/patch-src_imapcommon.c head/mail/pop3proxy/pkg-descr
A commit references this bug: Author: tobik Date: Tue Jan 29 17:49:13 UTC 2019 New revision: 491589 URL: https://svnweb.freebsd.org/changeset/ports/491589 Log: MFH: r491513 mail/pop3proxy: Fix build with OpenSSL 1.1.1 - Add license - Fix config file location - Reorder some things to pet portlint - Mark it deprecated too as it appears to have no upstream anymore and only works properly with unencrypted traffic PR: 232134 Submitted by: freebsd_ports@k-worx.org Approved by: ports-secteam (miwi) Changes: _U branches/2019Q1/ branches/2019Q1/mail/pop3proxy/Makefile branches/2019Q1/mail/pop3proxy/files/patch-Makefile.in branches/2019Q1/mail/pop3proxy/files/patch-src_imapcommon.c branches/2019Q1/mail/pop3proxy/pkg-descr