WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

Louis LaBrunda
Hi Everyone,

I use the following:

Json readFrom: (ReadStream on: (WebClient httpGet: 'http://freegeoip.net/json/', (WebClient
httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).

to get latitude and longitude from the internet.  It works great on windows but not linux
(Raspbian).  The #primitiveSSLCreate fails.  I expect something linux specific like some FFI or
something is missing.  Anyone have any idea what?

Lou
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe callto://PhotonDemon


Reply | Threaded
Open this post in threaded view
|

Re: WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

Levente Uzonyi
On Wed, 14 Feb 2018, Louis LaBrunda wrote:

> Hi Everyone,
>
> I use the following:
>
> Json readFrom: (ReadStream on: (WebClient httpGet: 'http://freegeoip.net/json/', (WebClient
> httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).
>
> to get latitude and longitude from the internet.  It works great on windows but not linux
> (Raspbian).  The #primitiveSSLCreate fails.  I expect something linux specific like some FFI or
> something is missing.  Anyone have any idea what?

If it worked on Linux before, then you should use the SqueakSSL plugin
from an older VM. The code has been changed recently.
If it never worked before, then you probably don't have openssl 1.0.x
installed.

Levente

>
> Lou
> --
> Louis LaBrunda
> Keystone Software Corp.
> SkypeMe callto://PhotonDemon

Reply | Threaded
Open this post in threaded view
|

Re: WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

timrowledge


> On 14-02-2018, at 1:35 PM, Levente Uzonyi <[hidden email]> wrote:
>
>> Json readFrom: (ReadStream on: (WebClient httpGet: 'http://freegeoip.net/json/', (WebClient
>> httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).

Works fine on my weather station Pi, which is currently running a 5.0-201705051555 vm from.. ooh, last Jun. So definitely before recent ssl related changes.

tim
--
tim Rowledge; [hidden email]; http://www.rowledge.org/tim
Homeopathy: Logic diluted, to make it stronger....


Reply | Threaded
Open this post in threaded view
|

Re: WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

fniephaus
In reply to this post by Louis LaBrunda

On Wed, 14 Feb 2018 at 9:56 pm, Louis LaBrunda <[hidden email]> wrote:
Hi Everyone,

I use the following:

Json readFrom: (ReadStream on: (WebClient httpGet: 'http://freegeoip.net/json/', (WebClient
httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).

to get latitude and longitude from the internet.  It works great on windows but not linux
(Raspbian).  The #primitiveSSLCreate fails.  I expect something linux specific like some FFI or
something is missing.  Anyone have any idea what?

What VM are you using? And what's the output of 'ldd SqueakSSL.so' in the VM plugin directory?

Fabio



Lou
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe <a href="callto://PhotonDemon" target="_blank">callto://PhotonDemon




Reply | Threaded
Open this post in threaded view
|

WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

Louis LaBrunda
In reply to this post by Levente Uzonyi
Hi Levente,

Thanks for the post.  OpenSSL version 1.1.0f is installed.

Lou

>On Wed, 14 Feb 2018, Louis LaBrunda wrote:
>
>> Hi Everyone,
>>
>> I use the following:
>>
>> Json readFrom: (ReadStream on: (WebClient httpGet: 'http://freegeoip.net/json/', (WebClient
>> httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).
>>
>> to get latitude and longitude from the internet.  It works great on windows but not linux
>> (Raspbian).  The #primitiveSSLCreate fails.  I expect something linux specific like some FFI or
>> something is missing.  Anyone have any idea what?
>
>If it worked on Linux before, then you should use the SqueakSSL plugin
>from an older VM. The code has been changed recently.
>If it never worked before, then you probably don't have openssl 1.0.x
>installed.
>
>Levente
>
>>
>> Lou
>> --
>> Louis LaBrunda
>> Keystone Software Corp.
>> SkypeMe callto://PhotonDemon
>
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe callto://PhotonDemon


Reply | Threaded
Open this post in threaded view
|

WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

Louis LaBrunda
In reply to this post by fniephaus
Hi Fabio,

Thanks for the reply.  There is a file called SqueakSSL (no .so) in the /home/pi/squeak/bin
folder.  When I run ldd SqueakSSL I get this:

        linux-vdso.so.1 (0x7ef70000)
        /usr/lib/arm-linux-gnueabihf/libarmmem.so (0x76f95000)
        libcrypto.so.1.0.0 => not found
        libssl.so.1.0.0 => not found
        libc.so.6 => /lib/arm-linux-gnueabihf/libc.so.6 (0x76e41000)
        /lib/ld-linux-armhf.so.3 (0x76fbf000)

I don't like that libcrypto.so.1.0.0 and libssl.so.1.0.0 are not found but I don't know what to
do about it.  Any ideas?

Lou


On Wed, 14 Feb 2018 22:18:30 +0000, Fabio Niephaus <[hidden email]> wrote:

>On Wed, 14 Feb 2018 at 9:56 pm, Louis LaBrunda <[hidden email]>
>wrote:
>
>> Hi Everyone,
>>
>> I use the following:
>>
>> Json readFrom: (ReadStream on: (WebClient httpGet: '
>> http://freegeoip.net/json/', (WebClient
>> httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).
>>
>> to get latitude and longitude from the internet.  It works great on
>> windows but not linux
>> (Raspbian).  The #primitiveSSLCreate fails.  I expect something linux
>> specific like some FFI or
>> something is missing.  Anyone have any idea what?
>
>
>What VM are you using? And what's the output of 'ldd SqueakSSL.so' in the
>VM plugin directory?
>
>Fabio
>
>
>>
>> Lou
>> --
>> Louis LaBrunda
>> Keystone Software Corp.
>> SkypeMe callto://PhotonDemon
>>
>>
>>
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe callto://PhotonDemon


Reply | Threaded
Open this post in threaded view
|

WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

Louis LaBrunda
In reply to this post by timrowledge
Hi Tim,

I'm pretty sure I'm using the VM from here: Squeak5.1-16549-32bit-201608171728-ARMv6.zip.  I
develop on a matching windows version (it's just easier and faster than trying to do it all on
the Raspberry).  Then I copy the image to the Raspberry to test.

Any ideas?

Lou


On Wed, 14 Feb 2018 13:45:43 -0800, tim Rowledge <[hidden email]> wrote:

>
>
>> On 14-02-2018, at 1:35 PM, Levente Uzonyi <[hidden email]> wrote:
>>
>>> Json readFrom: (ReadStream on: (WebClient httpGet: 'http://freegeoip.net/json/', (WebClient
>>> httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).
>
>Works fine on my weather station Pi, which is currently running a 5.0-201705051555 vm from.. ooh, last Jun. So definitely before recent ssl related changes.
>
>tim
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe callto://PhotonDemon


Reply | Threaded
Open this post in threaded view
|

WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

Louis LaBrunda
In reply to this post by timrowledge
Hi Tim,

I tried the SqueakSSL file from Squeak5.0-15120-32bit-r15.27.3397-ARMv6.zip, same problem.

Lou

P.S.  I'm testing on a Raspberry Pi 3 with Raspbian version 9 (stretch).

On Wed, 14 Feb 2018 13:45:43 -0800, tim Rowledge <[hidden email]> wrote:

>
>
>> On 14-02-2018, at 1:35 PM, Levente Uzonyi <[hidden email]> wrote:
>>
>>> Json readFrom: (ReadStream on: (WebClient httpGet: 'http://freegeoip.net/json/', (WebClient
>>> httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).
>
>Works fine on my weather station Pi, which is currently running a 5.0-201705051555 vm from.. ooh, last Jun. So definitely before recent ssl related changes.
>
>tim
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe callto://PhotonDemon


Reply | Threaded
Open this post in threaded view
|

Re: WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

fniephaus
In reply to this post by Louis LaBrunda
Hi Lou,

Could you try again with one of the VMs at [1], for example [2].

Best,
Fabio



--

On Thu, Feb 15, 2018 at 4:19 PM Louis LaBrunda <[hidden email]> wrote:
Hi Fabio,

Thanks for the reply.  There is a file called SqueakSSL (no .so) in the /home/pi/squeak/bin
folder.  When I run ldd SqueakSSL I get this:

        linux-vdso.so.1 (0x7ef70000)
        /usr/lib/arm-linux-gnueabihf/libarmmem.so (0x76f95000)
        libcrypto.so.1.0.0 => not found
        libssl.so.1.0.0 => not found
        libc.so.6 => /lib/arm-linux-gnueabihf/libc.so.6 (0x76e41000)
        /lib/ld-linux-armhf.so.3 (0x76fbf000)

I don't like that libcrypto.so.1.0.0 and libssl.so.1.0.0 are not found but I don't know what to
do about it.  Any ideas?

Lou


On Wed, 14 Feb 2018 22:18:30 +0000, Fabio Niephaus <[hidden email]> wrote:

>On Wed, 14 Feb 2018 at 9:56 pm, Louis LaBrunda <[hidden email]>
>wrote:
>
>> Hi Everyone,
>>
>> I use the following:
>>
>> Json readFrom: (ReadStream on: (WebClient httpGet: '
>> http://freegeoip.net/json/', (WebClient
>> httpGet: 'https://api.ipify.org') content) content utf8ToSqueak).
>>
>> to get latitude and longitude from the internet.  It works great on
>> windows but not linux
>> (Raspbian).  The #primitiveSSLCreate fails.  I expect something linux
>> specific like some FFI or
>> something is missing.  Anyone have any idea what?
>
>
>What VM are you using? And what's the output of 'ldd SqueakSSL.so' in the
>VM plugin directory?
>
>Fabio
>
>
>>
>> Lou
>> --
>> Louis LaBrunda
>> Keystone Software Corp.
>> SkypeMe <a href="callto://PhotonDemon" target="_blank">callto://PhotonDemon
>>
>>
>>
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe <a href="callto://PhotonDemon" target="_blank">callto://PhotonDemon




Reply | Threaded
Open this post in threaded view
|

WebClient httpGet: 'http://freegeoip.net/json/' works on windows not linux

Louis LaBrunda
Hi Fabio,

I tried the VM from your example, no luck.  I don't think this is a VM problem.  I think the
version of Raspbian I'm using (which is the latest) is missing some files.  I just can't figure
out how to install them.

Lou


On Fri, 16 Feb 2018 07:10:52 +0000, Fabio Niephaus <[hidden email]> wrote:
--
Louis LaBrunda
Keystone Software Corp.
SkypeMe callto://PhotonDemon