News for hackers. Stuff that matters.
Re:Beware of sudo on OS X by vortico on Sunday August 16, 2015 @06:26PM (#10070499)
Or simply append `alias sudo="sudo evil.sh; sudo"` to .bash_profile.

Although, OS X is a bit like Windows. A bad program running in userspace can essentially ruin your system as much as a program running as root. Privilege escalation is not a relatively big deal when you can `shred -u ~/` without root.

Re:Beware of sudo on OS X by coldtea on Sunday August 16, 2015 @09:14PM (#10070965)
>Although, OS X is a bit like Windows. A bad program running in userspace can essentially ruin your system as much as a program running as root.

Erm, OS X has sandboxing. So, no. Except if you use unsigned third party stuff.

Re:Beware of sudo on OS X by __david__ on Monday August 17, 2015 @12:48AM (#10071415)
I think he only sandboxed apps are the ones from the App Store—Signing is orthogonal to sandboxing. Even signed apps that you get from anywhere other than then App Store aren't sandboxed.
Re:Beware of sudo on OS X by comex on Monday August 17, 2015 @04:51AM (#10071907)
You can sandbox non-App Store apps the same way as App Store ones, you're just not forced to. And so developers don't.
Re:Beware of sudo on OS X by driverdan on Sunday August 16, 2015 @11:19PM (#10071219)
Which is pretty much everyone reading HN.
Re:Beware of sudo on OS X by coldtea on Sunday August 16, 2015 @11:25PM (#10071240)
In which case it's no different to Linux, OpenBSD or whatever.

As long as its your account files that matter, and you're running an app un-sandboxed, then it has access to them.

Nothing Windows or OS X particular about it.

As about "ruining your system", no, without root privileges it cannot, in either OS X or Windows. Of course it can if there's a privilege escalation bug, but there are tons of those for GNU/Gnome/KDE packages too.

Re:Beware of sudo on OS X by WalterGR on Monday August 17, 2015 @05:00AM (#10071937)

    ...like Windows. A bad program running in userspace can essentially
    ruin your system as much as a program running as root.
How so?

Are you talking about pre-Vista - i.e. versions of Windows in which the user created during first run was an Administrator, and UAC didn't exist - though you could certainly create non-administrator accounts? Vista came out eight years ago...

Or do you mean pre-NT, when there was no separation of any kind? NT came out 22 years ago...

Re:Beware of sudo on OS X by vortico on Monday August 17, 2015 @03:43PM (#10075579)
I mean that most of the "important stuff" is running in user space. You can shut down the computer, spread viruses, and delete the user's most important files. The only administrator-owned files on a typical Windows installation happen to be the replaceable ones. The ones modifiable by a user are the custom, personal, and sometimes irreplaceable files.

This is mostly true on personal Linux machines as well. I'm just expressing my opinion that you don't need root access to pwn someone's machine.