Complete
over 5 years ago

Garmin Connect Mobile 4.22 for Android includes the changes to allow HTTP on 127.0.0.1.

Connect version 4.20 broke local http access?

Getting several reports of functionality no longer working, it looks like Android Garmin connect app version 4.20 may have broken web request to local host via urls like http://127.0.0.1:17580/sgv.json?count=3

Parents
  • Hello, is there please some news or plans regarding this topic? We literally loosing money in these peak seasons days, so I would like to update our strategy regarding this as we so far failed to find usable solution for our Locus Map for Garmin on our side. Thanks

Comment
  • Hello, is there please some news or plans regarding this topic? We literally loosing money in these peak seasons days, so I would like to update our strategy regarding this as we so far failed to find usable solution for our Locus Map for Garmin on our side. Thanks

Children
  • You'll see a difference with GCM Android vs iOS.  You want to use https.

  • While  is correct that we advised switching to HTTPS in 2017, this clearly hasn't been strictly enforced and we apparently had a blind spot with regard to some of these use cases that require HTTP.

    Is this correct now? I find some devices can make http requests and some cannot. Is http blocked by some devices or GCM

  • Since i had some tim today i did some tests

    1. Using android studio i created an android app which did a plain HTTP request to a local webserver (in my case http://<ip>adress/script.php and show the output in a textview

    2. test this code under SDK 26, 28 and 29

    The outcome:

    - when using a webview it worked under all SDK's

    - when using a stringrequest Under SDK26: works perfectly, under SDK28 and 29 i immediately got a timeout error, just like currently happens in the ConnectIQ apps

    So i started studying the official Android documentation (developer.android.com/.../security-config.html) which states that only the defualt changes, but apps who need plainhttp still can use it if they specify it in a network security xml file and i found out there is a very easy fix, which solves all uses cases above

    1. Add  android:networkSecurityConfig="@xml/network_security_config" to the Application section in the manifest

    2. Create a file res/xml/network_security_config with the following contents:

    <?xml version="1.0" encoding="utf-8"?>
    <network-security-config>
    <base-config cleartextTrafficPermitted="true">
    <trust-anchors>
    <certificates src="system" />
    </trust-anchors>
    </base-config>
    </network-security-config>

    I retested and found out the timeout error is gone, my app could do plain HTTP again, also on SDK 28 and 29.

    @Garmin developers: Please implement this fix!!!!!!!!!!!!!!!!!!!!!!!

  • I agree with Jan - with this and other Connect regressions, as well as other CIQ networking limitations that prevent me from providing real functionality, its clear Garmin isn't serious about CIQ and I have adjusted the effort I put it to apps accordingly.