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]
Date:	Wed, 5 Sep 2012 02:17:31 +0300
From:	"Kasatkin, Dmitry" <dmitry.kasatkin@...el.com>
To:	David Howells <dhowells@...hat.com>
Cc:	Lucas De Marchi <lucas.de.marchi@...il.com>,
	Rusty Russell <rusty@...tcorp.com.au>,
	zohar@...ux.vnet.ibm.com, jmorris@...ei.org,
	keyrings@...ux-nfs.org, linux-security-module@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [RFC] module: signature infrastructure

On Wed, Sep 5, 2012 at 1:51 AM, David Howells <dhowells@...hat.com> wrote:
> Lucas De Marchi <lucas.de.marchi@...il.com> wrote:
>
>> Or let the magic string as the last thing in the module and store the
>> signature length, too. In this case no scanning is needed
>
> Indeed.  This is the better way.
>
> The main problem is rendering the length from a shell script.  It's trivial to
> do as ASCII (there's a printf program), but a pain to render to binary.  I'm
> sure it can be done with perl or python without the need to compile anything.
>
> David

That is very easy to do from script as well.
See script in my tree.

http://git.kernel.org/?p=linux/kernel/git/kasatkin/linux-digsig.git;a=blob;f=scripts/modsig.sh;h=4e997c3996d71d8e1afeb3a7afe23b3f303b9f63;hb=59f1d5352969166f2f32f84e07e20dd1b30a890f

110 # add signature length - big endian
111 dec2hex $(stat --printf %s $sigfile) 4 | hex2bin $sigfile
112 echo -n "This Is A Crypto Signed Module" >>$sigfile

well. I have couple of small functions in the script. dec2hex and hex2bin

- Dmitry
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ