-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can not connect to my AWS hosted Thingsboard Server using the mobile app #164
Comments
Hello, Your server is CE or PE? |
PE |
I see a lot of 400 errors in your log output. I'm not exactly sure what the issue is, as I can't view the specific APIs related to the 400 errors. However, it seems there may be an issue with the ThingsBoard/mobile app version, or something else might be causing the problem. |
I have the same issue when I upgraded to 3.8 - what thingsboard server version are you running? |
@pgirgis my thingsboard version is 3.6.4. |
@ybeshkarov This is an image of what happens when i run the app on a clean build of thingsboard pe app. Edit: Is there a way to add my ssl certificates to the app in order to ensure that the handshake occurs |
This is an issue with your SSL certificate. Ideally, you need to fix the certificate issue to ensure security, but you can bypass it as well. Inside the
|
Thanks. I got it to work on android. Just out of curiosity, does thingsboard require the entire SSL chain to be signed. |
The core issue ended up being that the server did not provide the full certificate chain but only the leaf certificate. Some browsers hides this kinds of issues if the browser have seen the intermediate certificate somewhere else. So just because things works in the browser, it does not means the server is actually providing enough information for other TLS clients to verify the certificate chain. |
The app is stuck before the login screen, with the thing board logo animation going in circles.
I changed my endpoint to point to the server and i can access it via pc, however not with the flutter app.
I/flutter (30307): dio response ThingsboardError: message: [400: ], errorCode: 31, status: 400
I/flutter (30307): #0 toThingsboardError (package:thingsboard_pe_client/src/error/_thingsboard_error_handler_io.dart:89:18)
I/flutter (30307): #1 HttpInterceptor.onError (package:thingsboard_pe_client/src/interceptor/http_interceptor.dart:104:19)
I/flutter (30307): #2 QueuedInterceptor._handleQueue (package:dio/src/interceptor.dart:401:17)
I/flutter (30307): #3 QueuedInterceptor._handleError (package:dio/src/interceptor.dart:377:5)
I/flutter (30307): #4 DioMixin.fetch.errorInterceptorWrapper..handleError (package:dio/src/dio_mixin.dart:429:22)
I/flutter (30307): #5 new Future. (dart:async/future.dart:256:37)
I/flutter (30307): #6 Timer._createTimer. (dart:async-patch/timer_patch.dart:18:15)
I/flutter (30307): #7 _Timer._runTimers (dart:isolate-patch/timer_impl.dart:398:19)
I/flutter (30307): #8 _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:429:5)
I/flutter (30307): #9 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
I/flutter (30307): ERROR ┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
I/flutter (30307): ERROR │ ThingsboardError: message: [400: ], errorCode: 31, status: 400
I/flutter (30307): ERROR │ #0 toThingsboardError (package:thingsboard_pe_client/src/error/_thingsboard_error_handler_io.dart:89:18)
I/flutter (30307): ERROR │ #1 HttpInterceptor.onError (package:thingsboard_pe_client/src/interceptor/http_interceptor.dart:104:19)
I/flutter (30307): ERROR │ #2 QueuedInterceptor._handleQueue (package:dio/src/interceptor.dart:401:17)
I/flutter (30307): ERROR │ #3 QueuedInterceptor._handleError (package:dio/src/interceptor.dart:377:5)
I/flutter (30307): ERROR │ #4 DioMixin.fetch.errorInterceptorWrapper..handleError (package:dio/src/dio_mixin.dart:429:22)
I/flutter (30307): ERROR │ #5 new Future. (dart:async/future.dart:256:37)
I/flutter (30307): ERROR │ #6 Timer._createTimer. (dart:async-patch/timer_patch.dart:18:15)
I/flutter (30307): ERROR │ #7 _Timer._runTimers (dart:isolate-patch/timer_impl.dart:398:19)
I/flutter (30307): ERROR │ #8 _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:429:5)
I/flutter (30307): ERROR │ #9 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
I/flutter (30307): ERROR │
I/flutter (30307): ERROR ├┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄
I/flutter (30307): ERROR │ ⛔ TbContext.onUserLoaded: ThingsboardError: message: [400: ], errorCode: 31, status: 400
I/flutter (30307): ERROR │ ⛔ #0 toThingsboardError (package:thingsboard_pe_client/src/error/_thingsboard_error_handler_io.dart:89:18)
I/flutter (30307): ERROR │ ⛔ #1 HttpInterceptor.onError (package:thingsboard_pe_client/src/interceptor/http_interceptor.dart:104:19)
I/flutter (30307): ERROR │ ⛔ #2 QueuedInterceptor._handleQueue (package:dio/src/interceptor.dart:401:17)
I/flutter (30307): ERROR │ ⛔ #3 QueuedInterceptor._handleError (package:dio/src/interceptor.dart:377:5)
I/flutter (30307): ERROR │ ⛔ #4 DioMixin.fetch.errorInterceptorWrapper..handleError (package:dio/src/dio_mixin.dart:429:22)
I/flutter (30307): ERROR │ ⛔ #5 new Future. (dart:async/future.dart:256:37)
I/flutter (30307): ERROR │ ⛔ #6 Timer._createTimer. (dart:async-patch/timer_patch.dart:18:15)
I/flutter (30307): ERROR │ ⛔ #7 _Timer._runTimers (dart:isolate-patch/timer_impl.dart:398:19)
I/flutter (30307): ERROR │ ⛔ #8 _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:429:5)
I/flutter (30307): ERROR │ ⛔ #9 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
I/flutter (30307): ERROR │ ⛔
I/flutter (30307): ERROR └───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
I/flutter (30307): DEBUG ┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
I/flutter (30307): DEBUG │ 🐛 LocalDatabaseService::getItem(initialAppLink)
I/flutter (30307): DEBUG └───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
I/flutter (30307): DEBUG ┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
I/flutter (30307): DEBUG │ 🐛 TbContext: On load finished.
I/flutter (30307): DEBUG └───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
I/flutter (30307): ERROR ┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
I/flutter (30307): ERROR │ ThingsboardError: message: [400: ], errorCode: 31, status: 400
I/flutter (30307): ERROR │ #0 toThingsboardError (package:thingsboard_pe_client/src/error/_thingsboard_error_handler_io.dart:89:18)
I/flutter (30307): ERROR │ #1 HttpInterceptor.onError (package:thingsboard_pe_client/src/interceptor/http_interceptor.dart:104:19)
I/flutter (30307): ERROR │ #2 QueuedInterceptor._handleQueue (package:dio/src/interceptor.dart:401:17)
I/flutter (30307): ERROR │ #3 QueuedInterceptor._handleError (package:dio/src/interceptor.dart:377:5)
I/flutter (30307): ERROR │ #4 DioMixin.fetch.errorInterceptorWrapper..handleError (package:dio/src/dio_mixin.dart:429:22)
I/flutter (30307): ERROR │ #5 new Future. (dart:async/future.dart:256:37)
I/flutter (30307): ERROR │ #6 Timer._createTimer. (dart:async-patch/timer_patch.dart:18:15)
I/flutter (30307): ERROR │ #7 _Timer._runTimers (dart:isolate-patch/timer_impl.dart:398:19)
I/flutter (30307): ERROR │ #8 _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:429:5)
I/flutter (30307): ERROR │ #9 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
I/flutter (30307): ERROR │
I/flutter (30307): ERROR ├┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄
I/flutter (30307): ERROR │ #0 toThingsboardError (package:thingsboard_pe_client/src/error/_thingsboard_error_handler_io.dart:89:18)
I/flutter (30307): ERROR │ #1 HttpInterceptor.onError (package:thingsboard_pe_client/src/interceptor/http_interceptor.dart:104:19)
I/flutter (30307): ERROR │ #2 QueuedInterceptor._handleQueue (package:dio/src/interceptor.dart:401:17)
I/flutter (30307): ERROR │ #3 QueuedInterceptor._handleError (package:dio/src/interceptor.dart:377:5)
I/flutter (30307): ERROR │ #4 DioMixin.fetch.errorInterceptorWrapper..handleError (package:dio/src/dio_mixin.dart:429:22)
I/flutter (30307): ERROR │ #5 new Future. (dart:async/future.dart:256:37)
I/flutter (30307): ERROR │ #6 Timer._createTimer. (dart:async-patch/timer_patch.dart:18:15)
I/flutter (30307): ERROR │ #7 _Timer._runTimers (dart:isolate-patch/timer_impl.dart:398:19)
I/flutter (30307): ERROR ├┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄
I/flutter (30307): ERROR │ ⛔ onError
I/flutter (30307): ERROR └───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
E/flutter (30307): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: 'package:flutter/src/material/scaffold.dart': Failed assertion: line 295 pos 7: '_scaffolds.isNotEmpty': ScaffoldMessenger.showSnackBar was called, but there are currently no descendant Scaffolds to present to.
E/flutter (30307): #0 _AssertionError._doThrowNew (dart:core-patch/errors_patch.dart:51:61)
E/flutter (30307): #1 _AssertionError._throwNew (dart:core-patch/errors_patch.dart:40:5)
E/flutter (30307): #2 ScaffoldMessengerState.showSnackBar (package:flutter/src/material/scaffold.dart:295:7)
E/flutter (30307): #3 TbContext.showNotification (package:thingsboard_app/core/context/tb_context.dart:281:32)
E/flutter (30307): #4 TbContext.showErrorNotification (package:thingsboard_app/core/context/tb_context.dart:230:5)
E/flutter (30307): #5 TbContext.onError (package:thingsboard_app/core/context/tb_context.dart:226:5)
E/flutter (30307): #6 ThingsboardClient._onError. (package:thingsboard_pe_client/src/thingsboard_client_base.dart:218:34)
E/flutter (30307): #7 new Future. (dart:async/future.dart:256:37)
E/flutter (30307): #8 Timer._createTimer. (dart:async-patch/timer_patch.dart:18:15)
E/flutter (30307): #9 _Timer._runTimers (dart:isolate-patch/timer_impl.dart:398:19)
E/flutter (30307): #10 _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:429:5)
E/flutter (30307): #11 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
E/flutter (30307):
The text was updated successfully, but these errors were encountered: