lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170117044921.GI9045@packer-debian-8-amd64.digitalocean.com>
Date:   Mon, 16 Jan 2017 23:49:21 -0500
From:   Jessica Yu <jeyu@...hat.com>
To:     Abel Vesa <abelvesa@...ux.com>
Cc:     linux@...linux.org.uk, jpoimboe@...hat.com, jikos@...nel.org,
        mbenes@...e.cz, pmladek@...e.com, rostedt@...dmis.org,
        mingo@...hat.com, gregkh@...uxfoundation.org,
        geert+renesas@...der.be, davem@...emloft.net,
        akpm@...ux-foundation.org, emil.l.velikov@...il.com,
        mchehab@...nel.org, linux@...ck-us.net, ard.biesheuvel@...aro.org,
        jens.wiklander@...aro.org, jean-philippe.brucker@....com,
        viro@...iv.linux.org.uk, stefano.stabellini@...citrix.com,
        chris.brandt@...esas.com, linux-kernel@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org, live-patching@...r.kernel.org
Subject: Re: arm: module: Add apply_relocate_add

+++ Abel Vesa [06/12/16 17:06 +0000]:
>It was only added to fix compiler error. It is not implemented
>yet.
>
>Signed-off-by: Abel Vesa <abelvesa@...ux.com>
>---
> arch/arm/kernel/module.c | 9 +++++++++
> 1 file changed, 9 insertions(+)
>
>diff --git a/arch/arm/kernel/module.c b/arch/arm/kernel/module.c
>index 4f14b5c..bf94922 100644
>--- a/arch/arm/kernel/module.c
>+++ b/arch/arm/kernel/module.c
>@@ -52,6 +52,15 @@ void *module_alloc(unsigned long size)
> #endif
>
> int
>+apply_relocate_add(Elf32_Shdr *sechdrs, const char *strtab,
>+		   unsigned int symindex, unsigned int relindex,
>+		   struct module *module)
>+{
>+	/* Not implemented yet */
>+	return 0;
>+}

Are SHT_RELA relocation sections actually supported on 32-bit arm? It looks
like there's only support for SHT_REL.

arch/arm/Kconfig:84:	select MODULES_USE_ELF_REL

If we support SHT_REL sections, the correct fix is to probably have
klp_write_object_relocations() check if the relocation section is
SHT_REL or SHT_RELA, and call the appropriate function (apply_relocate
or apply_relocate_add), similar to how the module loader does it.

Jessica

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ