HenrikBengtsson / speedtest-cli-extras

:signal_strength: Tools to enhance the speedtest-cli network tools
120 stars 32 forks source link

https:// #11

Closed stevewrightnz closed 8 years ago

stevewrightnz commented 8 years ago

Hi Henrik Any chance of adding an https:// option to allow everything to run securely and generate https:// paths?

I'm currently using a perl script to tweet the results like so:- speedtest_dev.zip

but it would be nice if I could eliminate some code and have everything run securely :)

SteveW

HenrikBengtsson commented 8 years ago

Hi, thanks for the suggestion.

It looks from your Perl script, that you're asking for the outputted http://www.speedtest.net/result/<id>.png URLs to use HTTPS instead of HTTP, and nothing else. Is this correct?

It turns out that the --secure option of speedtest-cli does this for us (in addition to running the benchmarking over HTTPS), e.g. compare

$ speedtest-cli --share
Retrieving speedtest.net configuration...
Retrieving speedtest.net server list...
Testing from NNNN (x.x.x.x)...
Selecting best server based on latency...
Hosted by nnn (xxxx) [xx.xx km]: 196.545 ms
Testing download speed.......................................
Download: 4.75 Mbit/s
Testing upload speed..................................................
Upload: 1.43 Mbit/s
Share results: http://www.speedtest.net/result/xxxxxxxxxx.png

and

$ speedtest-cli --share --secure
Retrieving speedtest.net configuration...
Retrieving speedtest.net server list...
Testing from NNNN (x.x.x.x)...
Selecting best server based on latency...
Hosted by nnn (xxxx) [xx.xx km]: 196.545 ms
Testing download speed........................................
Download: 5.66 Mbit/s
Testing upload speed..................................................
Upload: 1.45 Mbit/s
Share results: https://www.speedtest.net/result/xxxxxxxxxx.png

So, I guess the easiest and most transparent is simply to mirror this --secure option of speedtest-cli so it can be used also in speedtest-csv, cf. https://github.com/HenrikBengtsson/speedtest-cli-extras/blob/master/bin/speedtest-csv#L132

stevewrightnz commented 8 years ago

Yeah, all I'm doing in my script is substituting 'https' for 'http' on the png file which seems to get the png file securely . This allows my website to serve a secure image. As far as I can tell everything else happens in the open. I did try speedtest-cli-extras/bin/speedtest-csv --secure in my perl script which didn't appear to make any difference.

Steve

HenrikBengtsson commented 8 years ago

I've just pushed speedtest-csv 1.1.2 to the master branch. This new speedtest-csv version will now pass on any command-line options (not explicitly recognized) to speedtest-cli. Thus, --secure can now be specified too.

stevewrightnz commented 8 years ago

Hi Henrik,

Works nicely thank you :-)

Steve

On 06-Jul-16 7:42 AM, Henrik Bengtsson wrote:

Closed #11 https://github.com/HenrikBengtsson/speedtest-cli-extras/issues/11.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/HenrikBengtsson/speedtest-cli-extras/issues/11#event-713485603, or mute the thread https://github.com/notifications/unsubscribe/ACb5nMafzFbgXIPNp5XlC0ST_qkZ-u7Sks5qSrOggaJpZM4JEMvy.


This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus