Google Skupine ne podpirajo več novih objav ali naročnin v storitvi Usenet. Zgodovinsko vsebino si je še vedno mogoče ogledati.
Dismiss

[openssl-dev] Missing const EC_KEY *EC_KEY_dup(EC_KEY *src);

16 ogledov
Preskoči na prvo neprebrano sporočilo

Richard Moore

neprebran,
24. jul. 2016, 12:38:4524. 7. 16
do
Shouldn't this be  EC_KEY *EC_KEY_dup(const EC_KEY *src);

Cheers

Rich.


Salz, Rich

neprebran,
24. jul. 2016, 13:19:3624. 7. 16
do

> Shouldn't this be  EC_KEY *EC_KEY_dup(const EC_KEY *src);

I think the reason it is not is because the EC_KEY has an ENGINE* and that can't be const.

Sigh, C needs 'mutable' :)
--
openssl-dev mailing list
To unsubscribe: https://mta.openssl.org/mailman/listinfo/openssl-dev

Richard Levitte

neprebran,
24. jul. 2016, 16:06:0024. 7. 16
do
In message <a62628880fea43fa...@usma1ex-dag1mb1.msg.corp.akamai.com> on Sun, 24 Jul 2016 17:19:05 +0000, "Salz, Rich" <rs...@akamai.com> said:

rsalz>
rsalz> > Shouldn't this be  EC_KEY *EC_KEY_dup(const EC_KEY *src);
rsalz>
rsalz> I think the reason it is not is because the EC_KEY has an ENGINE* and that can't be const.

The pointer to ENGINE will be const, yes, but not the ENGINE content
itself, as if it was defined like this:

ENGINE * const engine;

What happens is that the ENGINE pointer is copied to the new
structure, and the ENGINE itself will work perfectly, both in the
source EC_KEY and the new one.

So there's no actual reason not to have const there. It does,
however, mean that we need to add const in a few more places. Now
many at all, actually, it took me 5 minutes. PR coming tomorrow.

Cheers,
Richard

--
Richard Levitte lev...@openssl.org
OpenSSL Project http://www.openssl.org/~levitte/

Richard Moore

neprebran,
26. jul. 2016, 12:08:1426. 7. 16
do
I meant to ask, should I make tickets for this and the missing DSA_bits()?

Cheers

Rich.

Salz, Rich

neprebran,
26. jul. 2016, 12:08:5526. 7. 16
do

> I meant to ask, should I make tickets for this and the missing DSA_bits()?

Tickets. Or ideally PR with code:)

Richard Moore via RT

neprebran,
30. jul. 2016, 10:26:4430. 7. 16
do
---------- Forwarded message ----------
From: Richard Moore <richm...@gmail.com>
Date: 24 July 2016 at 17:38
Subject: Missing const EC_KEY *EC_KEY_dup(EC_KEY *src);
To: opens...@openssl.org


Shouldn't this be EC_KEY *EC_KEY_dup(const EC_KEY *src);

Cheers

Rich.

--
Ticket here: http://rt.openssl.org/Ticket/Display.html?id=4638
Please log in as guest with password guest if prompted

Matt Caswell via RT

neprebran,
1. avg. 2016, 12:38:471. 8. 16
do
Fix for this was merged as 4a9a0d9bcb. Closing.

Matt
0 novih sporočil