Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

MalagLagoon

macrumors regular
Original poster
Dec 19, 2019
158
56
Hey,

I just bought a couple of used external hard drives for my MacBook Pro (running Mojave). I'd like your opinion on the best way to PREVENT any potential malware or virus from crossing over onto my MacBook. I wouldn't want to nonchalantly plug them in. I don't have any sort of malware software installed on my MacBook.

Thanks for your help!

-M
 
Format it. Always always always format a new drive you get. I do this to drives that are store bought and sealed. I don't use any of the included manufacturer software - just format it (not with the drive software, with the OS software).

Have disk utility opened, plug it in, then format it first thing.
 
Do you actually need anything that's on the drives? Because really you can just format the drives and use them as new. Just plug them in, if they automount then unmount the drive, then just format. Do a "full" format to be extra careful (but it could take an hour or so instead of 30 seconds to do a full format).
 
Yes, I plan on formatting the drives. My concern is that very moment I plug the drive into my MacBook. I figured if there was something evil lurking on these drives they'd infect my system faster than I could have Disk Utility take over.

EDIT: And, yes, I'd take the hour or so to do a full format! I take no chances!
 
Yes, I plan on formatting the drives. My concern is that very moment I plug the drive into my MacBook. I figured if there was something evil lurking on these drives they'd infect my system faster than I could have Disk Utility take over.

Very very very unlikely something would infect just by mounting. And you can minimize the danger by unmounting it immediately. The system executes its own code in mounting the filesystem of the drive. Only if vulnerabilities exist already in your system could they take advantage of those vulnerabilities, so it could be a problem if say you bought the drive from the CIA and they really really really want to get at your system, otherwise if it's just a plain Jane drive from some guy even if he put viruses on the drive it's not going to do anything just by mounting (you'd have to execute such viruses).

Also, any kind of "virus scanner" would have to mount the drive to scan the files anyway.

If you really really really really want to not mount the drive then figure out if you can turn off automount external drives in the Mac. Then you can format it. Personally I think there's no danger in just plugging the drive in and unmounting it, then formatting it. Here's guidance for no automounting: https://apple.stackexchange.com/questions/120782/how-to-disable-usb-auto-mount
 
  • Like
Reactions: BigMcGuire
Yes, I plan on formatting the drives. My concern is that very moment I plug the drive into my MacBook. I figured if there was something evil lurking on these drives they'd infect my system faster than I could have Disk Utility take over.

EDIT: And, yes, I'd take the hour or so to do a full format! I take no chances!

So if anyone selling them were to have malware on them, 90% of the time it would be Windows only malware. The small amount that would be able to affect macOS, would be extremely unlikely to have auto-run capabilities. In the small, small, small subset of malware that aims at macOS and auto-runs, it would have to be able to take over parts of the system that are protected by macOS security to really do any harm, and if your Mojave is reasonably up to date I frankly find it highly unlikely. I'd almost be willing to plug them into production servers with those odds.

If you're still worried though, you can prevent macOS from automatically mounting the drive when it's plugged in; That should solve it
[automerge]1588874347[/automerge]
Very very very unlikely something would infect just by mounting. And you can minimize the danger by unmounting it immediately. The system executes its own code in mounting the filesystem of the drive. Only if vulnerabilities exist already in your system could they take advantage of those vulnerabilities, so it could be a problem if say you bought the drive from the CIA and they really really really want to get at your system, otherwise if it's just a plain Jane drive from some guy even if he put viruses on the drive it's not going to do anything just by mounting (you'd have to execute such viruses).

Also, any kind of "virus scanner" would have to mount the drive to scan the files anyway.

If you really really really really want to not mount the drive then figure out if you can turn off automount external drives in the Mac. Then you can format it. Personally I think there's no danger in just plugging the drive in and unmounting it, then formatting it. Here's guidance for no automounting: https://apple.stackexchange.com/questions/120782/how-to-disable-usb-auto-mount


Funny how we wrote an almost similar post at pretty much the same time
 
  • Like
Reactions: BigMcGuire
Yeah, I doubt something bad would happen insofar as getting infected. It's always good to be careful though - even though I'm not using Windows. Also, I just realized something. I have a backup MacBook Pro. I can install a clean operating system on the backup MBP and format the drives on that computer
 
I'd open disk utility first.
Then, plug the drive in.
Then, erase it using the "secure erase" feature.
1-pass ought to be enough to "clean it off"...
 
Hi, I too have just bought a secondhand external drive, but for a windows PC. I see everyone’s advice to format it - I am a complete novice, can anyone provide a step by step how I do this? it’s a WD hard drive that I want to put my photos on.
 
Hi, I too have just bought a secondhand external drive, but for a windows PC. I see everyone’s advice to format it - I am a complete novice, can anyone provide a step by step how I do this? it’s a WD hard drive that I want to put my photos on.

Just open /Applications/Utilities/Disk Utility.app! Use that app to format your external, I suggest you format HFS+ because that is the default for Mac OS!
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.