Bug 2001430

Summary: net-snmp: FTBFS due to use of ERR_GET_FUNC (which was removed from OpenSSL)
Product: Red Hat Enterprise Linux 9 Reporter: Florian Weimer <fweimer>
Component: net-snmpAssignee: Josef Ridky <jridky>
Status: CLOSED ERRATA QA Contact: Evgeny Fedin <efedin>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: CentOS StreamCC: bstinson, jwboyer
Target Milestone: rcKeywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: net-snmp-5.9.1-7.el9 Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of:
: 2004351 (view as bug list) Environment:
Last Closed: 2022-05-17 12:55:46 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:
Bug Depends On:    
Bug Blocks: 2004351    
Attachments:
Description Flags
build.log none

Description Florian Weimer 2021-09-06 06:11:36 UTC
Created attachment 1820753 [details]
build.log

During the a rebuild of net-snmp-5.9.1-6.el9, the sources try to use the non-existing ERR_GET_FUNC function:

snmp_openssl.c: In function 'netsnmp_openssl_err_log':
snmp_openssl.c:949:36: warning: implicit declaration of function 'ERR_GET_FUNC'; did you mean 'ERR_GET_LIB'? [-Wimplicit-function-declaration]
  949 |                  ERR_GET_LIB(err), ERR_GET_FUNC(err), ERR_GET_REASON(err));
      |                                    ^~~~~~~~~~~~
      |                                    ERR_GET_LIB

This leads to a link failure later:

/usr/bin/ld: /tmp/ccKI9GVH.ltrans6.ltrans.o: in function `netsnmp_openssl_err_log':
/builddir/build/BUILD/net-snmp-5.9.1/snmplib/snmp_openssl.c:948: undefined reference to `ERR_GET_FUNC'
/usr/bin/ld: /builddir/build/BUILD/net-snmp-5.9.1/snmplib/snmp_openssl.c:948: undefined reference to `ERR_GET_FUNC'

The function has been removed without a replacement because function numbers have been removed from OpenSSL. It should be sufficient to adjust the error reporting so that the function number is no longer included.

Comment 1 Josef Ridky 2021-09-10 07:23:27 UTC
Fixed in upstream https://github.com/net-snmp/net-snmp/issues/343

Comment 7 errata-xmlrpc 2022-05-17 12:55:46 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (new packages: net-snmp), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2022:2421