mirror of
https://github.com/chillerlan/php-httpinterface.git
synced 2026-04-26 04:55:49 +03:00
[PR #3] [CLOSED] Fix CurlClient & StreamClient on default mode verify_peer and null ca_info #4
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/php-httpinterface#4
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/chillerlan/php-httpinterface/pull/3
Author: @eclipxe13
Created: 3/22/2019
Status: ❌ Closed
Base:
master← Head:master📝 Commits (2)
f61fa25Fix CurlClient on default mode verify_peer and default ca_infoac82d51Fix StreamClient on default mode verify_peer and default ca_info📊 Changes
4 files changed (+7 additions, -6 deletions)
View changed files
📝
src/Psr18/CurlHandle.php(+5 -2)📝
src/Psr18/StreamClient.php(+2 -2)📝
tests/Psr18/CurlClientTest.php(+0 -1)📝
tests/Psr18/StreamClientTest.php(+0 -1)📄 Description
The default mode for CurlClient and StreamClient is to verify peers, chich is good.
This is set in HTTPOptions.
The problem is that CurlClient and StreamClient set the value even if it is NULL and it make it fail instead of using default configured/system default values.
In this PR:
CurlClient (on CurlHandle) only set this option if can evaluate to true
StreamClient only set this option if can evaluate to true.
Feel free if you found a better way to test it or you don't like the way I did it.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.