Closed screenio5 closed 2 years ago
Hi, Can you attach the crash's stacktrace please?
Ofc, but how can I get the stacktrace since the app crashes upon startup? Can you please provide instructions?
Trying to follow your suggestion/instructions in [https://gitlab.linphone.org/BC/public/linphone-android#native-crash] I read:
So, I suppose I need to match the SDK debug directory (to be downloaded) with the SDK version reported in the "about" dialog of the Linphone app running in the phone. As stated above, it is reported as "SDK 5.2.0-alpha.195" A "195" version however isnt available to be downloaded. The closest are "194" and "196". Please advise
Did you build the SDK yourself?
No, all I have done is installed the app in the Phone. Dont even have Android Studio
You used one of our nightly snapshot?
Yes, that is correct.
This one: https://download.linphone.org/snapshots/android/linphone-android-release-4.7.0-alpha.231+622275812.apk
Ok I see what APK you used.
Please use https://download.linphone.org/snapshots/android/linphone-android-debug-4.7.0-alpha.255+86cba063d.apk instead.
-release
APK files in snapshots are for out internal use only. I'll remove them.
Ok, I will remove the current version on the phone and install the one you say. Which SDK version must I download from the maven repository?
The one that will match the SDK version in About page.
I have now installed the https://download.linphone.org/snapshots/android/linphone-android-debug-4.7.0-alpha.255+86cba063d.apk as you suggested. I will try to create the native crash logs in the next 24 hours or so.
I just tried to follow the instructions "Native crash" at [https://gitlab.linphone.org/BC/public/linphone-android#native-crash] but failed.
Executing "adb logcat -d | ndk-stack -sym ./libs-debug/adb shell getprop ro.product.cpu.abi | tr -d '\r'
"
results in "'tr' is not recognized as an internal or external command, operable program or batch file."
Please not that I dont have Android Studio installed. I have downloaded and trying to use these: 1) NDK from [https://developer.android.com/ndk/downloads] 2) the SDK manager from [https://developer.android.com/studio/intro/update#sdk-manager] 3) the SDK platform tools for Windows from [https://developer.android.com/studio/releases/platform-tools]
I am trying the best I can but instructions at "Native crash" are not clear enough for someone with zero experience in Android development. Maybe you can provide some more clear directions as to what I need to do?
Can you try using this: adb logcat -d | ndk-stack -sym ./libs-debug/arm64-v8a
Executing "adb logcat -d | ndk-stack -sym ./libs-debug/arm64-v8a" results to (with phone connected to laptop):
Do you see your device when you type adb devices
?
List of devices attached RFCT50M3EBB device
Ok so it is detected. Have you tried running the command again?
By the way, while the command is running you have to reproduce the crash so the stack trace appears.
Same error:
adb logcat -d | ndk-stack -sym ./libs-debug/adb shell getprop ro.product.cpu.abi | tr -d '\r'
'tr' is not recognized as an internal or external command, operable program or batch file.
Keep using adb logcat -d | ndk-stack -sym ./libs-debug/arm64-v8a
instead of the one in the README
ok, this command works, however what does it do? Where does it write so that I can send to you?
It will print in the shell the stacktrace when it will find one. Copy/paste it here after.
But how? Once I execute the command, after a couple of seconds it finishes and I get the command prompt again. There is no way for anything to print in the command line as nothing remains running.
That's not expected. It should run as long as you don't cancel it.
Does it behaves the same if you simply do adb logcat
?
For whatever reason it dumped to screen as soon as the app crashed and while I had re-executed the command. Here is the command line output:
** Crash dump: ** Build fingerprint: 'samsung/a33xnseea/a33x:12/SP1A.210812.016/A336BXXU1AVC9:user /release-keys' WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (BuildId: 3d34f584a2df8c71a5cb0 3d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (dns_res_reset+108) (BuildId: 3 d34f584a2df8c71a5cb03d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (dns_res_close+64) (BuildId: 3d 34f584a2df8c71a5cb03d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (dns_res_open+316) (BuildId: 3d 34f584a2df8c71a5cb03d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (BuildId: 3d34f584a2df8c71a5cb0 3d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (belle_sip_stack_resolve_a+300) (BuildId: 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (belle_sip_channel_resolve+116) (BuildId: 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (belle_sip_client_transaction_s end_request_to+400) (BuildId: 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (LinphonePrivate::SalOp::sendRe questWithContact(_belle_sip_request*, bool)+1372) (BuildId: 3d34f584a2df8c71a5cb 03d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (LinphonePrivate::SalOp::sendRe quest(_belle_sip_request*)+400) (BuildId: 3d34f584a2df8c71a5cb03d4e0d5039e36f8db 00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (LinphonePrivate::SalOp::sendRe questAndCreateRefresher(_belle_sip_request, int, void ()(belle_sip_refresher, void, unsigned int, char const*, int))+20) (BuildId: 3d34f584a2df8c71a5cb03d4e 0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (LinphonePrivate::SalRegisterOp
::sendRegister(std::ndk1::basic_string<char, std::__ndk1::char_traits
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (LinphonePrivate::Account::regi sterAccount()+532) (BuildId: 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00) WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (LinphonePrivate::Account::upda te()+68) (BuildId: 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00)
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/libbctoolbox.so (bctbx_list_for_each+28) (Buil dId: e388a27b78dfb16bc7c6ae07eec474c3c6010c48)
bctbx_list_for_each
/builds/BC/public/linphone-sd
k/build/WORK/android-arm64/Build/bctoolbox/src../../../../../../bctoolbox/src/c ontainers\list.c:172:3 WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00 WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
MNJHdG4ngVZTvx8xmFeLA==/lib/arm64/liblinphone.so (linphone_core_iterate+460) (Bu ildId: 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00)
jni_trampoline+148) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
tub+548) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
ArtInterpreterToCompiledCodeBridge(art::Thread, art::ArtMethod, art::ShadowFra me, unsigned short, art::JValue)+312) (BuildId: 2b417e2566f5eb686666666b6ee952 ea)
ter::DoCall<false, false>(art::ArtMethod, art::Thread, art::ShadowFrame&, art: :Instruction const, unsigned short, art::JValue)+820) (BuildId: 2b417e2566f5eb 686666666b6ee952ea)
1580) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
rect+20) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
MNJHdG4ngVZTvx8xmFeLA==/oat/arm64/base.vdex (org.linphone.core.CoreImpl.iterate+ 130)
Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art:: JValue, bool, bool) (.llvm.7449118509010352383)+644) (BuildId: 2b417e2566f5eb686 666666b6ee952ea)
ArtInterpreterToInterpreterBridge(art::Thread, art::CodeItemDataAccessor const& , art::ShadowFrame, art::JValue*)+148) (BuildId: 2b417e2566f5eb686666666b6ee952 ea)
ter::DoCall<false, false>(art::ArtMethod, art::Thread, art::ShadowFrame&, art: :Instruction const, unsigned short, art::JValue)+1452) (BuildId: 2b417e2566f5e b686666666b6ee952ea)
ce+4912) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
terface+20) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
MNJHdG4ngVZTvx8xmFeLA==/oat/arm64/base.vdex (org.linphone.core.tools.service.Cor eManager$3.run+20)
Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art:: JValue, bool, bool) (.llvm.7449118509010352383)+644) (BuildId: 2b417e2566f5eb686 666666b6ee952ea)
ArtInterpreterToInterpreterBridge(art::Thread, art::CodeItemDataAccessor const& , art::ShadowFrame, art::JValue*)+148) (BuildId: 2b417e2566f5eb686666666b6ee952 ea)
ter::DoCall<false, false>(art::ArtMethod, art::Thread, art::ShadowFrame&, art: :Instruction const, unsigned short, art::JValue)+1452) (BuildId: 2b417e2566f5e b686666666b6ee952ea)
ce+4912) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
terface+20) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
eCallback+4)
2120) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
atic+20) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
tchMessage+8)
+2292) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
rtual+20) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
ce+334)
2120) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
2120) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
atic+20) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
52)
620) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
atic+20) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
ad.main+214)
Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art:: JValue, bool, bool) (.llvm.7449118509010352383)+644) (BuildId: 2b417e2566f5eb686 666666b6ee952ea)
terBridge+1176) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
preter_bridge+88) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
tatic_stub+568) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
okeMethod<(art::PointerSize)8>(art::ScopedObjectAccessAlreadyRunnable const&, _j object, _jobject, _jobject*, unsigned long)+608) (BuildId: 2b417e2566f5eb68666 6666b6ee952ea)
(_JNIEnv, _jobject, _jobject, _jobjectArray)+52) (BuildId: 2b417e2566f5eb686 666666b6ee952ea)
mpoline+132) (BuildId: ad9ee401645a5135206a62ff86fc2ef5cdc29120)
tub+548) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
ArtInterpreterToCompiledCodeBridge(art::Thread, art::ArtMethod, art::ShadowFra me, unsigned short, art::JValue)+312) (BuildId: 2b417e2566f5eb686666666b6ee952 ea)
ter::DoCall<false, false>(art::ArtMethod, art::Thread, art::ShadowFrame&, art: :Instruction const, unsigned short, art::JValue)+820) (BuildId: 2b417e2566f5eb 686666666b6ee952ea)
+5380) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
rtual+20) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
RuntimeInit$MethodAndArgsCaller.run+22)
Execute(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame&, art:: JValue, bool, bool) (.llvm.7449118509010352383)+644) (BuildId: 2b417e2566f5eb686 666666b6ee952ea)
terBridge+1176) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
preter_bridge+88) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
nternal.os.ZygoteInit.main+2376) (BuildId: abbb706ebfb3f3f9ff279e470d8d8bb691630 cc5)
tatic_stub+568) (BuildId: 2b417e2566f5eb686666666b6ee952ea)
nvokeWithVarArgs<_jmethodID>(art::ScopedObjectAccessAlreadyRunnable const&, _jo bject, _jmethodID*, std::__va_list)+464) (BuildId: 2b417e2566f5eb686666666b6ee9 52ea)
llStaticVoidMethodV(_JNIEnv, _jclass, _jmethodID*, std::__va_list)+268) (Build Id: 2b417e2566f5eb686666666b6ee952ea)
oidMethod(_jclass, _jmethodID, ...)+120) (BuildId: c969ed538d679fba4bc11565cc4 c7caa)
ime::start(char const*, android::Vector
adb2c16025825ba2227ee34)
it+96) (BuildId: 1c37cae0a1a20a75f215af2188f648d5) Crash dump is completed
Thanks but it seems you aren't using the right libs-debug version according to these logs:
WARNING: Mismatched build id for ./libs-debug/arm64-v8a\liblinphone.so
WARNING: Expected 3d34f584a2df8c71a5cb03d4e0d5039e36f8db00
WARNING: Found 0e811165632c4c5fac2d145949d58a976ab12039
In the about dialog of the app which is version 4.7.0-alpha.255 it reports the SDK as 5.2.0-alpha.208+923454a
The SDK I have downloaded is: linphone-sdk-android-debug-5.2.0-alpha.208+923454a.aar
So, how come there is the mismatch?
That is surprising, I'll investigate.
Could you attach logs from the start of the to the moment it crashes using adb logcat
command please?
Start the command then start the app and copy/paste here everything reported by logcat.
Thanks in advance.
See attached. App as always crashed
Thanks. It seems it is a network access permission denial that's causing our DNS resolver to crash:
06-21 17:39:44.588 5291 5291 I Linphone: Creating listening point [0x7a00931730] on [sip:[::0]:-1;transport=UDP]
06-21 17:39:44.588 5291 5291 E Linphone: Cannot create UDP socket: Operation not permitted
06-21 17:39:44.588 5291 5291 I Linphone: Listening point [0x7a00931730] on [sip:[::0]:-1;transport=UDP] destroyed
06-21 17:39:44.588 5291 5291 I Linphone: Creating listening point [0x7a00931730] on [sip:[::0]:-1;transport=TCP]
06-21 17:39:44.588 5291 5291 E Linphone: Cannot create TCP socket: Operation not permitted
06-21 17:39:44.588 5291 5291 I Linphone: Listening point [0x7a00931730] on [sip:[::0]:-1;transport=TCP] destroyed
06-21 17:39:44.588 5291 5291 I Linphone: Creating listening point [0x7a00931730] on [sip:[::0]:-1;transport=TLS]
06-21 17:39:44.588 5291 5291 E Linphone: Cannot create TCP socket: Operation not permitted
[...]
06-21 17:39:45.252 5291 5291 E Linphone: get_local_ip_for_with_connect() could not create [AF_INET6] socket: Operation not permitted
06-21 17:39:45.252 5291 5291 E Linphone: get_local_ip_for_with_connect() could not create [AF_INET] socket: Operation not permitted
06-21 17:39:45.252 5291 5291 E Linphone: get_local_ip_for_with_connect() could not create [AF_INET] socket: Operation not permitted
I believe it's linked to KNOX but I don't know what/if you can do about it. Maybe this issue is related to this Android crash stack trace I can see in your logs:
06-21 17:39:44.972 1100 3956 W System.err: android.content.pm.PackageManager$NameNotFoundException: org.linphone.debug
06-21 17:39:44.972 1100 3956 W System.err: at android.app.ApplicationPackageManager.getApplicationInfoAsUser(ApplicationPackageManager.java:539)
06-21 17:39:44.972 1100 3956 W System.err: at android.app.ApplicationPackageManager.getApplicationInfo(ApplicationPackageManager.java:492)
06-21 17:39:44.972 1100 3956 W System.err: at com.android.server.wm.WindowState.<init>(WindowState.java:1384)
06-21 17:39:44.972 1100 3956 W System.err: at com.android.server.wm.WindowState.<init>(WindowState.java:1165)
06-21 17:39:44.972 1100 3956 W System.err: at com.android.server.wm.WindowManagerService.addWindow(WindowManagerService.java:1841)
06-21 17:39:44.972 1100 3956 W System.err: at com.android.server.wm.Session.addToDisplayAsUser(Session.java:211)
06-21 17:39:44.972 1100 3956 W System.err: at android.view.IWindowSession$Stub.onTransact(IWindowSession.java:691)
06-21 17:39:44.972 1100 3956 W System.err: at com.android.server.wm.Session.onTransact(Session.java:176)
06-21 17:39:44.972 1100 3956 W System.err: at android.os.Binder.execTransactInternal(Binder.java:1220)
06-21 17:39:44.972 1100 3956 W System.err: at android.os.Binder.execTransact(Binder.java:1179)
I'll try to fix the crash but I believe it won't make the app work anyway if it can't connect to the network...
I remind you that when you leave the app ALSO outside knox (the secure folder), the app IN the secure folder never crashes and works fine. If you uninstall the app outside the secure folder, the app IN the secure folder keeps on working fine UNTIL you restart the phone. When you do, the app always crashes (as if something that existed outside the secure folder satisfied the inside secure folder app and when it gets removed it doesnt satisfies it any more)
It seems to me to be likely a bug in either Samsung KNOX feature given the particular scenario to reproduce the issue and the lack of information in the system logs.
I'll try to reproduce it on my device, but in the meantime do you have the same behavior (app can't access Internet) with any other app following the same process?
Absolutely not! Only Linphone crashes. Any other app (which needs and access internet) when moved into secure folder AND uninstalled outside the secure folder works fine (even after phone restarts). Please focus on the fact that when you DONT uninstall Linphone from outside secure folder, the instance IN the secure folder works always absolutely fine (even when you restart the phone). It is when you UNINSTALL from outside the secure folder and you restart the phone that Linphone begins to crash. In my opinion it is somehow related to some kind of file/directory requirement (which it doesnt find and therefore crashes).
In my opinion also you must enable secure folder and have a working phone/environment on your own in order to troubleshoot this.
Please focus on the fact that when you DONT uninstall Linphone from outside secure folder, the instance IN the secure folder works always absolutely fine (even when you restart the phone). It is when you UNINSTALL from outside the secure folder and you restart the phone that Linphone begins to crash.
Yes, I understood.
In my opinion it is somehow related to some kind of file/directory requirement (which it doesnt find and therefore crashes).
Not it's not. Linphone doesn't rely on much files, and given the logs from before the crash everything is fine from that point. The only real issue is why we aren't allowed to create sockets, and I'm quite sure this issue is out of our hands.
In my opinion also you must enable secure folder and have a working phone/environment on your own in order to troubleshoot this.
That we can agree on.
"The only real issue is why we aren't allowed to create sockets, and I'm quite sure this issue is out of our hands."
But if its a socket allowance issue, how can you explain the fact that when the outside secure folder linphone exists, the inside works fine? Theoretically, each instance does NOT see the other, therefore the inside knows nothing about the outside and whatever socket(s) the outside has created/creates should play no role for the inside one!
Furthermore, if KNOX did not allow socket creation I dont see how anything would work inside the secure folder. In previous versions of KNOX and Android Linphone worked fine in the secure folder. Something obviously has changed lately either in Android and/or KNOX but this seems to have an effect only in Linphone and none of any other apps I have tried (regardless of whether I keep the original instance outside secure folder or not).
I can confirm this is a KNOX issue as I don't reproduce this problem with my Samsung device (everything is up-to-date) following the same steps as you. So either you are not up-to-date and this issue has been fixed or this is an issue specific to your device.
Have you enabled secure folder? If yes, please let me know of the KNOX and Android version. Have you uninstalled the outside secure folder linphone? If yes, have you restarted the phone?
I can confirm that this happens on several phones, not only with the one in my hands.
Have you enabled secure folder? If yes, please let me know of the KNOX and Android version. Have you uninstalled the outside secure folder linphone? If yes, have you restarted the phone?
Yes I did all that, following your instructions... Please stop considering I'm a moron, I'm simply trying to help you and you're being a bit aggressive.
Know version is 3.8 (API level 35), secure folder version is 1.7.02.5, software version is One UI 4.1 (security patch from June 16 2022) Kernel 4.19.113-24299070
No no no!!! You misunderstood me! I thank you immensely for trying to help me out and I apologize if my tone of voice/texting was misunderstood
Know version is 3.8 (API level 35), secure folder version is 1.7.02.5, software version is One UI 4.1 (security patch from June 16 2022) Kernel 4.19.113-24299070
Hmmm, we have some discrepancies:
KNOX: same (3.8 (API level 35)) Secure folder: 1.7.01.67 (but says latest version is installed and there is no option to somehow upgrade it) One UI: 4.1 Kernel: 5.10.43
I also have everything updated. Which phone model is yours?
Which phone model is yours?
It's a Z Fold 2.
I just received a brand new A33 in its box. I will set it up from scratch, will not install anything else apart from Linphone and enable secure folder.
I can reproduce the crash on a Samsung Galaxy S10 with secure folder version 1.7.02.5 with KNOX 3.8 (API level 35) One UI 4.1 from May 2022. So maybe it has been fixed in June firmware update.
By the way I fixed the crash in DNS resolver, Linphone app still can't register (due to socket creation permission denial) and thus will be useless.
Can you please provide this special built so I try?
I tried the special built. App does not crash anymore (when instance outside secure folder has been uninstalled) BUT like you said. it fails to register on the SIP server. As soon as I installed the app outside the secure folder, the inside instance connected IMMEDIATELY! What I dont understand is how and why the outside is correlated with the inside one regarding the socket creation permission and why this didnt happen in previous Android/Knox versions.
Is there any workaround you might think of? I understand that if you need permissions and you are not granted there is obviously nothing you cant do, if for example you are granted the permissions some seconds later after the app has fully started?
What I dont understand is how and why the outside is correlated with the inside one regarding the socket creation permission and why this didnt happen in previous Android/Knox versions.
I don't understand it either, I believe this is merely a bug since it seems to have been fixed in latest firmware.
Is there any workaround you might think of? I understand that if you need permissions and you are not granted there is obviously nothing you cant do, if for example you are granted the permissions some seconds later after the app has fully started?
No there are not. INTERNET permission is automatically granted to the app the moment it is installed, it is not part of the permissions that have to be requested to the user.
I am a little bit confused. Please correct me if I got it wrong so far:
1) You have a Z Fold 2 with the following versions:
KNOX: 3.8 (API level 35) Secure folder: 1.7.02.5 One UI: 4.1 security patch from June 16 2022 Kernel: 4.19.113-24299070
In this phone Linphone never crashes and connects fine to SIP server (1st instance outside secure folder removed and phone has been restarted)
2) You also have a Galaxy S10 with:
KNOX: 3.8 (API level 35) Secure folder: 1.7.02.5 One UI: 4.1 from May 2022 Kernel: ?
In this phone Linphone crashes like mine
3) I have several A33 (and now I just setup a brand new one) which all have:
KNOX: 3.8 (API level 35) Secure folder: 1.7.01.67 One UI: 4.1 Kernel: 5.10.43
All ofc crash.
The only apparent difference -like you mentioned- is the "June 16" update which is not available for my A33 phones (and I assume also yours).
Furthermore, what confuses me totally is this:
1) I install Linphone and then add it to secure folder. In secure folder I setup a SIP account and it connects 2) I restart the phone. Linphone inside secure folder still works fine 3) I remove Linphone from outside secure folder. Inside still works fine 4) Restart the phone. Inside does not connect to sip server anymore (here it would crash) 5) I install Linphone outside and I dont touch it! (not even open it) 6) I go into the Linphone inside secure folder and now it has connected to the sip server!!!!
I fail to understand why the presence -and only the presence- of the app outside secure folder allows the inside one to create sockets and resolve dns names. I am totally baffled
Please correct me if I got it wrong so far
You are right. The device that crashes in on May 2022 security patch, the one that works fine is on June 2022 security patch.
I fail to understand why the presence -and only the presence- of the app outside secure folder allows the inside one to create sockets and resolve dns names. I am totally baffled
You don't have to understand as there is probably no other correlation than a bug in how KNOX & secure folder work. For example it might simply be that the system no longer as access to the app's Manifest and thus doesn't grant the INTERNET permission or something like that. You may want to send this feedback to Samsung if there is a way to notify them of issues in their softwares/firmwares.
Describe the bug Whan app is started INSIDE Samsung KNOX, app crashes immediately
To Reproduce Steps to reproduce the behavior:
The above behavior did not occur prior to Android 12 & KNOX 3.8
Please complete the following information
SDK logs Cant have logs as app crashes immediately upon start
Additional context Up to Android 11 running Samsung KNOX 3.7 app was working always fine INSIDE KNOX