public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: John Sigler <linux.kernel@free.fr>
To: Jan Engelhardt <jengelh@linux01.gwdg.de>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Dumping the checksums in a module
Date: Wed, 23 May 2007 17:18:20 +0200	[thread overview]
Message-ID: <46545B3C.9070901@free.fr> (raw)
In-Reply-To: <Pine.LNX.4.61.0705222149160.4452@yvahk01.tjqt.qr>

Jan Engelhardt wrote:
> On May 22 2007 10:13, John Sigler wrote:
>>>> How do I list the checksums within a module?
>>>> Is there a simpler way to list all the checksums?
>>> 22:25 ichi:~ > modinfo aes
>>> srcversion:     8CB82B3A254D5A950FD0D14
>>>
>>> I think this one checksum is computed out of all functions that
>>> the module uses.
>> You've enabled MODULE_SRCVERSION_ALL which adds a checksum computed from the
>> source files used to build a given module. What I want is to list ALL the
>> checksums of the symbols included inside a given module.
>>
>> e.g. for the kernel:
> 
> for i in `nm 
> /lib/modules/2.6.18.8-ccj45-default/kernel/block/as-iosched.ko |
> grep " U " | cut -b 20-`; do
>     grep '\b'"$i"'\b' Module.symvers;
> done;
> 
> (for 32-bit, use `cut -b 12-`)

I think you didn't understand my request.

I have a *binary* kernel module that was compiled with 
CONFIG_MODVERSIONS enabled.

Thus, that binary module includes 32-bit (?) checksums for several 
kernel functions AND kernel structures.

cf. my original post:

$ hexdump -C test.ko | grep -A2 struct_
000752e0  17 98 07 0e 73 74 72 75  63 74 5f 6d 6f 64 75 6c 
|....struct_modul|
000752f0  65 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00 
|e...............|
00075300  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00 
|................|

For example, the checksum for "struct_module" seems to be 0x1798070e.

Is there a tool (from linux-module-init-tools?) to list all the 
checksums included in a binary module.

Regards.

  reply	other threads:[~2007-05-23 15:18 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-18 15:02 Dumping the checksums in a module John Sigler
2007-05-18 20:27 ` Jan Engelhardt
2007-05-18 20:46   ` Sam Ravnborg
2007-05-22  8:19     ` John Sigler
2007-05-22  8:13   ` John Sigler
2007-05-22 19:53     ` Jan Engelhardt
2007-05-23 15:18       ` John Sigler [this message]
  -- strict thread matches above, loose matches on Subject: below --
2007-06-19 11:59 John Sigler
2007-06-19 13:18 ` Arjan van de Ven
2007-06-19 14:40   ` John Sigler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=46545B3C.9070901@free.fr \
    --to=linux.kernel@free.fr \
    --cc=jengelh@linux01.gwdg.de \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox