Ubuntu 20.04 GDM3 Root Login GUI How Can I Disable Security Notification

343 Views Asked by At

firstly sorry for my english because im trying to explain my question yours.

System Details; Ubuntu 20.04 GDM3 (GUI) Installed VNC Connection Installed Root Login Enabled for login screen & SSH Automatic Login Enabled login screen

everythings good working but. on internet everywhere i checked and ubuntu sources i checked no have about this information to disable when login after notification about security message

Message is ;

title : ' Logged in as a privileged user ', message : ' Running a session as a privileged user should be avoided for security reasons. If possible, you should log in as a normal user. '

enter image description here I Want To Disable This Notification Message. Please if you know can you help me my colleagues

1

There are 1 best solutions below

0
On

This is baked into gnome. For anyone who stumble here, this is what I did on Ubuntu 22.04:

Follow the general method described here to make any change to gnome js files.

In this case, the file we need is ui/main.js. Replace this chunk

    let credentials = new Gio.Credentials();
    if (credentials.get_unix_user() === 0) {
        notify(_('Logged in as a privileged user'),
               _('Running a session as a privileged user should be avoided for security reasons. If possible, you should log in as a normal user.'));
    } else if (sessionMode.showWelcomeDialog) {
        _handleShowWelcomeScreen();
    }
    

with

if (sessionMode.showWelcomeDialog) {
    _handleShowWelcomeScreen();
}

Disclaimer: Running a session as a privileged user should be avoided for security reasons. If possible, you should log in as a normal user.