Re: [PATCH -v3 3/4 cifs] NTLMv2/NTLMSSP define crypto hash functions and create and send keys needed for key exchange

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Sep 14, 2010 at 9:33 AM, Jeff Layton <jlayton@xxxxxxxxxx> wrote:
> On Tue, 14 Sep 2010 09:15:38 -0500
> Shirish Pargaonkar <shirishpargaonkar@xxxxxxxxx> wrote:
>
>> >> +                             /* 5 is an empirical value, large enought to
>> >> +                              * hold authenticate message, max 10 of
>> >> +                              * av paris, doamin,user,workstation mames,
>> >> +                              * flags etc..
>> >> +                              */
>> >> +                             ntlmsspblob = kmalloc(5 *
>> >> +                                     sizeof(struct _AUTHENTICATE_MESSAGE),
>> >> +                                     GFP_KERNEL);
>> >
>> >                                ^^^^ when does this get freed?
>>
>> It gets freed in build_ntlmssp_auth_blob, once the contents are copied.
>>
>
> I don't think it does. It gets passed to that function as the
> 'pbuffer', and then cast to 'sec_blob'. I don't see where it gets freed
> at all.
>
> Even if you're correct though, that's really messy and unclear. I
> think it would be best to free it in this function before you exit that
> block.
>
> --
> Jeff Layton <jlayton@xxxxxxxxxx>
>

Sure, I think that would be clearer.
--
To unsubscribe from this list: send the line "unsubscribe linux-cifs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux