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: <alpine.LSU.2.21.2202091526260.32090@pobox.suse.cz>
Date:   Wed, 9 Feb 2022 15:28:49 +0100 (CET)
From:   Miroslav Benes <mbenes@...e.cz>
To:     Aaron Tomlin <atomlin@...hat.com>
cc:     mcgrof@...nel.org, cl@...ux.com, pmladek@...e.com,
        akpm@...ux-foundation.org, jeyu@...nel.org,
        linux-kernel@...r.kernel.org, linux-modules@...r.kernel.org,
        live-patching@...r.kernel.org, atomlin@...mlin.com,
        ghalat@...hat.com, allen.lkml@...il.com, void@...ifault.com,
        joe@...ches.com
Subject: Re: [RFC PATCH v4 07/13] module: Move extra signature support out
 of core code

> diff --git a/include/linux/module.h b/include/linux/module.h
> index 520c0f4bb968..15ba2ebbca3e 100644
> --- a/include/linux/module.h
> +++ b/include/linux/module.h
> @@ -720,8 +720,8 @@ static inline bool set_livepatch_module(struct module *mod)
>  	return false;
>  }
>  
> -bool is_module_sig_enforced(void);
> -void set_module_sig_enforced(void);
> +extern bool is_module_sig_enforced(void);
> +extern void set_module_sig_enforced(void);

Please, drop these extern modifiers in front of function declarations. 
They are unnecessary. It applies to different patches of the set as well.
  
>  #else /* !CONFIG_MODULES... */
>  
> @@ -911,6 +911,7 @@ static inline bool module_sig_ok(struct module *module)
>  {
>  	return true;
>  }
> +#define sig_enforce false
>  #endif	/* CONFIG_MODULE_SIG */
>  
>  int module_kallsyms_on_each_symbol(int (*fn)(void *, const char *,
> diff --git a/kernel/module/internal.h b/kernel/module/internal.h
> index de28d6bb7b5b..2ec2a1d9dd9f 100644
> --- a/kernel/module/internal.h
> +++ b/kernel/module/internal.h
> @@ -114,3 +114,12 @@ static struct module *mod_find(unsigned long addr)
>  	return NULL;
>  }
>  #endif /* CONFIG_MODULES_TREE_LOOKUP */
> +
> +#ifdef CONFIG_MODULE_SIG
> +extern int module_sig_check(struct load_info *info, int flags);
> +#else /* !CONFIG_MODULE_SIG */
> +static int module_sig_check(struct load_info *info, int flags)
> +{
> +	return 0;
> +}

I think it should be 

static inline int module_sig_check(struct load_info *info, int flags)

Thanks,
Miroslav

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ