[illumos-Developer] [REVIEW] 289 invalid padding when using java pkcs11 provider
Robert Gordon
rbg at openrbg.com
Fri Oct 8 17:38:02 PDT 2010
On Oct 8, 2010, at 6:12 PM, Jason King wrote:
> On Fri, Oct 8, 2010 at 1:38 PM, Garrett D'Amore <garrett at damore.org> wrote:
>> On Fri, 2010-10-08 at 14:11 -0400, Gordon Ross wrote:
>>> Oh, and the kmem_alloc needs another arg, I think :)
>>> i.e. KM_SLEEP
>>
>> That's an excellent point. The old code lacked the sleep parameter,
>> which makes me thing this code has never even compiled for kernel use.
>> (Which isn't surprising... there are no kernel consumers for DH -- the
>> only related use would be IKE, but IKE runs in userland.)
>>
>> Since we know *nothing* about the context where this would possibly
>> used, I think KM_NOSLEEP would be better.
>>
>> - Garrett
>
> It looks like most of the ones that are used in the kernel have a
> wrapper function that calls into the API to get the appropriate flag
> to use. I'd prefer to follow the example of the existing kernel
> providers and just add an argument that is only used in the kernel.
>
> With that here is an updated webrev w/ the suggested changes:
> http://cr.illumos.org/view/w041vj3b/
Super-NIT:
I'd suspect that dh_key_derive() in user-land is not lint clean (i've not tested that yet),
however since flag is not used in user-land lint would be all fussy about that.. so the addition
of /*ARGSUSED*/ would shut it up ;-)
Robert.
More information about the Developer
mailing list