~xnox/debian/sid/cryptsetup/ubuntu

« back to all changes in this revision

Viewing changes to debian/cryptdisks.functions

  • Committer: Package Import Robot
  • Author(s): Jonas Meurer, Milan Broz, Steve Langasek, Jonas Meurer
  • Date: 2013-06-28 12:10:41 UTC
  • mfrom: (0.2.11)
  • Revision ID: package-import@ubuntu.com-20130628121041-ek9rtel19yehj31t
Tags: 2:1.6.1-1
[ Milan Broz ]
* new upstream version. (closes: #704827, 707997)
  - default LUKS encryption mode is XTS (aes-xts-plain64) (closes: #714331)
  - adds native support for Truecrypt and compatible on-disk format
  - adds benchmark command
  - adds cryptsetup-reencrypt, a tool to offline reencrypt LUKS device
  - adds veritysetup, a tool for dm-verity block device verification module
* install docs/examples into docs at cryptsetup-dev package.
* fix compilation warnings in askpass.c.

[ Steve Langasek ]
* fix upstart jobs to not cause boot hangs when actually used in
  conjunction with startpar.  (closes: #694499, #677712).
* in connection with the above, make the cryptdisks-early job explicitly
  wait for 'umountfs' on shutdown just like cryptdisks does; otherwise,
  the teardown of the cryptdisks upstart job may cause the cryptdisks-early
  init script run before we're done unmounting filesystems.

[ Jonas Meurer ]
* minor wording fixes to README.initramfs, suggested by intrigeri and Adam
  D. Barrett.
* add bash-completion script for cryptdisks_{start,stop}. Thanks to Claudius
  Hubig for providing a patch. (closes: #700777)
* support specifying key-slot in crypttab. Thanks to Kevin Locke for the
  patch. (closes: #704470)
* remove evms support code from cryptroot initramfs script. (closes: #713918)
* fix location of keyscripts in initramfs documentation. (closes: #697446)
* fix a typo in decrypt_ssl script that prevented stdout from beeing
  redirected to /dev/null. (closes: #700285)
* give full path to blkid in crytproot initramfs script. (closes: #697155)
* export number of previous tries from cryptroot and cryptdisks to
  keyscript. Thanks to Laurens Blankers for the idea. Opens the possibility
  to fallback after a given number of tries for keyscripts. (closes: #438481,
  #471729, #697455)
* improve check for cpu hardware encryption support in initramfs cryptroot
  hook. (closes: #714326)

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
        # Strip comments - https://bugs.launchpad.net/bugs/185380
31
31
        opts=$(echo -n $1 | sed 's/ *#.*//')
32
32
        PARAMS=""
 
33
        LUKSPARAMS=""
33
34
        PLAINPARAMS=""
34
35
        CHECK=""
35
36
        CHECKARGS=""
181
182
                                return 1
182
183
                        fi
183
184
                        ;;
 
185
                keyslot)
 
186
                        if [ -z "$VALUE" ]; then
 
187
                                log_warning_msg "$dst: no value for keyslot option, skipping"
 
188
                                return 1
 
189
                        fi
 
190
                        LUKSPARAMS="$LUKSPARAMS --key-slot $VALUE"
 
191
                        ;;
184
192
                esac
185
193
 
186
194
                CRYPTTAB_OPTIONS="$CRYPTTAB_OPTIONS $PARAM"
285
293
        PARAMS="$PARAMS --key-file=$key"
286
294
 
287
295
        while [ "$tried" -lt "$TRIES" ] || [ "$TRIES" -eq "0" ]; do
 
296
                export CRYPTTAB_TRIED="$tried"
288
297
                if [ -n "$KEYSCRIPT" ]; then
289
 
                        if $KEYSCRIPT "$keyscriptarg" | cryptsetup $PARAMS luksOpen "$src" "${dst}_unformatted"; then
 
298
                        if $KEYSCRIPT "$keyscriptarg" | cryptsetup $PARAMS $LUKSPARAMS luksOpen "$src" "${dst}_unformatted"; then
290
299
                                break
291
300
                        fi
292
301
                else
293
 
                        if cryptsetup $PARAMS luksOpen "$src" "${dst}_unformatted"; then
 
302
                        if cryptsetup $PARAMS $LUKSPARAMS luksOpen "$src" "${dst}_unformatted"; then
294
303
                                break
295
304
                        fi
296
305
                fi
350
359
        PARAMS="$PARAMS --key-file=$key"
351
360
 
352
361
        while [ "$tried" -lt "$TRIES" ]; do
 
362
                export CRYPTTAB_TRIED="$tried"
353
363
                if [ -n "$KEYSCRIPT" ]; then
354
364
                        $KEYSCRIPT "$keyscriptarg" | cryptsetup $PLAINPARAMS $PARAMS create "${dst}_unformatted" "$src"
355
365
                else