Curl Error: curl error: An unknown option was passed in to libcurl

Hello!,
This is my first post here.

I’m having some problems after upgrading from CentOS 7 to Alma Linux 8

When trying to perform some action such as a yum update / dnf upgrade I have the following error

Error: curl error: An unknown option was passed in to libcurl

yum check-update
Error: curl error: An unknown option was passed in to libcurl

esearching the topic and forums I found that it could be due to a double curl

I found some duplicates but when I wanted to reinstall or delete the following:

libcurl.x86_64 7.61.1-34.el8 @System

i have the same error

It is an environment with cPanel

 yum list installed | grep curl
cpanel-perl-536-net-curl-promiser.noarch                     0.18-1.cp108~el7                             @System
curl.x86_64                                                  7.61.1-34.el8                                @System
libcurl.x86_64                                               7.61.1-34.el8                                @System
python3-pycurl.x86_64                                        7.43.0.2-4.el8                               @System
 rpm -qa | grep curl
libcurl-7.61.1-34.el8.x86_64
python3-pycurl-7.43.0.2-4.el8.x86_64
curl-7.61.1-34.el8.x86_64

# curl --version
curl 7.45.0 (x86_64-pc-linux-gnu) libcurl/7.45.0 OpenSSL/1.0.1e zlib/1.2.11 libidn/1.34

cat /etc/redhat-release 
AlmaLinux release 8.10 (Cerulean Leopard)


Note that the version indicated in curl --version is different from that of the packages, which I understand is why this causes the problem

But since I couldn’t install or delete it, after searching for a few hours of information, I didn’t find much else, just like consulting with colleagues.

If you have suggestions, I listen to everything and I also apologize in advance if there is a format that I did not follow and I will be totally willing to edit the post so that it complies with forum regulations.

Fixed installing manually a new version

Version 7.62.x:

wget https://curl.se/download/curl-7.62.0.tar.gz
tar -xzf curl-7.62.0.tar.gz
cd curl-7.62.0
./configure
make
sudo make install

Verify

curl --version