Re: [RFC] Under Discussion: Default User-Agent for cURL
| From: | Hans Henrik Bergan | Date: | Tue, 03 Aug 2021 17:51:55 +0000 |
| Subject: | Re: [RFC] Under Discussion: Default User-Agent for cURL | ||
| References: | 1 2 3 4 5 6 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-115626@lists.php.net to get a copy of this message | ||
>
> or doing nothing at all.
>
Sounds good to me.
On Tue, 3 Aug 2021 at 16:47, Sara Golemon <pollita@php.net> wrote:
> On Tue, Aug 3, 2021 at 4:45 AM Hans Henrik Bergan <divinity76@gmail.com>
> wrote:
>
>> fwiw i think no self-respecting codebase is depending on an ini-setting
>> being correct for the ua in cases where the ua is actually important, so
>> the breakage should be minimal.
>>
>>
> In my mind, this is either an argument in favor of either NOT adding a new
> INI setting (rather applying the existing user_agent setting to curl), or
> doing nothing at all. Code using curl already knows how to call the
> precisely ONE line required to set a user agent, or more likely uses a
> wrapper which simplifies cURL's archaic interface, in which case it's that
> proxy which should be setting any default UA, not PHP.
>
> And on the subject of PHP_INI_ALL/PERDIR/SYSTEM. The answer is ALL.
> PERDIR and SYSTEM exist either for technical limits (something gets
> allocated and has to live across requests), or security limiters. The
> former certainly doesn't apply, and the latter wouldn't achieve anything
> since the UA can always be set explicitly on any curl handle. PHP_INI_ALL
> is the only setting which makes sense if we add an additional configuration
> (which I don't think we should).
>
> -Sara
>