From: Paul Eggert <eggert@cs.ucla.edu>
To: Glenn Morris <rgm@gnu.org>
Cc: Emacs developers <emacs-devel@gnu.org>,
Noam Postavsky <npostavs@users.sourceforge.net>
Subject: Re: master 583995c: GnuTLS HMAC and symmetric cipher support
Date: Tue, 18 Jul 2017 13:44:14 -0700 [thread overview]
Message-ID: <f6146ef8-4ad0-b1e7-8d78-2f0657ce4a48@cs.ucla.edu> (raw)
In-Reply-To: <n54lu9lh3r.fsf@fencepost.gnu.org>
[-- Attachment #1: Type: text/plain, Size: 771 bytes --]
Glenn Morris wrote:
> I was using ftp://ftp.gnutls.org/gcrypt/gnutls/v3.2/gnutls-3.2.21.tar.xz
Weird, because I was looking at the same source code. It does not build under
recent Ubuntu or Fedora, so I did not compile it: I just looked at the source
code. Its implementation of gnutls_cipher_list appears to be straightforward: it
adds only values found as the 'id' component of an entry in the 'algorithms'
array in lib/algorithms/ciphers.c. None of these values are
GNUTLS_CIPHER_UNKNOWN, so gnutls_cipher_list cannot possibly return an array
containing GNUTLS_CIPHER_UNKNOWN.
For example, on my platform, if I compile and run the attached program via:
gcc gs.c -lgnutls
./a.out
the program silently succeeds. What happens on your platform?
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: gs.c --]
[-- Type: text/x-csrc; name="gs.c", Size: 387 bytes --]
#include <gnutls/gnutls.h>
#include <stdio.h>
int
main (void)
{
const gnutls_cipher_algorithm_t *gciphers = gnutls_cipher_list ();
for (int pos = 0; gciphers[pos] != 0; pos++)
{
gnutls_cipher_algorithm_t gca = gciphers[pos];
if (gca == GNUTLS_CIPHER_UNKNOWN)
return printf ("gciphers[%d] == GNUTLS_CIPHER_UNKNOWN ?!?\n", pos), 1;
}
return 0;
}
next prev parent reply other threads:[~2017-07-18 20:44 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20170714150706.13106.18905@vcs0.savannah.gnu.org>
[not found] ` <20170714150707.5E9B322DF8@vcs0.savannah.gnu.org>
2017-07-17 0:05 ` master 583995c: GnuTLS HMAC and symmetric cipher support Glenn Morris
2017-07-17 14:18 ` Ted Zlatanov
2017-07-17 14:30 ` Michael Albinus
2017-07-17 14:50 ` Ted Zlatanov
2017-07-17 18:22 ` Michael Albinus
2017-07-17 17:12 ` Glenn Morris
2017-07-17 17:19 ` Noam Postavsky
2017-07-17 18:20 ` Glenn Morris
2017-07-17 18:45 ` Noam Postavsky
2017-07-17 19:27 ` Glenn Morris
2017-07-17 19:44 ` Paul Eggert
2017-07-17 21:37 ` Glenn Morris
2017-07-17 21:58 ` Paul Eggert
2017-07-17 22:14 ` Glenn Morris
2017-07-18 0:59 ` Paul Eggert
2017-07-18 2:33 ` Glenn Morris
2017-07-18 7:45 ` Paul Eggert
2017-07-18 18:44 ` Glenn Morris
2017-07-18 20:44 ` Paul Eggert [this message]
2017-07-18 21:02 ` Glenn Morris
2017-07-18 21:16 ` Paul Eggert
2017-07-18 21:29 ` Glenn Morris
2017-07-23 19:18 ` Ted Zlatanov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=f6146ef8-4ad0-b1e7-8d78-2f0657ce4a48@cs.ucla.edu \
--to=eggert@cs.ucla.edu \
--cc=emacs-devel@gnu.org \
--cc=npostavs@users.sourceforge.net \
--cc=rgm@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).