This is nothing directly related to Webmin/Virtualmin.
Recently, I had a problem with MariaDB. To resolve the issue I used MobaXterm to login to server using SSH. To my surprise, the root user was logged in even without asking a password.
Then I tried Putty to login and it asked me for the password.
Whenever I try to login using MobaXterm, it is not asking for any password.
By default, MariaDB enables Unix socket authentication. This means if your system username matches a MariaDB user, you can log in without a password. Keep in mind that users authenticated this way cannot be used directly by web apps like phpMyAdmin, because it expects a username/password handshake.
You can check which authentication plugin is used by running the following command while logged into your database: