Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Improved error handling in i386 boot(8) w/ password




When a password is set for the bootloader ("installboot -o password=..."), it currently complains about an unknown command and prints a usage if the password is entered wrong:

        ...
        Choose an option; RETURN for default; SPACE to stop countdown.
        Option 1 will be chosen in 0 seconds.
        Password: *
        Password: *
        Password: *
        unknown command
        commands are:
        boot [xdNx:][filename] [-12acdqsvxz]
             (ex. "hd0a:netbsd.old -s"
        ls [path]
        dev xd[N[x]]:
        consdev {pc|com[0123]|com[0123]kbd|auto}
        modules {enabled|disabled}
        load {path_to_module}
        multiboot [xdNx:][filename] [<args>]
        help|?
        quit

        Choose an option; RETURN for default; SPACE to stop countdown.
        Option 1 will be chosen in 0 seconds.
        ...

This is confusing, plus someone may use it to determine bits of information about the system. What should happen instead is that the user is informed that the password is wrong:

        ...
        Choose an option; RETURN for default; SPACE to stop countdown.
        Option 1 will be chosen in 0 seconds.
        Password: ****
        Password: ****
        Password: ****
        Wrong password.

        Choose an option; RETURN for default; SPACE to stop countdown.
        ...

The patch to implement this is at the following URL:

        http://www.feyrer.de/Misc/patch-i386boot-passwd.txt

I'd appreciate any comments, reports of tests, and and an OK to commit.
Thanks!


 - Hubert


Home | Main Index | Thread Index | Old Index