Countly not working when i set Private DNS on my mobile device.

Hi

When I set Private DNS on my mobile device, it almost never works.

I discovered that while using the Private DNS: "dns.adguard.com" on my device, not a single event was delivered to countly.

Can an countly event be sent using private DNS in any other ways?

0

Comments

7 comments
  • Official comment

    Hi Mr. Ahire,

    Can you please let us know which SDK you are using and its version? Also can you please enable logs and send us logs with and without the private DNS enabled if possible?

    Comment actions Permalink
  • Hi Deniz Erten

    countly SDK:
        implementation 'ly.count.android:sdk:20.11.10'
        
    DNS: 
        dns.adguard.com

    Log without active DNS:

    2022-11-03 16:27:18.090 23917-23917/com.avodigy.aptadev I/Countly: [Events] Calling recordEvent: [Main Menu]
    2022-11-03 16:27:18.090 23917-23917/com.avodigy.aptadev V/Countly: [ModuleEvents] calling 'recordEventInternal'
    2022-11-03 16:27:18.091 23917-23917/com.avodigy.aptadev D/Countly: [ModuleEvents] Recording event with key: [Main Menu]


    Logs With active DNS:

    2022-11-03 16:28:59.134 24846-24846/com.avodigy.aptadev I/Countly: [Events] Calling recordEvent: [Main Menu]
    2022-11-03 16:28:59.134 24846-24846/com.avodigy.aptadev V/Countly: [ModuleEvents] calling 'recordEventInternal'
    2022-11-03 16:28:59.134 24846-24846/com.avodigy.aptadev D/Countly: [ModuleEvents] Recording event with key: [Main Menu]

     

    2022-11-03 16:29:43.674 24846-25359/com.avodigy.aptadev V/Countly: [onTimer] Calling heartbeat, Activity count:[1]
    2022-11-03 16:29:43.674 24846-25359/com.avodigy.aptadev D/Countly: [ModuleSessions] 'updateSessionInternal'
    2022-11-03 16:29:43.674 24846-25359/com.avodigy.aptadev D/Countly: [Connection Queue] updateSession
    2022-11-03 16:29:43.676 24846-25359/com.avodigy.aptadev V/Countly: [Connection Queue] tick, Not empty:[true], Has processor:[false], Done or null:[true]
    2022-11-03 16:29:43.683 24846-25359/com.avodigy.aptadev D/Countly: [Connection Queue] sendConsentChanges
    2022-11-03 16:29:43.685 24846-25359/com.avodigy.aptadev V/Countly: [Connection Queue] tick, Not empty:[true], Has processor:[false], Done or null:[false]
    2022-11-03 16:29:43.686 24846-25359/com.avodigy.aptadev V/Countly: [Connection Queue] tick, Not empty:[true], Has processor:[false], Done or null:[false]
    2022-11-03 16:29:43.686 24846-25375/com.avodigy.aptadev I/Countly: [Connection Processor] Starting to run, there are [2] requests stored
    2022-11-03 16:29:43.696 24846-25375/com.avodigy.aptadev V/Countly: [Connection Processor] Got picturePath: 
    2022-11-03 16:29:43.696 24846-25375/com.avodigy.aptadev V/Countly: [Connection Processor] Using HTTP GET
    2022-11-03 16:29:43.716 24846-25375/com.avodigy.aptadev V/Countly: [Connection Processor] Using HTTP POST: [false] forced:[false] length:[false] crash:[false] | Approx data size: [632 B]
    2022-11-03 16:29:43.717 24846-25375/com.avodigy.aptadev W/Countly: [Connection Processor] Got exception while trying to submit event data: 

    *****Confidential Information*****

    [java.net.ConnectException: Failed to connect to avodigy.count.ly/:::443]

    0
    Comment actions Permalink
  • Hi Mr. Ahire,

    Thank you for sharing this information. Seems like Adguard is blocking connections to 'count.ly'. Could you please first try to force POST all requests as described here and let us know what happens: https://support.count.ly/hc/en-us/articles/360037754031-Android#forcing-http-post

    0
    Comment actions Permalink
  • Hi Deniz Erten nothing happen after

    Countly.sharedInstance().setHttpPostForced(true);

     

    2022-11-03 17:59:16.723 18757-18757/com.avodigy.aptadev I/Countly: [Events] Calling recordEvent: [Main Menu]
    2022-11-03 17:59:16.723 18757-18757/com.avodigy.aptadev V/Countly: [ModuleEvents] calling 'recordEventInternal'
    2022-11-03 17:59:16.723 18757-18757/com.avodigy.aptadev D/Countly: [ModuleEvents] Recording event with key: [Main Menu]

     

     

    2022-11-03 18:01:32.332 20352-20352/com.avodigy.aptadev D/Countly: Enabling logging
    2022-11-03 18:01:32.333 20352-20352/com.avodigy.aptadev D/Countly: Setting if HTTP POST is forced: [true]
    2022-11-03 18:01:32.337 20352-20778/com.avodigy.aptadev D/nativeloader: Configuring classloader-namespace for other apk /system/framework/org.apache.http.legacy.jar. target_sdk_version=33, uses_libraries=ALL, library_path=/data/app/~~TxGFz6KZA5LoBelTT0Z-Sg==/com.google.android.gms-1HAUd5f6RW_06bIUjW98DQ==/lib/arm64:/data/app/~~TxGFz6KZA5LoBelTT0Z-Sg==/com.google.android.gms-1HAUd5f6RW_06bIUjW98DQ==/base.apk!/lib/arm64-v8a, permitted_path=/data:/mnt/expand:/data/user/0/com.google.android.gms
    2022-11-03 18:01:32.337 20352-20778/com.avodigy.aptadev D/nativeloader: Extending system_exposed_libraries: libcamera_algoup_jni.xiaomi.so:libcamera_mianode_jni.xiaomi.so:libcamera_ispinterface_jni.xiaomi.so:libapuwareapusys.mtk.so:libapuwareapusys_v2.mtk.so:libapuwarexrp.mtk.so:libapuwarexrp_v2.mtk.so:libapuwareutils.mtk.so:libapuwareutils_v2.mtk.so:libapuwarehmp.mtk.so:libmcv_runtime_usdk.mtk.so:libneuron_graph_delegate.mtk.so:libneuronusdk_adapter.mtk.so:libtflite_mtk.mtk.so:libarmnn_ndk.mtk.so:libcmdl_ndk.mtk.so:libnir_neon_driver_ndk.mtk.so:libmvpu_runtime.mtk.so:libmvpu_runtime_pub.mtk.so:libmvpu_engine_pub.mtk.so:libmvpu_pattern_pub.mtk.so:libmvpuop_mtk_cv.mtk.so:libmvpuop_mtk_nn.mtk.so:libteeservice_client.trustonic.so
    2022-11-03 18:01:32.342 20352-20778/com.avodigy.aptadev D/nativeloader: Configuring classloader-namespace for other apk /system/framework/com.android.media.remotedisplay.jar. target_sdk_version=33, uses_libraries=ALL, library_path=/data/app/~~TxGFz6KZA5LoBelTT0Z-Sg==/com.google.android.gms-1HAUd5f6RW_06bIUjW98DQ==/lib/arm64:/data/app/~~TxGFz6KZA5LoBelTT0Z-Sg==/com.google.android.gms-1HAUd5f6RW_06bIUjW98DQ==/base.apk!/lib/arm64-v8a, permitted_path=/data:/mnt/expand:/data/user/0/com.google.android.gms
    2022-11-03 18:01:32.342 20352-20778/com.avodigy.aptadev D/nativeloader: Extending system_exposed_libraries: libcamera_algoup_jni.xiaomi.so:libcamera_mianode_jni.xiaomi.so:libcamera_ispinterface_jni.xiaomi.so:libapuwareapusys.mtk.so:libapuwareapusys_v2.mtk.so:libapuwarexrp.mtk.so:libapuwarexrp_v2.mtk.so:libapuwareutils.mtk.so:libapuwareutils_v2.mtk.so:libapuwarehmp.mtk.so:libmcv_runtime_usdk.mtk.so:libneuron_graph_delegate.mtk.so:libneuronusdk_adapter.mtk.so:libtflite_mtk.mtk.so:libarmnn_ndk.mtk.so:libcmdl_ndk.mtk.so:libnir_neon_driver_ndk.mtk.so:libmvpu_runtime.mtk.so:libmvpu_runtime_pub.mtk.so:libmvpu_engine_pub.mtk.so:libmvpu_pattern_pub.mtk.so:libmvpuop_mtk_cv.mtk.so:libmvpuop_mtk_nn.mtk.so:libteeservice_client.trustonic.so
    2022-11-03 18:01:32.344 20352-20778/com.avodigy.aptadev W/avodigy.aptade: Loading /data/misc/apexdata/com.android.art/dalvik-cache/arm64/system@framework@com.android.location.provider.jar@classes.odex non-executable as it requires an image which we failed to load
    2022-11-03 18:01:32.345 20352-20778/com.avodigy.aptadev D/nativeloader: Configuring classloader-namespace for other apk /system/framework/com.android.location.provider.jar. target_sdk_version=33, uses_libraries=ALL, library_path=/data/app/~~TxGFz6KZA5LoBelTT0Z-Sg==/com.google.android.gms-1HAUd5f6RW_06bIUjW98DQ==/lib/arm64:/data/app/~~TxGFz6KZA5LoBelTT0Z-Sg==/com.google.android.gms-1HAUd5f6RW_06bIUjW98DQ==/base.apk!/lib/arm64-v8a, permitted_path=/data:/mnt/expand:/data/user/0/com.google.android.gms
    2022-11-03 18:01:32.345 20352-20778/com.avodigy.aptadev D/nativeloader: Extending system_exposed_libraries: libcamera_algoup_jni.xiaomi.so:libcamera_mianode_jni.xiaomi.so:libcamera_ispinterface_jni.xiaomi.so:libapuwareapusys.mtk.so:libapuwareapusys_v2.mtk.so:libapuwarexrp.mtk.so:libapuwarexrp_v2.mtk.so:libapuwareutils.mtk.so:libapuwareutils_v2.mtk.so:libapuwarehmp.mtk.so:libmcv_runtime_usdk.mtk.so:libneuron_graph_delegate.mtk.so:libneuronusdk_adapter.mtk.so:libtflite_mtk.mtk.so:libarmnn_ndk.mtk.so:libcmdl_ndk.mtk.so:libnir_neon_driver_ndk.mtk.so:libmvpu_runtime.mtk.so:libmvpu_runtime_pub.mtk.so:libmvpu_engine_pub.mtk.so:libmvpu_pattern_pub.mtk.so:libmvpuop_mtk_cv.mtk.so:libmvpuop_mtk_nn.mtk.so:libteeservice_client.trustonic.so

     

     


    2022-11-03 18:01:32.655 20352-20352/com.avodigy.aptadev D/Countly: Countly onStart called, name:[CmaMainContainerActivity], [0] -> [1] activities now open
    2022-11-03 18:01:32.656 20352-20352/com.avodigy.aptadev D/Countly: [ModuleSessions] 'beginSessionInternal'
    2022-11-03 18:01:32.656 20352-20352/com.avodigy.aptadev D/Countly: [Connection Queue] beginSession
    2022-11-03 18:01:32.659 20352-20352/com.avodigy.aptadev D/Countly: [DeviceInfo, getStore] No store found
    2022-11-03 18:01:32.661 20352-20352/com.avodigy.aptadev V/Countly: [Connection Queue] tick, Not empty:[true], Has processor:[true], Done or null:[true]
    2022-11-03 18:01:32.664 20352-20352/com.avodigy.aptadev D/Countly: Checking referrer: null
    2022-11-03 18:01:32.665 20352-20352/com.avodigy.aptadev D/Countly: Enabling unhandled crash reporting
    2022-11-03 18:01:32.665 20352-20791/com.avodigy.aptadev I/Countly: [Connection Processor] Starting to run, there are [29] requests stored
    2022-11-03 18:01:32.666 20352-20352/com.avodigy.aptadev W/Activity: PerfMonitor: Slow Operation: Activity com.avodigy.aptadev/.memberpediaModules.CmaMainContainerActivity onStart took 158ms
    2022-11-03 18:01:32.667 20352-20791/com.avodigy.aptadev V/Countly: [Connection Processor] Got picturePath: 

     

     

    2022-11-03 18:01:32.695 20352-20791/com.avodigy.aptadev W/Countly: [Connection Processor] Got exception while trying to submit event data: 

    ****Confidential INfo****
     [java.net.ConnectException: Failed to connect to avodigy.count.ly/:::443]

    0
    Comment actions Permalink
  • Hi Mr. Ahire,

    Then instead can you please use your IP address (http://35.226.112.239/) as the server URL instead of https://avodigy.count.ly/ and let us know if it avoids detection.

    0
    Comment actions Permalink
  • Hi Deniz Erten Please obfuscate or mask the IP address. The approach is effective, but could you kindly explain why we must use the http URL rather than a secure URL?

    0
    Comment actions Permalink
  • Do we have any updates about this?

    0
    Comment actions Permalink

Please sign in to leave a comment.