From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ted Zlatanov Newsgroups: gmane.emacs.devel Subject: Re: Testing the gnutls support Date: Sat, 09 Oct 2010 23:50:55 -0500 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: <8762xalkgg.fsf@lifelogs.com> References: <87r5g0x0fd.fsf@lifelogs.com> <83mxqnmqqy.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1286686297 20636 80.91.229.12 (10 Oct 2010 04:51:37 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 10 Oct 2010 04:51:37 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Oct 10 06:51:36 2010 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1P4nsj-0003O2-Jx for ged-emacs-devel@m.gmane.org; Sun, 10 Oct 2010 06:51:33 +0200 Original-Received: from localhost ([127.0.0.1]:44289 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P4nsi-0008EO-Rf for ged-emacs-devel@m.gmane.org; Sun, 10 Oct 2010 00:51:32 -0400 Original-Received: from [140.186.70.92] (port=53981 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P4nsX-0008Ct-NA for emacs-devel@gnu.org; Sun, 10 Oct 2010 00:51:24 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1P4nsT-00042U-33 for emacs-devel@gnu.org; Sun, 10 Oct 2010 00:51:21 -0400 Original-Received: from lo.gmane.org ([80.91.229.12]:40858) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1P4nsS-00042J-MU for emacs-devel@gnu.org; Sun, 10 Oct 2010 00:51:17 -0400 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1P4nsN-0003CO-TZ for emacs-devel@gnu.org; Sun, 10 Oct 2010 06:51:11 +0200 Original-Received: from c-24-14-16-248.hsd1.il.comcast.net ([24.14.16.248]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 10 Oct 2010 06:51:11 +0200 Original-Received: from tzz by c-24-14-16-248.hsd1.il.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 10 Oct 2010 06:51:11 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 33 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: c-24-14-16-248.hsd1.il.comcast.net X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6; d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (gnu/linux) Cancel-Lock: sha1:vJ5fg5mqEa0JhFLg1URSYFQt0uk= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:131551 Archived-At: On Sat, 09 Oct 2010 15:56:04 +0200 Lars Magne Ingebrigtsen wrote: LMI> Eli Zaretskii writes: >>> Debugger entered--Lisp error: (file-error "writing to process" "interrupted system call" #>) >>> process-send-string(#> "GET /market.php HTTP/1.0.\n.\n") >> >> That's strange. process-send-string calls emacs_write to write to the >> process, but emacs_write already handles EINTR, by retrying the write >> which failed. So why does this signal raise a Lisp error? LMI> This is in emacs_gnutls_write, not emacs_write. But thanks for the LMI> tip -- it was indeed faulty EINTR handling. I've now peeked at the LMI> gnutls documentation and changed it to use the proper EINTR handling it LMI> needs, and it seems to work in my test cases now. Wonderful. Thanks for fixing the gnutls-boot plist symbols, too. I had a long conversation (er, mostly monologue) with the GnuTLS guys about the right way to set up callbacks and verification. So: 1) we should be verifying the host name matches the certificate--but should this be done in gnutls.el or gnutls.c? 2) we should set up a verification callback (but this is not available in mainstream Debian/Ubuntu yet, since it's new in 2.10). In the callback we should let the user accept an invalid certificate. I'd like to defer this until 2.10 is in the Debian mainstream. 3) We should give users a way to accept certificates. Right now they can pass a list of trust file names themselves but I think this should be a more general facility. Ted