? Error

User tests: Successful: Unsuccessful:

avatar haydenyoung
haydenyoung
7 Apr 2015

Fix for unverified peer/host certificate.

I have added a unit test but have been unable to test as running JHttpTransportTest tests skips all tests. I've also run phpunit --testsuite libraries-cms but I think it is skipping my test also.

Also this needs an https url with a private cert or a cert with an invalid name attribute.

Alternatively, I have run a test in my dev environment using:

$array = array(
    'curl'=>array(
        'ssl'=>array(
            "verifypeer"=false,
            "verifyhost"=>false)));

$options = new \Joomla\Registry\Registry($array);
$http = JFactory::getHttp($options);
...
avatar haydenyoung haydenyoung - open - 7 Apr 2015
avatar joomla-cms-bot joomla-cms-bot - change - 7 Apr 2015
Labels Added: ?
avatar wilsonge
wilsonge - comment - 7 Apr 2015

Sorry to be a pain but can you swap the spaces for tabs back please otherwise travis will definitely fail on the codestyle :)

avatar mbabker
mbabker - comment - 7 Apr 2015

So 2 things:

1) Can you change your settings to keep the tab indentions? As is it looks like you've changed the entire file.
2) In the Framework, we went for a route that allows custom options to be injected for all transports whereas this really only works for the curl SSL options. Take a look at joomla-framework/http#12

avatar haydenyoung
haydenyoung - comment - 7 Apr 2015

2) seems like a much better option than what I'm proposing as it would, as you say, give much more control over all transport settings. My solution was really just an immediate fix to a specific problem.

Will this be merged into the joomla-cms any time soon?


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/6689.
avatar haydenyoung
haydenyoung - comment - 7 Apr 2015

1) are we using PSR-2 requirement of 4 spaces rather than a tab?


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/6689.
avatar mbabker
mbabker - comment - 7 Apr 2015

1) are we using PSR-2 requirement of 4 spaces rather than a tab?

No, we do not follow PSR-2.

avatar haydenyoung
haydenyoung - comment - 7 Apr 2015

Got it. So size 4 tabs.

Anyway I think it would be preferable to use the joomla-framework/http#12 implementation instead.


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/6689.
avatar mbabker
mbabker - comment - 7 Apr 2015

Feel free to PR it in.

avatar wilsonge
wilsonge - comment - 7 Apr 2015

I've PR'd that framework thing in as part of #6692 if it helps :)

avatar zero-24
zero-24 - comment - 7 Apr 2015

@haydenyoung is the PR by @wilsonge a replecement of this PR so this here can be closed?

avatar zero-24 zero-24 - change - 7 Apr 2015
Category Libraries
avatar haydenyoung
haydenyoung - comment - 7 Apr 2015

@zero-24 yes can be closed.

avatar haydenyoung haydenyoung - change - 7 Apr 2015
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2015-04-07 21:47:04
avatar haydenyoung haydenyoung - close - 7 Apr 2015

Add a Comment

Login with GitHub to post a comment