Skip to content

Auto login and sudo security cheat

wordpress meta

title: 'Auto Login and Sudo Security Cheat'
date: '2013-07-24T14:17:33-05:00'
status: publish
permalink: /auto-login-and-sudo-security-cheat
author: admin
excerpt: ''
type: post
id: 411
category:
    - Gnome
    - Ubuntu
tag:
    - Gnome
post_format: []

Sometimes you have a VM that you just don't care about security. I do the following to cheat a little on login and sudo.

Update shadow password file will enable tools like gksudo to work. gksudo is what is used for prompts you get when using System Administration etc... You don't have to type your password just hit enter.

It has to be this specific string "U6aMy0wojraho" you set.

# grep rrossouw /etc/shadow
rrossouw:U6aMy0wojraho:15910:0:99999:7:::

Give yourself some sudo privileges. For instance sudo -s won't need a password. Use visudo tool to update sudo policies.

# grep rrossouw /etc/sudoers
rrossouw ALL=(ALL) NOPASSWD:ALL

Enable Auto Login: System Settings -> User Accounts -> Unlock -> Authenticate (No need for password now) -> Click Automatic Login

I also disable my screensaver and password lock on the VM since my host has that enabled through an Active Directory policy already.