Let Sudo Insult You When You Screw Up

Discussion and support for all Linux distributions and Unix flavours (FreeBSD, OpenBSD, etc).
Post Reply
Anthro
Moderator Emeritus
Posts: 5547
Joined: 21 Dec 2002, 02:00
Processor: i7 3770k
Motherboard: ASUS P8P67-Pro
Graphics card: 2xNvidia GTX670
Memory: 16 GB Gskill Sniper
Location: In SQL Space inserting 'null' on purpose
Contact:

Let Sudo Insult You When You Screw Up

Post by Anthro »

recently found a fun feature available within the sudo program that will insult you when you do the wrong thing such as enter your password incorrectly. I’ll tell you how you can activate the feature for a few laughs and also give a few examples of what insults you might get.

To turn the feature on you’ll need to use the following command:

Code: Select all

sudo visudo
(always use visudo when you need to edit your sudoers file as it has a self-check system that won’t let you screw it up.)

Find the line that begins with Default and append insults to the end. (Any addition to that line is comma separated.) Your entry will then look like this:

Code: Select all

Defaults !lecture,tty_tickets,!fqdn,insults
Save the file and you’ll notice the next time you screw up your sudo password you’ll get an insult.

Note: to clear your sudo session and be required to enter the password again try:

Code: Select all

sudo -K
A few examples below:

Code: Select all

Maybe if you used more than just two fingers…

    I have been called worse.

    Listen, burrito brains, I don’t have time to listen to this trash.
Post Reply