linux.debian.devel.mentors
[Top] [All Lists]

Handling password inputs and verification in config scripts so that spe

Subject: Handling password inputs and verification in config scripts so that special characters are allowed in passwords
From: Olivier Berger <olivier.berger@xxxxxxxxxxxxxx>
Date: Mon, 28 Jul 2008 14:10:15 +0200
Newsgroups: linux.debian.devel.mentors

Hi.

Let's consider the following snippet from a package's config script :
            db_beginblock
             db_input critical "phpgroupware/header/password" || true
             db_input critical "phpgroupware/header/password/confirm" || true
            db_endblock
            db_get "package/header/password"
            password="$RET"
            db_get "package/header/password/confirm"
            confirm="$RET"
            if [ "$password" != "$confirm" ] ; then

If I'm not mistaken, whenever a user inputs a password containing
characters like a double quote ("), the script may fail to properly
manage such a password.

Is there any good practice, doc or otherwise guidelines on how to deal
with such cases in debconf ?

Thanks in advance.

Best regards,

-- 
Olivier BERGER <olivier.berger@xxxxxxxxxxxxxx>
http://www-public.it-sudparis.eu/~berger_o/ - OpenPGP-Id: 1024D/6B829EEC
Ingénieur Recherche - Dept INF
Institut TELECOM, SudParis (http://www.it-sudparis.eu/), Evry (France)


--
To UNSUBSCRIBE, email to debian-mentors-REQUEST@xxxxxxxxxxxxxxxx
with a subject of "unsubscribe". Trouble? Contact listmaster@xxxxxxxxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>