Bug 1282864 - Missing important documentation in gnutls_x509_crt_set_key() and gnutls_pubkey_encrypt_data()
Summary: Missing important documentation in gnutls_x509_crt_set_key() and gnutls_pubke...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: gnutls
Version: 23
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Nikos Mavrogiannopoulos
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-11-17 16:30 UTC by Andreas Schneider
Modified: 2015-11-25 21:52 UTC (History)
3 users (show)

Fixed In Version: gnutls-3.4.7-1.fc23
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-11-25 21:52:18 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Andreas Schneider 2015-11-17 16:30:53 UTC
Description of problem:

gnutls_x509_crt_set_key() should have a reference to gnutls_pubkey_import_x509() so you can find out how to import it.

gnutls_pubkey_encrypt_data() doesn't document that the ciphertext is allocated using gnutls_alloc and needs to be freed!

Comment 1 Nikos Mavrogiannopoulos 2015-11-18 08:26:19 UTC
I've added that text to solve the second point.
https://gitlab.com/gnutls/gnutls/commit/09d8d8a89f56cf63745b82834945fa33a1a7654e

I'm not sure how gnutls_pubkey_import_x509() fits into the description of gnutls_x509_crt_set_key(). Could you elaborate or suggest some text?

Comment 2 Andreas Schneider 2015-11-19 10:43:34 UTC
If you have use doxygen you normally just add a reference using:

@see gnutls_pubkey_import_x509()


Or you would write:

To export the public key from the PublicKeyInfo part again, you can do this using gnutls_pubkey_import_x509().


I was looking for gnutls_x509_crt_get_key() or gnutls_x509_crt_get_pubkey(), but there is no such function. I wasn't obvious for me that I have to look in the pubkey import functions. So a simple reference would already help.

Comment 3 Fedora Update System 2015-11-23 10:11:06 UTC
gnutls-3.4.7-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-9b8c741e68

Comment 4 Fedora Update System 2015-11-24 02:23:13 UTC
gnutls-3.4.7-1.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
If you want to test the update, you can install it with
$ su -c 'dnf --enablerepo=updates-testing update gnutls'
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-9b8c741e68

Comment 5 Fedora Update System 2015-11-25 21:52:09 UTC
gnutls-3.4.7-1.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.