You can fix this via AppleScript, without needing to reboot, or even log out & back in, or an existing root shell, or... All you need is a valid administrator password.
Run this command:
osascript -e 'do shell script "chown root:wheel /etc/sudoers; chmod 440 /etc/sudoers; chmod -N /etc/sudoers" with administrator privileges'
...and then ...
So for the past 4 days my computer has been at an apple authorized service center and authorized reseller for service in Hammond, LA for repeating keyboard letters and password mismatch issues - my user password seems to be different for login vs password used for user preferences. They should be the same. The service center has been telling me that they ...
Mac computers with the T2 chip have a feature known as Secure Boot, which prevents booting from external drives. It will need to be turned off using your admin password.
Previously, Apple techs would boot to their own disks in order to run diagnostic checks and test that everything works on a known system.
I haven't reverse engineered if it's a hashed / salted version of the password or if it's just key exchange and entangled secrets that are cryptographically difficult to alter. However, my best estimate is no - it's not simply a hashed version of your password.
Apple states that they don't retain the secret or shared key, so I expect if that's the case, it ...
I would make sure all the data is backed up and then make a new account.
Test that new account - one possibility that comes to mind is that there is a keyboard mismatch when entering the password at login.
If all is then well, install the data from the backup and proceed as normal.