[6dcb9e77] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
| 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[8dfc5c3] | 7 | <!ENTITY cryptsetup-download-http "&kernel-dl;/linux/utils/cryptsetup/v&cryptsetup-minor;/cryptsetup-&cryptsetup-version;.tar.xz">
|
---|
[6dcb9e77] | 8 | <!ENTITY cryptsetup-download-ftp " ">
|
---|
[93817f4] | 9 | <!ENTITY cryptsetup-md5sum "6e4ffb6d35a73f7539a5d0c1354654cd">
|
---|
[b5dc1cf] | 10 | <!ENTITY cryptsetup-size "11 MB">
|
---|
[93817f4] | 11 | <!ENTITY cryptsetup-buildsize "34 MB (add 129 MB for tests)">
|
---|
| 12 | <!ENTITY cryptsetup-time "0.2 SBU (add 9.1 SBU for tests)">
|
---|
[6dcb9e77] | 13 | ]>
|
---|
| 14 |
|
---|
| 15 | <sect1 id="cryptsetup" xreflabel="cryptsetup-&cryptsetup-version;">
|
---|
| 16 | <?dbhtml filename="cryptsetup.html"?>
|
---|
| 17 |
|
---|
| 18 | <sect1info>
|
---|
| 19 | <othername>$LastChangedBy$</othername>
|
---|
| 20 | <date>$Date$</date>
|
---|
| 21 | </sect1info>
|
---|
| 22 |
|
---|
| 23 | <title>cryptsetup-&cryptsetup-version;</title>
|
---|
| 24 |
|
---|
| 25 | <indexterm zone="cryptsetup">
|
---|
| 26 | <primary sortas="a-cryptsetup">cryptsetup</primary>
|
---|
| 27 | </indexterm>
|
---|
| 28 |
|
---|
| 29 | <sect2 role="package">
|
---|
| 30 | <title>Introduction to cryptsetup</title>
|
---|
| 31 |
|
---|
| 32 | <para>
|
---|
| 33 | cryptsetup is used to set up transparent encryption of block devices
|
---|
| 34 | using the kernel crypto API.
|
---|
| 35 | </para>
|
---|
| 36 |
|
---|
[90c883f] | 37 | &lfs91_checked;
|
---|
[6dcb9e77] | 38 |
|
---|
| 39 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 40 | <itemizedlist spacing="compact">
|
---|
| 41 | <listitem>
|
---|
| 42 | <para>
|
---|
| 43 | Download (HTTP): <ulink url="&cryptsetup-download-http;"/>
|
---|
| 44 | </para>
|
---|
| 45 | </listitem>
|
---|
| 46 | <listitem>
|
---|
| 47 | <para>
|
---|
| 48 | Download (FTP): <ulink url="&cryptsetup-download-ftp;"/>
|
---|
| 49 | </para>
|
---|
| 50 | </listitem>
|
---|
| 51 | <listitem>
|
---|
| 52 | <para>
|
---|
| 53 | Download MD5 sum: &cryptsetup-md5sum;
|
---|
| 54 | </para>
|
---|
| 55 | </listitem>
|
---|
| 56 | <listitem>
|
---|
| 57 | <para>
|
---|
| 58 | Download size: &cryptsetup-size;
|
---|
| 59 | </para>
|
---|
| 60 | </listitem>
|
---|
| 61 | <listitem>
|
---|
| 62 | <para>
|
---|
| 63 | Estimated disk space required: &cryptsetup-buildsize;
|
---|
| 64 | </para>
|
---|
| 65 | </listitem>
|
---|
| 66 | <listitem>
|
---|
| 67 | <para>
|
---|
| 68 | Estimated build time: &cryptsetup-time;
|
---|
| 69 | </para>
|
---|
| 70 | </listitem>
|
---|
| 71 | </itemizedlist>
|
---|
| 72 |
|
---|
[93817f4] | 73 | <!-- No longer needed with 2.3.2.
|
---|
[24f32bb] | 74 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
| 75 | <itemizedlist spacing="compact">
|
---|
| 76 | <listitem>
|
---|
| 77 | <para>
|
---|
| 78 | Required patch:
|
---|
| 79 | <ulink url="&patch-root;/cryptsetup-&cryptsetup-version;-upstream_fixes-1.patch"/>
|
---|
| 80 | </para>
|
---|
| 81 | </listitem>
|
---|
| 82 | </itemizedlist>
|
---|
[93817f4] | 83 | -->
|
---|
[24f32bb] | 84 |
|
---|
[6dcb9e77] | 85 | <bridgehead renderas="sect3">cryptsetup Dependencies</bridgehead>
|
---|
| 86 |
|
---|
| 87 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
| 88 | <para role="required">
|
---|
[6cc2f9a8] | 89 | <xref linkend="json-c"/>,
|
---|
[82e1be5] | 90 | <xref linkend="libgcrypt"/>,
|
---|
[6cc2f9a8] | 91 | <xref linkend="lvm2"/>, and
|
---|
[4509c956] | 92 | <xref linkend="popt"/>
|
---|
[6dcb9e77] | 93 | </para>
|
---|
| 94 |
|
---|
| 95 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
| 96 | <para role="optional">
|
---|
| 97 | <xref linkend="libpwquality"/>,
|
---|
[93817f4] | 98 | <xref linkend="python2"/>,
|
---|
| 99 | <ulink url="https://github.com/P-H-C/phc-winner-argon2">argon2</ulink>, and
|
---|
[6dcb9e77] | 100 | <ulink url="http://www.openwall.com/passwdqc/">passwdqc</ulink>
|
---|
| 101 | </para>
|
---|
| 102 |
|
---|
| 103 |
|
---|
| 104 | <para condition="html" role="usernotes">User Notes:
|
---|
| 105 | <ulink url="&blfs-wiki;/cryptsetup"/>
|
---|
| 106 | </para>
|
---|
| 107 | </sect2>
|
---|
| 108 |
|
---|
| 109 | <sect2 role="kernel" id="cryptsetup-kernel">
|
---|
| 110 | <title>Kernel Configuration</title>
|
---|
| 111 |
|
---|
| 112 | <para>
|
---|
[416617d6] | 113 | Encrypted block devices require kernel support. To use it, the
|
---|
[6dcb9e77] | 114 | appropriate kernel configuration parameters need to be set:
|
---|
| 115 | </para>
|
---|
| 116 |
|
---|
| 117 | <screen><literal>Device Drivers --->
|
---|
| 118 | [*] Multiple devices driver support (RAID and LVM) ---> [CONFIG_MD]
|
---|
| 119 | <*/M> Device mapper support [CONFIG_BLK_DEV_DM]
|
---|
| 120 | <*/M> Crypt target support [CONFIG_DM_CRYPT]
|
---|
| 121 |
|
---|
| 122 | Cryptographic API --->
|
---|
| 123 | <*/M> XTS support [CONFIG_CRYPTO_XTS]
|
---|
| 124 | <*/M> SHA224 and SHA256 digest algorithm [CONFIG_CRYPTO_SHA256]
|
---|
| 125 | <*/M> AES cipher algorithms [CONFIG_CRYPTO_AES]
|
---|
| 126 | <*/M> User-space interface for symmetric key cipher algorithms
|
---|
| 127 | [CONFIG_CRYPTO_USER_API_SKCIPHER]
|
---|
| 128 | For tests:
|
---|
| 129 | <*/M> Twofish cipher algorithm [CONFIG_CRYPTO_TWOFISH]</literal></screen>
|
---|
| 130 |
|
---|
| 131 | <indexterm zone="cryptsetup cryptsetup-kernel">
|
---|
| 132 | <primary sortas="d-cryptsetup">cryptsetup</primary>
|
---|
| 133 | </indexterm>
|
---|
| 134 |
|
---|
| 135 | </sect2>
|
---|
| 136 |
|
---|
| 137 | <sect2 role="installation">
|
---|
| 138 | <title>Installation of cryptsetup</title>
|
---|
| 139 |
|
---|
[93817f4] | 140 | <!-- No longer needed with 2.3.2
|
---|
[24f32bb] | 141 | <para>
|
---|
| 142 | First, apply a patch to fix a build problem caused by API changes in
|
---|
| 143 | <xref role="nodep" linkend="json-c"/>:
|
---|
| 144 | </para>
|
---|
| 145 |
|
---|
| 146 | <screen><userinput remap="pre">patch -Np1 -i ../cryptsetup-&cryptsetup-version;-upstream_fixes-1.patch</userinput></screen>
|
---|
[93817f4] | 147 | -->
|
---|
[24f32bb] | 148 |
|
---|
[6dcb9e77] | 149 | <para>
|
---|
| 150 | Install <application>cryptsetup</application> by running the following
|
---|
| 151 | commands:
|
---|
| 152 | </para>
|
---|
| 153 |
|
---|
[4472f011] | 154 | <screen><userinput>./configure --prefix=/usr &&
|
---|
[6dcb9e77] | 155 | make</userinput></screen>
|
---|
| 156 |
|
---|
| 157 | <para>
|
---|
| 158 | To test the result, issue as the <systemitem
|
---|
[9f5dcb97] | 159 | class="username">root</systemitem> user: <command>make check</command>.
|
---|
| 160 | Some tests may fail if the kernel configuration parameters above are not
|
---|
[93817f4] | 161 | set. <!--Three (of 21) tests are known to fail.-->
|
---|
[6dcb9e77] | 162 | </para>
|
---|
| 163 |
|
---|
[47274444] | 164 | <para>
|
---|
| 165 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 166 | </para>
|
---|
[6dcb9e77] | 167 |
|
---|
| 168 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
| 169 |
|
---|
| 170 | </sect2>
|
---|
| 171 |
|
---|
[4472f011] | 172 | <!--sect2 role="commands">
|
---|
[4509c956] | 173 | <title>Command Explanations</title>
|
---|
| 174 |
|
---|
[4472f011] | 175 | </sect2-->
|
---|
[6dcb9e77] | 176 |
|
---|
| 177 | <sect2 role="configuration">
|
---|
| 178 | <title>Configuring cryptsetup</title>
|
---|
| 179 |
|
---|
| 180 | <para>
|
---|
[effdf5be] | 181 | Because of the number of possible configurations, setup of encrypted
|
---|
| 182 | volumes is beyond the scope of the BLFS book. Please see the
|
---|
| 183 | configuration guide in the cryptsetup <ulink
|
---|
| 184 | url="https://gitlab.com/cryptsetup/cryptsetup/wikis/FrequentlyAskedQuestions#2-setup">
|
---|
| 185 | FAQ</ulink>.
|
---|
[6dcb9e77] | 186 | </para>
|
---|
| 187 |
|
---|
| 188 | </sect2>
|
---|
| 189 |
|
---|
| 190 | <sect2 role="content">
|
---|
| 191 | <title>Contents</title>
|
---|
| 192 |
|
---|
| 193 | <segmentedlist>
|
---|
| 194 | <segtitle>Installed Programs</segtitle>
|
---|
| 195 | <segtitle>Installed Libraries</segtitle>
|
---|
| 196 | <segtitle>Installed Directories</segtitle>
|
---|
| 197 |
|
---|
| 198 | <seglistitem>
|
---|
| 199 | <seg>
|
---|
[9f5dcb97] | 200 | cryptsetup,
|
---|
| 201 | cryptsetup-reencrypt,
|
---|
| 202 | integritysetup, and
|
---|
[6dcb9e77] | 203 | veritysetup
|
---|
| 204 | </seg>
|
---|
| 205 | <seg>
|
---|
| 206 | libcryptsetup.so
|
---|
| 207 | </seg>
|
---|
| 208 | <seg>
|
---|
| 209 | None
|
---|
| 210 | </seg>
|
---|
| 211 | </seglistitem>
|
---|
| 212 | </segmentedlist>
|
---|
| 213 |
|
---|
| 214 | <variablelist>
|
---|
| 215 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 216 | <?dbfo list-presentation="list"?>
|
---|
| 217 | <?dbhtml list-presentation="table"?>
|
---|
| 218 |
|
---|
| 219 | <varlistentry id="cryptsetup-prog">
|
---|
| 220 | <term><command>cryptsetup</command></term>
|
---|
| 221 | <listitem>
|
---|
| 222 | <para>
|
---|
| 223 | is used to setup dm-crypt managed device-mapper mappings.
|
---|
| 224 | </para>
|
---|
| 225 | <indexterm zone="cryptsetup cryptsetup-prog">
|
---|
| 226 | <primary sortas="b-cryptsetup">cryptsetup</primary>
|
---|
| 227 | </indexterm>
|
---|
| 228 | </listitem>
|
---|
| 229 | </varlistentry>
|
---|
| 230 |
|
---|
[9f5dcb97] | 231 | <varlistentry id="cryptsetup-reencrypt">
|
---|
| 232 | <term><command>cryptsetup-reencrypt</command></term>
|
---|
| 233 | <listitem>
|
---|
| 234 | <para>
|
---|
| 235 | is a for offline LUKS device re-encryption.
|
---|
| 236 | </para>
|
---|
| 237 | <indexterm zone="cryptsetup cryptsetup-reencrypt">
|
---|
| 238 | <primary sortas="b-cryptsetup-reencrypt">cryptsetup-reencrypt</primary>
|
---|
| 239 | </indexterm>
|
---|
| 240 | </listitem>
|
---|
| 241 | </varlistentry>
|
---|
| 242 |
|
---|
| 243 | <varlistentry id="integritysetup">
|
---|
| 244 | <term><command>integritysetup</command></term>
|
---|
| 245 | <listitem>
|
---|
| 246 | <para>
|
---|
| 247 | is a tool to manage dm-integrity (block level integrity) volumes.
|
---|
| 248 | </para>
|
---|
| 249 | <indexterm zone="cryptsetup integritysetup">
|
---|
| 250 | <primary sortas="b-integritysetup">integritysetup</primary>
|
---|
| 251 | </indexterm>
|
---|
| 252 | </listitem>
|
---|
| 253 | </varlistentry>
|
---|
| 254 |
|
---|
[6dcb9e77] | 255 | <varlistentry id="veritysetup">
|
---|
| 256 | <term><command>veritysetup</command></term>
|
---|
| 257 | <listitem>
|
---|
| 258 | <para>
|
---|
| 259 | is used to configure dm-verity managed device-mapper mappings.
|
---|
| 260 | Device-mapper verity target provides read-only transparent integrity
|
---|
| 261 | checking of block devices using kernel crypto API.
|
---|
| 262 | </para>
|
---|
| 263 | <indexterm zone="cryptsetup veritysetup">
|
---|
| 264 | <primary sortas="b-veritysetup">veritysetup</primary>
|
---|
| 265 | </indexterm>
|
---|
| 266 | </listitem>
|
---|
| 267 | </varlistentry>
|
---|
| 268 |
|
---|
| 269 | </variablelist>
|
---|
| 270 |
|
---|
| 271 | </sect2>
|
---|
| 272 |
|
---|
| 273 | </sect1>
|
---|