caml-list - the Caml user's mailing list
 help / color / Atom feed
From: Gerd Stolpmann <info@gerd-stolpmann.de>
To: Alan Schmitt <alan.schmitt@polytechnique.org>,
	OCaml Mailing List <caml-list@inria.fr>
Subject: Re: [Caml-list] https and Ocamlnet
Date: Wed, 25 Sep 2019 17:47:33 +0200
Message-ID: <4ef6b3c5-8d04-e877-085b-99439eb42611@gerd-stolpmann.de> (raw)
In-Reply-To: <87impglc4p.fsf@polytechnique.org>

Hi Alan,

looks like that there is some incompatibility with one of the newer TLS
protocol features (like zero roundtrip), so that the TLS negotiation
fails. I don't have time to look into this right now, and cryptic errors
are also cryptic for the developer, but I'm definitely interested in
fixing this. Will just take a bit of time.

Gerd

Am 25.09.19 um 15:49 schrieb Alan Schmitt:
> Hello,
>
> I have a small utility that downloads and parses the RSS feed from
> ocaml.org to include in the OCaml Weekly News, but a recent change to
> ocaml.org broke it: it seems to only be served through https. I tried to
> add a TLS provider, but it's still failing with a cryptic error message.
>
> Here is an extract of the code showing the problem:
>
> #+begin_src ocaml
> let () = Nettls_gnutls.init()
>
> let site = "https://ocaml.org"
> let feed_name = "/feed.xml"
>
> let planet = Nethttp_fs.http_fs site
> let feedic = planet # read [] feed_name
> let feed_string = Netchannels.string_of_in_obj_channel feedic
> let () = feedic # close_in()
> #+end_src
>
> I can compile it with
>
> ocamlfind ocamlc -o test -linkpkg -package netclient,nettls-gnutls
> test.ml
>
> but when I run it, I get this error
>
> Fatal error: exception Nettls_gnutls.TLS.Error(GNUTLS_E_PUSH_ERROR)
>
> I know nothing of TLS and searching for the error did not point me
> toward any solution.
>
> I'm using gnutls 3.6.9 and ocamlnet 4.1.6.
>
> How can I access the site using https?
>
> Thanks,
>
> Alan

-- 
------------------------------------------------------------
Gerd Stolpmann, Darmstadt, Germany    gerd@gerd-stolpmann.de
My OCaml site:          http://www.camlcity.org
Contact details:        http://www.camlcity.org/contact.html
Company homepage:       http://www.gerd-stolpmann.de
------------------------------------------------------------



  parent reply index

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-25 13:49 Alan Schmitt
2019-09-25 14:52 ` Christophe TROESTLER
2019-09-25 15:47 ` Gerd Stolpmann [this message]
2019-09-26  6:20   ` Alan Schmitt
2019-09-26  6:27     ` Christophe TROESTLER
2019-09-26  6:56       ` Alan Schmitt
2019-09-26 13:41         ` Simon Cruanes
2019-09-26 15:44           ` Gerd Stolpmann
2019-09-27  6:31           ` Alan Schmitt
2019-09-27 13:53             ` Simon Cruanes
2019-09-26 14:39         ` Adrien Nader
2019-09-25 17:38 ` Oliver Bandel

Reply instructions:

You may reply publically 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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4ef6b3c5-8d04-e877-085b-99439eb42611@gerd-stolpmann.de \
    --to=info@gerd-stolpmann.de \
    --cc=alan.schmitt@polytechnique.org \
    --cc=caml-list@inria.fr \
    /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

caml-list - the Caml user's mailing list

Archives are clonable:
	git clone --mirror http://inbox.vuxu.org/caml-list
	git clone --mirror https://inbox.ocaml.org/caml-list

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://inbox.vuxu.org/vuxu.archive.caml-list


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git