[Solved] Disable MTP For Security - Samsung Galaxy Nexus

Hi,
I'd like to disable USB everything (MTP, ADB, whatever the camera mode is) on my phone for security reasons. Currently if I plug my phone into a computer (even with the screen locked), I can download data via gMTP. I read here: http://www.nimdae.com/?p=851 that encrypting my phone won't solve this problem.
I still want to encrypt my phone, but if I can't disable MTP, then I'm not that interested.
How can I disable USB stuff completely? I know how to turn off ADB, and the phone lets me select betwene MTP and camera mode under settings->storage->USB Connection Settings, but it won't let me select neither option, only one or the other.
In older versions of Android, when I connect a phone to a computer, I get a message on screen telling me that it's connected and that I can enable mass storage if I like. I get that the reason they had that message was because they _needed_ it because mass storage had to unmount the SD card for it to work. However, how can I get something like that back for MTP?
If there's not a GUI way to disable this stuff, is there a setting for "persist.sys.usb.config" that would disable it instead?
I just don't want to waste the effort of dealing with phone encryption if plugging it into a computer completely avoids the issue.
Edit: I'm on a VZW LTE/CDMA gNex on JB Sourcery 2.3, but I'd be willing to migrate ROMs if necessary.

kbitz said:
Hi,
I'd like to disable USB everything (MTP, ADB, whatever the camera mode is) on my phone for security reasons. Currently if I plug my phone into a computer (even with the screen locked), I can download data via gMTP. I read here: http://www.nimdae.com/?p=851 that encrypting my phone won't solve this problem.
I still want to encrypt my phone, but if I can't disable MTP, then I'm not that interested.
How can I disable USB stuff completely? I know how to turn off ADB, and the phone lets me select betwene MTP and camera mode under settings->storage->USB Connection Settings, but it won't let me select neither option, only one or the other.
In older versions of Android, when I connect a phone to a computer, I get a message on screen telling me that it's connected and that I can enable mass storage if I like. I get that the reason they had that message was because they _needed_ it because mass storage had to unmount the SD card for it to work. However, how can I get something like that back for MTP?
If there's not a GUI way to disable this stuff, is there a setting for "persist.sys.usb.config" that would disable it instead?
I just don't want to waste the effort of dealing with phone encryption if plugging it into a computer completely avoids the issue.
Edit: I'm on a VZW LTE/CDMA gNex on JB Sourcery 2.3, but I'd be willing to migrate ROMs if necessary.
Click to expand...
Click to collapse
Stock Jelly Bean won't enable MTP/PTP until you have unlocked your lockscreen. The same goes for CM10 by the way. It seems that JB Sourcery modified this behavior.

You could try enabling USB fast charge mod using a custom kernel (when enabled, phone see computer as an ac charging source, disabling USB data connection PC and only charges, but at a higher rate).
Other than that, I'm not sure.
Also, encryption only works really at boot time and shutdown time. When you shut down, everything is "locked" and upon booting up, it requires the key to "in lock" everything. But once it's" unlocked" it stays that way until you reboot.
Sent from my Galaxy Nexus using Tapatalk 2

geoffcorey said:
You could try enabling USB fast charge mod using a custom kernel (when enabled, phone see computer as an ac charging source, disabling USB data connection PC and only charges, but at a higher rate).
Click to expand...
Click to collapse
Thanks.
Also, encryption only works really at boot time and shutdown time. When you shut down, everything is "locked" and upon booting up, it requires the key to "in lock" everything. But once it's" unlocked" it stays that way until you reboot.
Click to expand...
Click to collapse
Yes, this is the reason why I'd like to be able to disable MTP. My point was that it's not worth the hassle of encrypting the data at rest if all anybody would have to do to get the data off was plug it into a computer. Like most people, my cell phone is running all the time. We can force action after a bunch of failed passwords, but if the attacker doesn't have to interact with the unlock screen at all, then there's no protection there.
Petrovski80 said:
Stock Jelly Bean won't enable MTP/PTP until you have unlocked your lockscreen. The same goes for CM10 by the way. It seems that JB Sourcery modified this behavior
Click to expand...
Click to collapse
Thanks! This was the ticket. Here's what I failed to notice: Once I've unlocked the screen while it's plugged in, I have MTP for the entirety of the time it's plugged in, even if the phone is locked again before the connection is started. If, however, I plug it in locked and don't unlock it before starting the connection, I get nothing.
I'm marking this solved.
Thanks so much to both of you.

Disable MTP in Samsung Tab A
Hello,
I have a samsung Tab A 2016 (SM-T580) & in developer options i put the USB configuration into charging mode, & turn the developer options off. But whenever i plug it into a PC it turns into MTP automatically & I want to disable this. Any help please?

Related

USB Connected but doesn't show up on my mac

How come the internal storage and the sd card doesn't show up on my mac? I can see that it is recognizing the phone though.
Tried it with windows 7 on parallels too for some reason they don't show up as drives. Can't seem to figure out why.
It's not on by default, you have to go to Settings>Wireless And Networks>USB Utilities>Connect Storage To PC
After you connect your phone to your computer, on your phone, bring down your notifications and click usb and then click connect usb data mode or whatever it's called. I had the same problem until I found out how it worked.
Both above answers don't give the full story. The default connectivity mode for the phone is a media connectivity mode that simplifies the process and allows you to access your data without unmounting the storage, but it's only supported by Windows. Macs can't connect that way.
86apex's information is one correct way to turn on the more typical mode that will then work with your Mac. It's just not that it's not on by default, it's just that the mode that IS on isn't supported by your system.
Megatr0n.'s instructions are only valid if you have USB debugging mode turned on. Otherwise you wouldn't see what he (I'm assuming) is describing. That said, turning on that mode (Settings/Applications/Development/USB debugging) and enabling that menu option would be easier than going through the steps 86apex listed every single time you want to connect.

Having trouble with eg30aut0 due to usb?

Hi all,
Of course I'm a newbie here.
I'm a former Precentral webos person who finally made the jump over to Android.
So far I am loving it, the only thing I really miss is the true multitasking, which seems to get in the want of working like I did on the Pre.
But I've moved on...
Anyway, when on the Pre it was so much easier to get into developer mode and make changes to the OS, it seems a bit more crypt and more involved here. So I am trying to be extra careful, which is why it's taken more 3 or so month before even attempting what I believe is the simplest of procedures. Just to root, no custom roms yet for me.
I followed the instructions over in the 'eg30Auto' thread that was recommended on Android Central.
I have everything ready and installed.
So now my issue is the stupid USB thing.
The instructions are to keep the USB debugging on! That was easy, I just went into settings and selected the check box.
But then next part of the instructions is the 'disable' the usb connection.
That is where I seem to be having trouble.
When I plug my phone in, under notifications, it's saying USB Connect (MTP).
I touch that which I thought would trigger it to become disabled. But that does not work.
And now I don't know how to disable that usb connected.
I did the 'runfirst' under the eg30auto directory and in the command prompt screen is it saying it's waiting for a device to be connected?
So that's where I'm stuck at, I'm not sure how to turn off this USB connected thing.
I did install the Samsung USB drivers which I believe I was supposed to.
So I'm at a loose right now and need your help!
Thanks guys!
Rob (if it makes it easier, I would welcome a private voice call).
If you enabled USB debugging, I believe it should disable MTP mode.
There is a mode where the internal /sdcard is made available as USB mass storage (ie you plug it into your PC and it becomes available as a *drive letter*). This is what the second part is asking you to disable, because if the internal /sdcard is made available as a drive on your PC, it is not accessible from within Android.
Note, MTP mode and USB mass storage mode are not the same. The former will show up on your PC but not have a drive letter. Mass Storage mode will show up as a drive letter.
If you are having trouble with the USB connection w/r/t auto root see FAQ #E3 in the second post of that auto root thread. There is a debugging checklist there.
e3) Why is the install stuck waiting for device to be connected?

Bypass LockScreen and access USB data

When connected via USB to the PC, the GNex only displays USB contents if the lock screen is unlocked. What surprised me was when I plugged the USB cable, just after the boot animation started, the entire contents were available even before the lock screen was unlocked, I could access all folders. I started rebooting to find out how repeatable it is. If I hit F5 on the PC and keep refreshing 'my computer' it seems to have a higher chance to allow you to access data without unlocking. The phone is rooted 4.2.2 stock ROM, stock kernel (initially saw this with Franco`s, swapped to stock kernel to make sure its happening on stock kernel also). The bootloader is locked and USB debugging is disabled, I see no reason why the USB contents should be accessible without unlocking the phone. I did do a couple of searches with USB and lock screen bypass and came up with no other thread, if this has been a known scenario I apologize for starting a new thread.
Just wanted to know if it was something I did which was causing this or if it was a common scenario.
Have you checked Google groups under Android?
Sent from my Galaxy Nexus using Tapatalk 2

[Q] galaxy nexus troubleshooting help please

hi, i got this sgn from a friend with a broken screen, and ive now replaced the screen and the phone turns on and boots up no problem. but when i plug it in to my puter, it says usb device not recognized, one ot the usb devices attached.... as well in settings the wifi on/off toggle starts greyed out, if i go into the wifi setup, i can push the toggle and it says turning on wifi, but then after about 20 seconds or so, it just flicks the toggle back to off. bluetooth if i press the toggle, it instantly flicks back to off, and wont turn/stay on. and the last thing i have noticed that is not right, is when i try to go into the camera, it just f/c's and says gallery has has stopped, yet if i go into the gallery, it comes up. but f/c's if i try to access the camera.. i am thinking its probably a hardware issue, just was wondering if anyone might be able to give me any extra insight or suggestions, thanks in advance.
edit: oh, and the phone charges through the usb port, which i find weird that the puter wont recognize it...
slickwidnick said:
hi, i got this sgn from a friend with a broken screen, and ive now replaced the screen and the phone turns on and boots up no problem. but when i plug it in to my puter, it says usb device not recognized, one ot the usb devices attached.... as well in settings the wifi on/off toggle starts greyed out, if i go into the wifi setup, i can push the toggle and it says turning on wifi, but then after about 20 seconds or so, it just flicks the toggle back to off. bluetooth if i press the toggle, it instantly flicks back to off, and wont turn/stay on. and the last thing i have noticed that is not right, is when i try to go into the camera, it just f/c's and says gallery has has stopped, yet if i go into the gallery, it comes up. but f/c's if i try to access the camera.. i am thinking its probably a hardware issue, just was wondering if anyone might be able to give me any extra insight or suggestions, thanks in advance.
edit: oh, and the phone charges through the usb port, which i find weird that the puter wont recognize it...
Click to expand...
Click to collapse
hey,
if you don't mind rooting and phone is not underwarranyty, try: wugfresh nexus toolkit
or cyanogemod.org
may help fix...... and both are automated very easy.
gnexususer said:
hey,
if you don't mind rooting and phone is not underwarranyty, try: wugfresh nexus toolkit
or cyanogemod.org
may help fix...... and both are automated very easy.
Click to expand...
Click to collapse
Yeah, see the problem is my computer won't recognize the phone to be able to perform any of the functions of the toolkit... So I don't know what options (if any) I have...
slickwidnick said:
Yeah, see the problem is my computer won't recognize the phone to be able to perform any of the functions of the toolkit... So I don't know what options (if any) I have...
Click to expand...
Click to collapse
try reboot to odin bootloader. long press volume down + power button. can u boot it up?
memaro_maro said:
try reboot to odin bootloader. long press volume down + power button. can u boot it up?
Click to expand...
Click to collapse
yeah, ive got a usb jig to boot it into odin download mode, but i think i tried it but the computer still didnt recognize it, ill try it again and let you nkow what happens.. also, i have another working sgn here, and i switched out the boards, cause the usb port is not on the mainboard, it is connected by a flex ribbon (thinking it may be a faulty usb port) but either one generates the same results..
You dont need Odin. Just use fastboot and flash the latest Factory image. There are plenty of guides on how to do that. Good luck! If you cant get it to work just let me know.
Sent from my Galaxy Nexus using XDA Premium HD app
slickwidnick said:
yeah, ive got a usb jig to boot it into odin download mode, but i think i tried it but the computer still didnt recognize it, ill try it again and let you nkow what happens.. also, i have another working sgn here, and i switched out the boards, cause the usb port is not on the mainboard, it is connected by a flex ribbon (thinking it may be a faulty usb port) but either one generates the same results..
Click to expand...
Click to collapse
correctly install/setup adb & fastboot first & try ~
http://forum.xda-developers.com/showthread.php?t=2588979
if still not recognize ur device use odin tool, from odin bootloader
odin ~
http://forum.xda-developers.com/galaxy-nexus/general/guide-restore-to-stock-unbrick-galaxy-t2065470
memaro_maro said:
correctly install/setup adb & fastboot first & try ~
http://forum.xda-developers.com/showthread.php?t=2588979
if still not recognize ur device use odin tool, from odin bootloader
odin ~
http://forum.xda-developers.com/galaxy-nexus/general/guide-restore-to-stock-unbrick-galaxy-t2065470
Click to expand...
Click to collapse
okay i tried your advice, but the computer still fails to recognize the phone, i installed the drivers, cause the computer picks up the other sgn that i have here, i just unplugged the one thats fine, and plugged in the one i am trying to fix ant it doesnt do anything,...
Go to System Settings -> Storage -> 3 dots -> USB connection, and set MTP ON (V)
and if that doesn't work, try another DATA cable
.
Ed V said:
Go to System Settings -> Storage -> 3 dots -> USB connection, and set MTP ON (V)
and if that doesn't work, try another DATA cable
.
Click to expand...
Click to collapse
tried setting mtp on, tried setting ptp on, tried setting debugging mode off and on, tried a different cable, still nothing..
something i did notice was that i have another sgn here and i went to the storage settings, and i was able to uncheck both mtp and ptp and my computer installed a new device "samsung something something" cant remember what the new device was tho..
oh and the bootloader is locked on the sgn im trying to fix and it is unlocked on the second sgn i have here...
could that have something to do with any of this?

Verizon Software Upgrade Assistant needed

Hi,
Looks like I need to restore my phone to stock in order to install an OTA. However, when I connect my phone to my Windows PC (or MAC for that matter), I don't get the prompt to install the Verizon Software Upgrade Assistant. Somehow this is missing on my phone.
This must be in some sort of autorun location on the phone. Can someone please copy it over for me and upload it somewhere? I am really stuck without it.
EDIT: I figured it out, if someone runs into the same issue: The phone needs to be connected to the PC as an installer. You can tell if it displays the notification "Connected as an installer", rather than MTP, camera, or charging. Since this mode is not one of the options you can select in the settings, it's still not 100% clear to me how you get to this mode. I was able to get into it only when my phone was locked and showing the lock screen. So try cycling through the various USB options and then lock your phone, it should get you there eventually.
konradsa said:
Hi,
Looks like I need to restore my phone to stock in order to install an OTA. However, when I connect my phone to my Windows PC (or MAC for that matter), I don't get the prompt to install the Verizon Software Upgrade Assistant. Somehow this is missing on my phone.
This must be in some sort of autorun location on the phone. Can someone please copy it over for me and upload it somewhere? I am really stuck without it.
EDIT: I figured it out, if someone runs into the same issue: The phone needs to be connected to the PC as an installer. You can tell if it displays the notification "Connected as an installer", rather than MTP, camera, or charging. Since this mode is not one of the options you can select in the settings, it's still not 100% clear to me how you get to this mode. I was able to get into it only when my phone was locked and showing the lock screen. So try cycling through the various USB options and then lock your phone, it should get you there eventually.
Click to expand...
Click to collapse
I have the same issue, but your method isn't working for me yet. Should USB debugging be checked? You're cycling by pulling down the notification shade?

Categories

Resources