/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to mandos-keygen

  • Committer: Teddy Hogeborn
  • Date: 2009-11-09 05:10:35 UTC
  • Revision ID: teddy@fukt.bsnet.se-20091109051035-zcmvuhioo9gjs0cb
* mandos-monitor (MandosClientPropertyCache): Remove conversion of
                                              D-Bus types to native
                                              Python types.
  (MandosClientPropertyCache.type_map): Removed attribute.
  (MandosClientPropertyCache.conversion): Removed method.
  (ConstrainedListBox): New; a ListBox which will keep the focus.
  (UserInterface.__init__): Take new argument "max_log_length".
  (UserInterface.divider, UserInterface.log,
  UserInterface.max_log_length, UserInterface.logbox,
  UserInterface.log_visible, UserInterface.log_wrap): New attributes.
  (UserInterface.rebuild, UserInterface.log_message,
  UserInterface.toggle_log_display, UserInterface.change_log_display):
  New methods.
  (UserInterface.remove_client): Bug fix: Eliminate double client
                                 listing when an empty list gets a
                                 ClientAdded signal.
  (UserInterface.process_input): Add more key translations.

Show diffs side-by-side

added added

removed removed

Lines of Context:
278
278
    
279
279
    # Get fingerprint of key
280
280
    FINGERPRINT="`gpg --quiet --batch --no-tty --no-options \
281
 
        --enable-dsa2 --homedir \"$RINGDIR\" --trust-model always \
 
281
        --enable-dsa2 --homedir '"'$RINGDIR'"' --trust-model always \
282
282
        --fingerprint --with-colons \
283
283
        | sed --quiet \
284
284
        --expression='/^fpr:/{s/^fpr:.*:\\([0-9A-Z]*\\):\$/\\1/p;q}'`"
293
293
        stty -echo
294
294
        echo -n "Enter passphrase: " >&2
295
295
        first="$(head --lines=1 | tr --delete '\n')"
296
 
        echo >&2
297
 
        echo -n "Repeat passphrase: " >&2
 
296
        echo -n -e "\nRepeat passphrase: " >&2
298
297
        second="$(head --lines=1 | tr --delete '\n')"
299
298
        echo >&2
300
299
        stty echo
301
300
        if [ "$first" != "$second" ]; then
302
 
            echo "Passphrase mismatch" >&2
 
301
            echo -e "Passphrase mismatch" >&2
303
302
            touch "$RINGDIR"/mismatch
304
303
        else
305
304
            echo -n "$first"