[asterisk-bugs] [JIRA] (ASTERISK-17491) CURLOPT() needs a "followlocation" parameter / "maxredirs" doesn't do anything

Asterisk Team (JIRA) noreply at issues.asterisk.org
Wed Sep 9 11:16:49 CDT 2020


     [ https://issues.asterisk.org/jira/browse/ASTERISK-17491?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Asterisk Team updated ASTERISK-17491:
-------------------------------------

    Target Release Version/s: 18.0.0

> CURLOPT() needs a "followlocation" parameter / "maxredirs" doesn't do anything
> ------------------------------------------------------------------------------
>
>                 Key: ASTERISK-17491
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-17491
>             Project: Asterisk
>          Issue Type: New Feature
>          Components: Functions/func_curl
>    Affects Versions: 1.8.3, 13.18.4
>            Reporter: candrews
>              Labels: patch
>      Target Release: 13.31.0, 16.8.0, 17.2.0, 18.0.0
>
>         Attachments: ast11_func_curl_redirects_and_tls.patch
>
>
> I noticed that the CURL function will not follow redirects. According to http://curl.haxx.se/libcurl/c/curl_easy_setopt.html#CURLOPTFOLLOWLOCATION you need to set the CURLOPT_FOLLOWLOCATION in order for CURL to follow redirects, and that is not set according to the source code: http://svnview.digium.com/svn/asterisk/trunk/funcs/func_curl.c?view=markup
> This is especially interesting seeing as how there is a "maxredirs" CURLOPT parameter. According to the CURL documentation at http://curl.haxx.se/libcurl/c/curl_easy_setopt.html#CURLOPTMAXREDIR :
> "This option only makes sense if the CURLOPT_FOLLOWLOCATION is used at the same time."
> I suggest that a new CURLOPT parameter "followlocation" be added to add the redirect following feature and fix the currently broken "maxredirs" option.
> ****** ADDITIONAL INFORMATION ******
> Note that this is not a feature request - "maxredirect" (which already exists) is currently broken - and I'm suggesting a way to fix that.



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list