Re: [Suspend-devel] [PATCH] writeout_time not saved with CONFIG_ENCRYPT=yes

2007-01-22 Thread Rafael J. Wysocki
On Monday, 22 January 2007 21:53, Tim Dijkstra wrote: > On Mon, 22 Jan 2007 18:48:30 +0100 > Michal Schmidt <[EMAIL PROTECTED]> wrote: > > > Consider adding this one too. It makes RSA_data itself much smaller. Not > > all RSA components need to take 512 bytes: > > Yes I noticed this too, but it

Re: [Suspend-devel] [PATCH] writeout_time not saved with CONFIG_ENCRYPT=yes

2007-01-22 Thread Tim Dijkstra
On Mon, 22 Jan 2007 18:48:30 +0100 Michal Schmidt <[EMAIL PROTECTED]> wrote: > Consider adding this one too. It makes RSA_data itself much smaller. Not > all RSA components need to take 512 bytes: Yes I noticed this too, but it didn't seem relevant at the time. Patch looks good. grts Tim -

Re: [Suspend-devel] [PATCH] writeout_time not saved with CONFIG_ENCRYPT=yes

2007-01-22 Thread Michal Schmidt
Rafael J. Wysocki wrote: I'm going to apply your previous patch as a short term fix. Consider adding this one too. It makes RSA_data itself much smaller. Not all RSA components need to take 512 bytes: n - the modulus - can be as big as 4096 bits = 512 bytes. e - public exponent - the usual ch

Re: [Suspend-devel] [PATCH] writeout_time not saved with CONFIG_ENCRYPT=yes

2007-01-21 Thread Rafael J. Wysocki
On Saturday, 20 January 2007 02:46, Michal Schmidt wrote: > Rafael J. Wysocki wrote: > > Hm, as far as I remember, key_data is not just plain key and it can be > > greater than 512 bytes. And that would explain one bug report related > > to > > the encryption with RSA. > > (struct encrypted

Re: [Suspend-devel] [PATCH] writeout_time not saved with CONFIG_ENCRYPT=yes

2007-01-19 Thread Michal Schmidt
Michal Schmidt wrote: You can take a look at the attached patch, which shrinks struct swsusp_info to 2028 bytes on i386. This is achieved by only saving the components (n, e, d). I am _not_ proposing to merge this one, because it requires a slightly modified libgcrypt to work. Original libgcryp

Re: [Suspend-devel] [PATCH] writeout_time not saved with CONFIG_ENCRYPT=yes

2007-01-19 Thread Michal Schmidt
Rafael J. Wysocki wrote: Hm, as far as I remember, key_data is not just plain key and it can be greater than 512 bytes. And that would explain one bug report related to the encryption with RSA. (struct encrypted_key).data contains the encrypted pair (k, i). The session key (k) is 16 bytes an

Re: [Suspend-devel] [PATCH] writeout_time not saved with CONFIG_ENCRYPT=yes

2007-01-18 Thread Rafael J. Wysocki
Hi, On Thursday, 18 January 2007 15:04, Michal Schmidt wrote: > Hi, > > When saving the image, uswsusp measures the time it takes and saves it > in the writeout_time member of struct swsusp_info. During resume the > information is printed. I found this feature useful. Unfortunately, it > doesn

[Suspend-devel] [PATCH] writeout_time not saved with CONFIG_ENCRYPT=yes

2007-01-18 Thread Michal Schmidt
Hi, When saving the image, uswsusp measures the time it takes and saves it in the writeout_time member of struct swsusp_info. During resume the information is printed. I found this feature useful. Unfortunately, it doesn't work when configured with CONFIG_ENCRYPT=yes. The reason is that stru