diff --git a/Makefile b/Makefile index c32484f..64816c6 100644 --- a/Makefile +++ b/Makefile @@ -5,7 +5,7 @@ info: @echo "ppa - upload to ppa launchpad. Stable" VERSION=0.5.1 -SRC_DIR = yubikey_luks.orig +SRC_DIR = yubikey-luks-${VERSION} debianize: rm -fr DEBUILD diff --git a/key-script b/key-script index 764c2a1..580c2a1 100755 --- a/key-script +++ b/key-script @@ -47,12 +47,17 @@ if [ "$check_yubikey_present" = "1" ]; then PW=$(printf %s "$PW" | sha256sum | awk '{print $1}') fi R="$(ykchalresp -2 "$PW" 2>/dev/null || true)" - message "Retrieved the response from the Yubikey" - if [ "$CONCATENATE" = "1" ]; then - printf '%s' "$PW$R" + if [ "$R" ]; then + message "Retrieved the response from the Yubikey" + if [ "$CONCATENATE" = "1" ]; then + printf '%s' "$PW$R" + else + printf '%s' "$R" + fi else - printf '%s' "$R" + message "Failed to retrieve the response from the Yubikey" fi + else printf '%s' "$PW" fi