Skip to content

Commit d60f84c

Browse files
committed
Fixed outstanding bugs with Xcode and password loop.
1 parent 895dab0 commit d60f84c

File tree

5 files changed

+28
-4
lines changed

5 files changed

+28
-4
lines changed

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
1.3.1
2+
-----
3+
4+
- Fixed a bug where the installation script went into the infinite loop asking
5+
the user for volume's password with no way to cancel the activity;
6+
- Hopefully, addressed an issue where the installation script was not waiting
7+
for Xcode's installation to complete.
8+
19
1.3.0
210
-----
311

build/Distribution.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
22
<installer-gui-script minSpecVersion="2">
33
<title>BootUnlock</title>
4-
<product id="au.com.openwall.BootUnlock" version="1.3.0" />
4+
<product id="au.com.openwall.BootUnlock" version="1.3.1" />
55
<background file="background.png" scaling="proportional" alignment="bottomleft"/>
66
<welcome file="welcome.rtf"/>
77
<readme file="readme.rtf"/>
@@ -20,5 +20,5 @@
2020
<choice id="au.com.openwall.BootUnlock" visible="false">
2121
<pkg-ref id="au.com.openwall.BootUnlock"/>
2222
</choice>
23-
<pkg-ref id="au.com.openwall.BootUnlock">BootUnlock-1.3.0-dist.pkg</pkg-ref>
23+
<pkg-ref id="au.com.openwall.BootUnlock">BootUnlock-1.3.1-dist.pkg</pkg-ref>
2424
</installer-gui-script>

build/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ NAME="BootUnlock"
77
IDENTIFIER="au.com.openwall.$NAME"
88

99
# Package version number.
10-
VERSION="1.3.0"
10+
VERSION="1.3.1"
1111

1212
# The location to copy the contents of files.
1313
INSTALL_LOCATION="/Library/PrivilegedHelperTools/$IDENTIFIER"

files/update.sh

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,15 @@ for V in "${VOLUME[@]}" ; do
113113
promptPassword('Please provide the passphrase for volume \"$NAME\":')
114114
")
115115

116+
if [ -z "PASSPHRASE" ]; then
117+
osascript -e "display alert \"BootUnlock\" message \"
118+
You did not specfy the passphrase for the selected volume(s), so BootUnlock is not going to do anything at the system boot up time.
119+
120+
If you reconsider and will want to enable unlocking of a particular volume you can re-run the '$SELF' script at a later time
121+
\" as critical" &>/dev/null
122+
exit 0
123+
fi
124+
116125
if printf '%s' "$PASSPHRASE" | diskutil apfs unlock "$DEVICE" -stdinpassphrase -verify -user "$UUID"; then
117126
printf 'Adding password for volume "%s" with UUID %s to the System keychain...\n' "$NAME" "$UUID"
118127
if sudo /usr/bin/security add-generic-password \
@@ -140,4 +149,3 @@ If you believe that you are providing the correct password, yet it is not recogn
140149
fi
141150
done
142151
done
143-

scripts/preinstall

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,13 @@
33
set -eu -o pipefail
44

55
if ! xcode-select -p >/dev/null 2>&1; then
6+
osascript -e "display alert \"BootUnlock\" message \"
7+
The required Xcode command-line tools have not been found on the system, requesting the installation.
8+
9+
The installation process is going to wait until Xcode command-line tools are installed (may need your confirmation in another dialog).
10+
\" as critical" &>/dev/null
611
xcode-select --install ||:
12+
until xcode-select -p >/dev/null 2>&1; do
13+
sleep 1
14+
done
715
fi

0 commit comments

Comments
 (0)