Kconfig 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. # IBM Integrity Measurement Architecture
  2. #
  3. config IMA
  4. bool "Integrity Measurement Architecture(IMA)"
  5. depends on SECURITY
  6. select INTEGRITY
  7. select SECURITYFS
  8. select CRYPTO
  9. select CRYPTO_HMAC
  10. select CRYPTO_MD5
  11. select CRYPTO_SHA1
  12. select CRYPTO_HASH_INFO
  13. select TCG_TPM if HAS_IOMEM && !UML
  14. select TCG_TIS if TCG_TPM && X86
  15. select TCG_IBMVTPM if TCG_TPM && PPC64
  16. help
  17. The Trusted Computing Group(TCG) runtime Integrity
  18. Measurement Architecture(IMA) maintains a list of hash
  19. values of executables and other sensitive system files,
  20. as they are read or executed. If an attacker manages
  21. to change the contents of an important system file
  22. being measured, we can tell.
  23. If your system has a TPM chip, then IMA also maintains
  24. an aggregate integrity value over this list inside the
  25. TPM hardware, so that the TPM can prove to a third party
  26. whether or not critical system files have been modified.
  27. Read <http://www.usenix.org/events/sec04/tech/sailer.html>
  28. to learn more about IMA.
  29. If unsure, say N.
  30. config IMA_MEASURE_PCR_IDX
  31. int
  32. depends on IMA
  33. range 8 14
  34. default 10
  35. help
  36. IMA_MEASURE_PCR_IDX determines the TPM PCR register index
  37. that IMA uses to maintain the integrity aggregate of the
  38. measurement list. If unsure, use the default 10.
  39. config IMA_LSM_RULES
  40. bool
  41. depends on IMA && AUDIT && (SECURITY_SELINUX || SECURITY_SMACK)
  42. default y
  43. help
  44. Disabling this option will disregard LSM based policy rules.
  45. choice
  46. prompt "Default template"
  47. default IMA_NG_TEMPLATE
  48. depends on IMA
  49. help
  50. Select the default IMA measurement template.
  51. The original 'ima' measurement list template contains a
  52. hash, defined as 20 bytes, and a null terminated pathname,
  53. limited to 255 characters. The 'ima-ng' measurement list
  54. template permits both larger hash digests and longer
  55. pathnames.
  56. config IMA_TEMPLATE
  57. bool "ima"
  58. config IMA_NG_TEMPLATE
  59. bool "ima-ng (default)"
  60. config IMA_SIG_TEMPLATE
  61. bool "ima-sig"
  62. endchoice
  63. config IMA_DEFAULT_TEMPLATE
  64. string
  65. depends on IMA
  66. default "ima" if IMA_TEMPLATE
  67. default "ima-ng" if IMA_NG_TEMPLATE
  68. default "ima-sig" if IMA_SIG_TEMPLATE
  69. choice
  70. prompt "Default integrity hash algorithm"
  71. default IMA_DEFAULT_HASH_SHA1
  72. depends on IMA
  73. help
  74. Select the default hash algorithm used for the measurement
  75. list, integrity appraisal and audit log. The compiled default
  76. hash algorithm can be overwritten using the kernel command
  77. line 'ima_hash=' option.
  78. config IMA_DEFAULT_HASH_SHA1
  79. bool "SHA1 (default)"
  80. depends on CRYPTO_SHA1
  81. config IMA_DEFAULT_HASH_SHA256
  82. bool "SHA256"
  83. depends on CRYPTO_SHA256 && !IMA_TEMPLATE
  84. config IMA_DEFAULT_HASH_SHA512
  85. bool "SHA512"
  86. depends on CRYPTO_SHA512 && !IMA_TEMPLATE
  87. config IMA_DEFAULT_HASH_WP512
  88. bool "WP512"
  89. depends on CRYPTO_WP512 && !IMA_TEMPLATE
  90. endchoice
  91. config IMA_DEFAULT_HASH
  92. string
  93. depends on IMA
  94. default "sha1" if IMA_DEFAULT_HASH_SHA1
  95. default "sha256" if IMA_DEFAULT_HASH_SHA256
  96. default "sha512" if IMA_DEFAULT_HASH_SHA512
  97. default "wp512" if IMA_DEFAULT_HASH_WP512
  98. config IMA_APPRAISE
  99. bool "Appraise integrity measurements"
  100. depends on IMA
  101. default n
  102. help
  103. This option enables local measurement integrity appraisal.
  104. It requires the system to be labeled with a security extended
  105. attribute containing the file hash measurement. To protect
  106. the security extended attributes from offline attack, enable
  107. and configure EVM.
  108. For more information on integrity appraisal refer to:
  109. <http://linux-ima.sourceforge.net>
  110. If unsure, say N.
  111. config IMA_TRUSTED_KEYRING
  112. bool "Require all keys on the _ima keyring be signed"
  113. depends on IMA_APPRAISE && SYSTEM_TRUSTED_KEYRING
  114. default y
  115. help
  116. This option requires that all keys added to the _ima
  117. keyring be signed by a key on the system trusted keyring.