facebook / flipper

A desktop debugging platform for mobile developers.
https://fbflipper.com/
MIT License
13.34k stars 953 forks source link

Samsung adb run-as problem (Operation not permitted) #92

Open jknoxville opened 6 years ago

jknoxville commented 6 years ago

There's an issue on some samsung builds where inside adb shell, the run-as command doesn't work. You get an 'Operation not permitted' error.

You can test if your device works by running the following inside a terminal, when the device is connected by usb. adb shell run-as com.my.app.package

Where com.my.app.package is replaced with the package name of your app. Note that the app has to be marked "debuggable" in the manifest for this to be allowed.

https://stackoverflow.com/questions/37413667/run-as-could-not-set-capabilities-operation-not-permitted

I've seen this happen on two samsung S8 devices on Android 7. However on Android 8, from anecdotal results it appears to work.

It would be good to: a) Find out whether upgrading to android 8 consistently fixes the issue. b) Find a workaround. We use this feature to securely write the sonar CA certificate to the app's internal data directory over usb. I'm not aware of any other way to do this at the moment.

drooph commented 5 years ago

On and S8 running Android 7 I have been able to fix this issue by going to Developer Options -> Select app to be debugged and then selecting the app you want to debug.

passy commented 5 years ago

I'm cleaning up some old issues and this one hasn't seen updates in a long time. Please let me know if this is still a problem and we can reopen it. Thanks!

Strime commented 5 years ago

I got the same issue on my Galaxy Tab A - Android 7.0, even if I select my app to be debugged on Developer Options.

It works on an other Galaxy Tab A - Android 8.1.

Strime commented 5 years ago

Can you re-open this issue ?

galex commented 4 years ago

Any updates on this? It blocks us from using Flipper at 100%!

Strime commented 4 years ago

Any updates ? :(

KrisGeorges commented 4 years ago

Samsung S8, this problem fixed for me by upgrading from Android 7 to 8.

vkalmath commented 4 years ago

Issue still persists on Samsung S7, with Android 7

stale[bot] commented 4 years ago

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.

stale[bot] commented 4 years ago

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information.

TPXP commented 4 years ago

Same issue on a Galaxy Tab S 10.5 with Android 6.0.1 (the latest it got from Samsung, works on a LineageOS port)

rileyhawk1417 commented 4 years ago

I guess this issue hasn't been fixed am using Samsung galaxy J7 running 6.1 buy nothings happening.

sarog commented 3 years ago

This is also present on Samsung Galaxy Tab E 8.0 devices running Android 7.1.1.

JoeTomkinson commented 3 years ago

Seen this issue present on the latest Samsung S21 running android 11 as well.

AvelinoJavier commented 3 years ago

Same problem on Galaxy S6 Edge..

M-J-Y-21 commented 3 years ago

I'm also having the same issue with a Samsung S7 running android 7 which is the latest update it's got and even with Selecting app to debug it still doesn't work, has anyone come up with a workaround this is really annoying.

SamTobias commented 3 years ago

Same problem on Galaxy J5 with Android 6.0.1

stale[bot] commented 2 years ago

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.

kris1803 commented 2 years ago

Still having issue on s6 edge

numsu commented 1 year ago

image This error keeps popping up whatever I do about it. It's getting in the way of debugger controls and other UI. Please make it stop.

favaztechcurve commented 11 months ago

On and S8 running Android 7 I have been able to fix this issue by going to Developer Options -> Select app to be debugged and then selecting the app you want to debug.

i tried it but still havi9ng same issue with samsung galaxy note 5 android version 7

favaztechcurve commented 11 months ago

anyone got any solution?