Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

apparmor: clarify CRYPTO dependency

The crypto framework can be built as a loadable module, but the
apparmor hash code can only be built-in, which then causes a
link error:

security/built-in.o: In function `aa_calc_profile_hash':
integrity_audit.c:(.text+0x21610): undefined reference to `crypto_shash_update'
security/built-in.o: In function `init_profile_hash':
integrity_audit.c:(.init.text+0xb4c): undefined reference to `crypto_alloc_shash'

This changes Apparmor to use 'select CRYPTO' like a lot of other
subsystems do.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: John Johansen <john.johansen@canonical.com>
Signed-off-by: James Morris <james.l.morris@oracle.com>

authored by

Arnd Bergmann and committed by
James Morris
083c1290 09302fd1

+1 -1
+1 -1
security/apparmor/Kconfig
··· 33 33 config SECURITY_APPARMOR_HASH 34 34 bool "SHA1 hash of loaded profiles" 35 35 depends on SECURITY_APPARMOR 36 - depends on CRYPTO 36 + select CRYPTO 37 37 select CRYPTO_SHA1 38 38 default y 39 39