-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Partially revert swtpm review
- Loading branch information
Showing
4 changed files
with
32 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# This patch disables stateful partition encryption (which does not work without official TPM since r103) | ||
|
||
ret=0 | ||
|
||
mv /roota/usr/sbin/mount-encrypted /roota/usr/sbin/mount-encrypted.real | ||
cat >/roota/usr/sbin/mount-encrypted <<'MOUNTS' | ||
#!/bin/bash | ||
#touch /test | ||
#echo "mount-encrypted called with args \"$@\"" >> /test | ||
if [ $# -eq 0 ]; then | ||
/usr/sbin/mount-encrypted.real | ||
umount /home/chronos | ||
umount /var | ||
umount /mnt/stateful_partition/encrypted | ||
rm -f /mnt/stateful_partition/encrypted.* | ||
mount --bind /mnt/stateful_partition/encrypted /mnt/stateful_partition/encrypted | ||
mkdir -p /mnt/stateful_partition/encrypted/chronos /mnt/stateful_partition/encrypted/var | ||
mount --bind /mnt/stateful_partition/encrypted/var /var | ||
chown chronos:chronos /mnt/stateful_partition/encrypted/chronos | ||
mount --bind /mnt/stateful_partition/encrypted/chronos /home/chronos | ||
else | ||
/usr/sbin/mount-encrypted.real "$@" | ||
fi | ||
MOUNTS | ||
chmod 0755 /roota/usr/sbin/mount-encrypted | ||
if [ ! "$?" -eq 0 ]; then ret=$((ret + (2 ** 0))); fi | ||
|
||
exit $ret |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters