[openssl-dev] [openssl.org #4518] OpenSSL-1.1.0-pre5 RSA_set0_key and related RSA_get0_*, RSA_set0_*, DSA_set0_* and DSA_get0_* problems

Salz, Rich rsalz at akamai.com
Mon Apr 25 17:45:05 UTC 2016


> The 3-slot function is I think cleaner.
> 
> I'll leave the decision of whether and when to support NULL parameters to
> the folks working on that code, but it is pretty clear that one must not pass an
> object one does not "own", such as one returned from a "get0" function, to a
> function that expects to take ownership of the indicated object.

Agree with both of those.

After a "set0" call, set your pointer to NULL, it's no longer yours :)


More information about the openssl-dev mailing list