Skip to content
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

Remove the ability to install an app from Tchap #832

Closed
jdauphant opened this issue Feb 3, 2023 · 2 comments
Closed

Remove the ability to install an app from Tchap #832

jdauphant opened this issue Feb 3, 2023 · 2 comments
Labels
android enhancement New feature or request

Comments

@jdauphant
Copy link
Contributor

Your use case

What would you like to do?

No be able to install app from Tchap

Why would you like to do it?

Security purpose

How would you like to achieve it?

Remove REQUEST_INSTALL_PACKAGES

Have you considered any alternatives?

No response

Additional context

No response

Are you willing to provide a PR?

Yes

@jdauphant jdauphant added the enhancement New feature or request label Feb 3, 2023
jdauphant added a commit that referenced this issue Feb 3, 2023
This was referenced Feb 7, 2023
@giomfo giomfo added the android label Feb 13, 2023
@giomfo
Copy link
Contributor

giomfo commented Feb 13, 2023

done in v2.6.2

@giomfo giomfo closed this as completed Feb 13, 2023
@Delphgateau
Copy link
Collaborator

L'ouverture d'une pièce jointe (fichier. apk) entraîne la fermeture de l'application : https://app.crisp.chat/website/6dacc68e-de3a-4511-8177-1339616098de/inbox/session_8e0ed92d-3392-4867-a360-c03f679dbd2e/

Thread: main, Exception: java.lang.SecurityException: Need to declare android.permission.REQUEST_INSTALL_PACKAGES to call this api
at android.os.Parcel.createExceptionOrNull(Parcel.java:2376)
at android.os.Parcel.createException(Parcel.java:2360)
at android.os.Parcel.readException(Parcel.java:2343)
at android.os.Parcel.readException(Parcel.java:2285)
at android.content.pm.IPackageManager$Stub$Proxy.canRequestPackageInstalls(IPackageManager.java:8818)
at android.app.ApplicationPackageManager.canRequestPackageInstalls(ApplicationPackageManager.java:3166)
at com.google.firebase.appdistribution.impl.InstallActivity$$ExternalSyntheticApiModelOutline0.m(Unknown Source:0)
at im.vector.app.features.home.room.detail.TimelineFragment.installApk(TimelineFragment.kt:18)
at im.vector.app.features.home.room.detail.TimelineFragment.startOpenFileIntent(TimelineFragment.kt:13)
at im.vector.app.features.home.room.detail.TimelineFragment.access$startOpenFileIntent(TimelineFragment.kt:1)
at im.vector.app.features.home.room.detail.TimelineFragment$onViewCreated$14.invoke(TimelineFragment.kt:14)
at im.vector.app.features.home.room.detail.TimelineFragment$onViewCreated$14.invoke(TimelineFragment.kt:1)
at im.vector.app.core.platform.VectorBaseFragment$observeViewEvents$1.invokeSuspend(VectorBaseFragment.kt:21)
at im.vector.app.core.platform.VectorBaseFragment$observeViewEvents$1.invoke(Unknown Source:8)
at im.vector.app.core.platform.VectorBaseFragment$observeViewEvents$1.invoke(Unknown Source:4)
at kotlinx.coroutines.flow.FlowKt__TransformKt$onEach$$inlined$unsafeTransform$1$2.emit(Emitters.kt:74)
at kotlinx.coroutines.flow.SharedFlowImpl.collect$suspendImpl(SharedFlow.kt:200)
at kotlinx.coroutines.flow.SharedFlowImpl$collect$1.invokeSuspend(Unknown Source:12)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:9)
at kotlinx.coroutines.DispatchedTaskKt.resume(DispatchedTask.kt:52)
at kotlinx.coroutines.CancellableContinuationImpl.dispatchResume(CancellableContinuationImpl.kt:105)
at kotlinx.coroutines.CancellableContinuationImpl.resumeImpl(CancellableContinuationImpl.kt:44)
at kotlinx.coroutines.CancellableContinuationImpl.resumeWith(CancellableContinuationImpl.kt:17)
at kotlinx.coroutines.flow.SharedFlowImpl.tryEmit(SharedFlow.kt:32)
at im.vector.app.core.utils.PublishDataSource.post(DataSource.kt:3)
at im.vector.app.features.home.room.detail.TimelineViewModel$handleOpenOrDownloadFile$3.invokeSuspend(TimelineViewModel.kt:194)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:9)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:119)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:236)
at android.app.ActivityThread.main(ActivityThread.java:7861)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:600)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:967)
Suppressed: kotlinx.coroutines.DiagnosticCoroutineContextException: [StandaloneCoroutine{Cancelling}@b282279, Dispatchers.Main.immediate]
Caused by: android.os.RemoteException: Remote stack trace:
at com.android.server.pm.PackageManagerService.canRequestPackageInstallsInternal(PackageManagerService.java:25933)
at com.android.server.pm.PackageManagerService.canRequestPackageInstalls(PackageManagerService.java:25905)
at android.content.pm.IPackageManager$Stub.onTransact(IPackageManager.java:4233)
at com.android.server.pm.PackageManagerService.onTransact(PackageManagerService.java:4399)
at android.os.Binder.execTransactInternal(Binder.java:1154)

User-Agent: "Tchap/2.6.2 (Xiaomi Redmi Note 9S; Android 11; RKQ1.200826.002 test-keys; Flavour GooglePlay; MatrixAndroidSdk2 1.5.7)"
Version: "2.6.2 [402060202] (G-120f8a53-2023-02-10 17:39:11 +0100)"
app_language: "fr_FR"
branch_name: "HEAD"
can_contact: "false"
default_app_language: "fr_FR"
device: "Redmi Note 9S"
device_id: "GUOYGYWBYV"
locale: "fr_FR"
matrix_sdk_version: "1.5.7 (120f8a5)"
multi_window: "OFF"
olm_version: "3.2.12 - olm version (3.2.11) - 92769ce-2022-05-30 13:55:34 -0400"
os: "11 (API 30) V12.5.1.0.RJWEUXM-REL"
server_version: "undefined"
theme: "light"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
android enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants