LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 04-26-2016, 02:01 PM   #1
sneakyimp
Senior Member
 
Registered: Dec 2004
Posts: 1,056

Rep: Reputation: 78
CentOS 6.7 has really OLD curl. Best way to update curl?


I've got version 3 of a website running on a CentOS server and was recently notified by a payment gateway that they plan to upgrade their SSL/TSL transport. They kindly supplied a battery of tests. The tests have revealed that curl is lamentably old on CentOS 6.7:
Code:
$ curl --version
curl 7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.19.1 Basic ECC zlib/1.2.3 libidn/1.18 libssh2/1.4.2
Protocols: tftp ftp telnet dict ldap ldaps http file https ftps scp sftp 
Features: GSS-Negotiate IDN IPv6 Largefile NTLM SSL libz
I tried sniffing around using yum for some newer version of curl but it doesn't seem to have anything that is an obvious upgrade. Tried this:
Code:
sudo yum clean all
sudo yum install libcurl
but it responds:
Code:
Package libcurl-7.19.7-46.el6.x86_64 already installed and latest version
Nothing to do
Unless I'm missing something, CentOS 6.7's packages have curl 7.19 and that's that. Is this not the case?

There's an upgrade method using RPM here. Basically it says do this:
Quote:
Use the city-fan repo ( part of the curl mirror http://curl.haxx.se/download.html#LinuxRedhat)

Code:
rpm -Uvh http://www.city-fan.org/ftp/contrib/yum-repo/rhel6/x86_64/city-fan.org-release-1-13.rhel6.noarch.rpm
yum install libcurl
I'm not really sure how this might impact my package management, whether it's safe or not, and whether this will result in security upgrades when I do a yum upgrade or not.

Can anyone recommend the best way to deal with this such that my curl is updated (ideally 7.35 or later) and stays patched with security fixes and so on?
 
Old 04-26-2016, 02:04 PM   #2
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,824

Rep: Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615
* Update this host to 7.x, or
* compile it yourself, install to /usr/local so it doesn't touch the system, and take responsibility for updates, or
* use city-fan and trust it will not break anything
 
Old 04-26-2016, 02:12 PM   #3
sneakyimp
Senior Member
 
Registered: Dec 2004
Posts: 1,056

Original Poster
Rep: Reputation: 78
Thanks for your response.
Quote:
Originally Posted by AlucardZero View Post
* Update this host to 7.x, or
* compile it yourself, install to /usr/local so it doesn't touch the system, and take responsibility for updates, or
* use city-fan and trust it will not break anything
Given this server is soon to be replaced by version 4 (which will probably run on Ubuntu 16.04) we are hoping to avoid the full upgrade ordeal to CentOS 7. The current website is quite old and we expect things to break.

If I compile myself, why keep it from touching the system? The desire is to have it upgrade curl usage in PHP scripts et.al so it's desirable for us to have it "touch" the system I think. Is it really going to break anything?

As for trusting city-fan -- I've no idea who they are or whether they are trustworthy. I'm not exactly inclined to trust them with this particular server as it performs some sensitive operations.
 
Old 04-26-2016, 02:16 PM   #4
sneakyimp
Senior Member
 
Registered: Dec 2004
Posts: 1,056

Original Poster
Rep: Reputation: 78
Also, I suspect that the curl installed on CentOS 6.7 uses NSS instead of OpenSSL -- not certain about that but it seems to be a complicating issue if I hope to compile from source.
 
Old 04-26-2016, 03:06 PM   #5
sneakyimp
Senior Member
 
Registered: Dec 2004
Posts: 1,056

Original Poster
Rep: Reputation: 78
OK I downloaded curl 7.48 source code from haxx.se and did the ./configure and make and make install and now when I invoke curl from the CLI it reports version 7.48.

HOWEVER, the version of curl reported by PHP is still the old one:
Code:
$ php -r 'var_dump(curl_version());'
array(9) {
  ["version_number"]=>
  int(463623)
  ["age"]=>
  int(3)
  ["features"]=>
  int(1597)
  ["ssl_version_number"]=>
  int(0)
  ["version"]=>
  string(6) "7.19.7"
  ["host"]=>
  string(23) "x86_64-redhat-linux-gnu"
  ["ssl_version"]=>
  string(20) "NSS/3.19.1 Basic ECC"
  ["libz_version"]=>
  string(5) "1.2.3"
  ["protocols"]=>
  array(12) {
    [0]=>
    string(4) "tftp"
    [1]=>
    string(3) "ftp"
    [2]=>
    string(6) "telnet"
    [3]=>
    string(4) "dict"
    [4]=>
    string(4) "ldap"
    [5]=>
    string(5) "ldaps"
    [6]=>
    string(4) "http"
    [7]=>
    string(4) "file"
    [8]=>
    string(5) "https"
    [9]=>
    string(4) "ftps"
    [10]=>
    string(3) "scp"
    [11]=>
    string(4) "sftp"
  }
}
How can I get PHP's curl version to also be updated?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
cURL: Server has many IPs, how would I make a cURL script use those IPs to send data? guest Programming 0 04-11-2009 11:42 AM
LXer: Security update for cURL LXer Syndicated Linux News 0 03-05-2009 04:41 AM
centos /apache issues...no gd / imap / curl I_AM Linux - General 2 06-06-2005 02:35 PM
urpmi.update fails on curl dukeinlondon Mandriva 2 01-03-2004 06:23 PM
curl or mandrake update robot adcripps Linux - Software 0 08-27-2002 08:32 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:48 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration