summaryrefslogtreecommitdiff
path: root/scripts/image_signing/sample-test-configs/ensure_secure_kernelparams.config
blob: 9b78def0e7202838f43d949c77ef03e619481a9e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/bin/bash

# Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

#
# COMMON
#
required_kparams_common=( quiet console=tty2 init=/sbin/init add_efi_memmap
                          boot=local rootwait ro noresume noswap i915.modeset=1
                          loglevel=1 cros_secure kern_guid=%U tpm_tis.force=1
                          tpm_tis.interrupts=0 root=/dev/dm-0
                          dm_verity.error_behavior=3 dm_verity.max_bios=-1
                          dm_verity.dev_wait=1 noinitrd )

optional_kparams_common=( )
optional_kparams_regex_common=( )

# use "MAGIC_HASH" in place of the unpredictable sha1 hash, comparison
# functions later take care of the rest.... This set of dmparams
# taken from observation of current builds. In particular we may see
# the size of the filesystem creep over time. That size is denoted by
# the large number that appears a couple times in this string.
dmparams_common_list=('vroot none ro,0 1740800 verity %U+1 %U+1 1740800 0 sha1 MAGIC_HASH' 
'vroot none ro,0 1740800 verity payload=%U+1 hashtree=%U+1 hashstart=1740800 alg=sha1 root_hexdigest=MAGIC_HASH' 

'vroot none ro,0 1740800 verity payload=%U+1 hashtree=%U+1 hashstart=1740800 alg=sha1 root_hexdigest=MAGIC_HASH salt=MAGIC_SALT' 
)

#
# x86-mario
#
required_kparams_x86_mario=( ${required_kparams_common[@]} )
optional_kparams_x86_mario=( ${optional_kparams_common[@]} )
optional_kparams_regex_x86_mario=( ${optional_kparams_regex_common[@]} )
required_dmparams_x86_mario=("${required_dmparams_common[@]}")

# Set up additional boards here. The "common" variables are
# not directly consulted by the test script, they're only
# here for your convenience in building up the board-specific
# configuration variables like the 3 shown above.