Skip to content

Commit 112e3ae

Browse files
philipandakrystian-hebel
authored andcommitted
user-docs/install_aem: Give precise versions of packages
For now it is required to ensure it works fine with the somewhat complex system of possible qubes-dom0-update `--action` variants Signed-off-by: Filip Gołaś <filip.golas@3mdeb.com>
1 parent 3378474 commit 112e3ae

File tree

1 file changed

+67
-68
lines changed

1 file changed

+67
-68
lines changed

docs/user-docs/install_aem.md

Lines changed: 67 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ a key that was used to sign RPM packages.
1515
To add a new repository, create in dom0 as root `/etc/yum.repos.d/aem.repo`
1616
with the following content:
1717

18-
```text
18+
```ini
1919
[aem]
2020
name = Anti Evil Maid based on TrenchBoot
2121
baseurl = https://dl.3mdeb.com/rpm/QubesOS/r4.2/current/dom0/fc37
@@ -35,17 +35,12 @@ sudo rpm --import RPM-GPG-KEY-tb-aem
3535

3636
Now it should be possible to download and install packages from AEM repository.
3737

38-
### Installing prerequisite packages
38+
### Intel systems dependencies
39+
40+
If your device has an Intel CPU, download [official package from Intel](https://cdrdv2.intel.com/v1/dl/getContent/630744)
41+
and extract ACM appropriate for your platform to `/boot/`.
3942

40-
As some of the packages are also available in standard QubesOS repositories,
41-
potentially in newer versions, those must be temporarily disabled during
42-
invocation of `qubes-dom0-update`, as shown in the following commands. If any
43-
of the packages that are part of AEM are updated in standard repos, you will
44-
have to choose between using new versions or having working AEM, at least until
45-
new AEM release is published, or the code gets merged upstream. If you decide to
46-
restore AEM after an update broke it, you will have to repeat the installation
47-
of overwritten package with `--action=reinstall` added to `qubes-dom0-update`,
48-
if it wasn’t present before.
43+
### Installing prerequisite packages
4944

5045
#### Qubes repository dependencies
5146

@@ -62,56 +57,77 @@ sudo qubes-dom0-update --enablerepo=qubes-dom0-current-testing \
6257
tpm-tools
6358
```
6459

65-
#### AEM repository dependencies
60+
#### Prepare a list of AEM packages
61+
62+
For convenience, the packages can be saved to an environment variable:
63+
64+
```shell
65+
packages=(
66+
"anti-evil-maid-4.2.1-1.fc37.x86_64"
67+
"grub2-common-2.13-1.fc37.noarch"
68+
"grub2-tools-2.13-1.fc37.x86_64"
69+
"grub2-tools-extra-2.13-1.fc37.x86_64"
70+
"grub2-tools-minimal-2.13-1.fc37.x86_64"
71+
"python3-xen-4.17.5-7.fc37.x86_64"
72+
"xen-4.17.5-7.fc37.x86_64"
73+
"xen-hypervisor-4.17.5-7.fc37.x86_64"
74+
"xen-libs-4.17.5-7.fc37.x86_64"
75+
"xen-licenses-4.17.5-7.fc37.x86_64"
76+
"xen-runtime-4.17.5-7.fc37.x86_64"
77+
)
78+
```
6679

67-
Next set of new packages comes from AEM repository, to avoid conflicts other
68-
repositories are disabled for this call:
80+
##### Legacy Systems
6981

70-
```bash
71-
sudo qubes-dom0-update --disablerepo="*" --enablerepo=aem \
72-
grub2-tools-extra
82+
If your system has a legacy BIOS, run:
83+
84+
```shell
85+
packages+=(
86+
"grub2-pc-2.13-1.fc37.x86_64"
87+
"grub2-pc-modules-2.13-1.fc37.noarch"
88+
)
7389
```
7490

75-
##### AMD systems dependencies
91+
##### UEFI Systems
7692

77-
This package is only needed on AMD systems:
93+
If your system has a UEFI BIOS, run:
7894

79-
```bash
80-
sudo qubes-dom0-update --disablerepo="*" --enablerepo=aem \
81-
secure-kernel-loader
95+
```shell
96+
packages+=(
97+
"grub2-efi-x64-2.13-1.fc37.x86_64"
98+
"grub2-efi-x64-modules-2.13-1.fc37.noarch"
99+
)
82100
```
83101

84-
#### AEM repository dependencies to reinstall
102+
##### AMD systems
85103

86-
This is followed by reinstalling additional packages. A reinstallation is required
87-
because currently installed version is equal (or it may be higher in the future)
88-
than those provided by AEM. A couple of GRUB packages differ slightly
89-
depending on whether you use a legacy or UEFI BIOS:
104+
If your systems has an AMD CPU, run:
90105

91-
##### Legacy Systems
106+
```shell
107+
packages+=(
108+
"secure-kernel-loader-0+224af56470eff64f2cc1f74c1e1099d3f170636f-1.fc37.x86_64"
109+
)
110+
```
92111

93-
If your system has a legacy BIOS, reinstall these packages:
112+
#### Installing
94113

95-
```bash
96-
sudo qubes-dom0-update --disablerepo="*" --enablerepo=aem --action=reinstall \
97-
python3-xen \
98-
xen \
99-
xen-hypervisor \
100-
xen-libs \
101-
xen-licenses \
102-
xen-runtime \
103-
grub2-common \
104-
grub2-pc \
105-
grub2-pc-modules \
106-
grub2-tools \
107-
grub2-tools-minimal
114+
Install the packages (first command reinstalls existing packages in case the
115+
same version numbers exist on official Qubes repositories, second one only
116+
adds new packages):
117+
118+
```shell
119+
qubes-dom0-update --disablerepo="*" --enablerepo=aem --action=reinstall -y ${packages[@]}
120+
qubes-dom0-update --disablerepo="*" --enablerepo=aem --action=install -y ${packages[@]}
108121
```
109122

110-
###### Updating GRUB on legacy systems
123+
#### Updating GRUB on legacy systems
111124

112125
Booting on legacy systems requires manual installation of GRUB2 to the MBR
113-
of disk where Qubes OS is stored. If you are sure where the root partition
114-
is located, you can skip the following steps explaining how to find it out.
126+
of disk where Qubes OS is stored. If your systems has a Legacy BIOS, follow
127+
these instructions.
128+
129+
If you are sure where the root partition is located, you can skip the
130+
following steps explaining how to find it out.
115131

116132
To check on which drive is your OS installed, run:
117133

@@ -167,31 +183,13 @@ skipped on UEFI systems.
167183
sudo grub2-install /dev/sda
168184
```
169185

170-
##### UEFI Systems
171-
172-
If your system has an UEFI BIOS, install these packages instead:
173-
174-
```bash
175-
sudo qubes-dom0-update --disablerepo="*" --enablerepo=aem --action=reinstall \
176-
python3-xen \
177-
xen \
178-
xen-hypervisor \
179-
xen-libs \
180-
xen-licenses \
181-
xen-runtime \
182-
grub2-common \
183-
grub2-efi-x64 \
184-
grub2-efi-x64-modules \
185-
grub2-tools \
186-
grub2-tools-minimal
187-
```
188-
189186
### Installing main AEM package
190187

191188
Finally, `anti-evil-maid` package may be installed:
192189

193190
```bash
194-
sudo qubes-dom0-update --disablerepo="*" --enablerepo=aem anti-evil-maid
191+
sudo qubes-dom0-update --disablerepo="*" --enablerepo=aem \
192+
anti-evil-maid-4.2.1-1.fc37.x86_64
195193
```
196194

197195
## Provisioning
@@ -214,8 +212,7 @@ clear the TPM, you will be shown a message like this:
214212

215213
![](../img/qubes_aem_setup_fail.png)
216214

217-
In that case, try clearing the TPM and run `sudo anti-evil-maid-tpm-setup`
218-
again.
215+
In that case, try clearing the TPM in your BIOS and run the command again.
219216

220217
Now all that's left is proper installation of AEM. There are different options,
221218
refer to `anti-evil-maid-install -h` for examples. In the simplest case, AEM is
@@ -235,11 +232,13 @@ sudo anti-evil-maid-install /dev/sda1
235232
236233
![](../img/qubes_aem_install.png)
237234
238-
After that, reboot the platform. On first boot you will be asked for SRK
235+
After that, reboot the platform. On first boot you will be asked for the SRK
239236
password, followed by another question for disk encryption password, after which
240237
a screen mentioning absent secret file will be shown:
241238
242239
![](../img/qubes_aem_1st_boot.png)
243240
244241
This is expected on the first boot after installation or an update to one or
245242
more of measured components (GRUB, Xen, dom0 kernel and initramfs).
243+
After rebooting for the second time, the Anti Evil Maid should be up
244+
and running.

0 commit comments

Comments
 (0)