diff options
author | Florian Pritz <bluewind@xinu.at> | 2015-02-02 12:04:50 +0100 |
---|---|---|
committer | Florian Pritz <bluewind@xinu.at> | 2015-02-02 12:04:50 +0100 |
commit | b8471ce80da8a0b66e64ca812598c91f43eeefae (patch) | |
tree | d7fd9c7db0debbb99e6087ddf3ac8411b2540816 /luks-header-backup | |
parent | 96e8159015f9bd4d5dc123be769ab55343e0ce12 (diff) | |
download | bin-b8471ce80da8a0b66e64ca812598c91f43eeefae.tar.gz bin-b8471ce80da8a0b66e64ca812598c91f43eeefae.tar.xz |
luks-header-backup: encrypt backup file
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'luks-header-backup')
-rwxr-xr-x | luks-header-backup | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/luks-header-backup b/luks-header-backup index 4219df7..38c0e7f 100755 --- a/luks-header-backup +++ b/luks-header-backup @@ -7,7 +7,11 @@ test -n "$host" dev=$1 dev_basename=${dev##*/} +outfile="$HOME/$host-${dev_basename}-luks-header.bak" test -n "$dev_basename" -cryptsetup --header-backup-file=$HOME/$host-${dev_basename}-luks-header.bak luksHeaderBackup $dev +cryptsetup --header-backup-file="$outfile" luksHeaderBackup $dev +gpg --batch -r 0x6D1655C14CE1C13E -e "$outfile" +rm "$outfile" +chown flo:users "$outfile.gpg" |