1

I am using tornado framework and doing certificate authentication but I am getting following error :

SSLError: [Errno 8] _ssl.c:510: EOF occurred in violation of protocol

I am using below code:

http_server = tornado.httpserver.HTTPServer(HomeHandler()
              ,ssl_options=dict(
               certfile="cert/certificate.crt",
               keyfile="cert/certificate.key",
               cert_reqs=ssl.CERT_REQUIRED,
               ca_certs="cert/cacertificate.crt",
               #ssl_version=ssl.PROTOCOL_TLSv1
               )
               )

Thanks in advance

Reetesh Nigam
  • 133
  • 2
  • 2
  • 15
  • which version of python 2.7? there was some problems in older ones with ssl version as in http://stackoverflow.com/questions/16748994/python-ssl-connection-eof-occurred-in-violation-of-protocol – kwarunek Dec 11 '15 at 17:24
  • What exactly are you doing that triggers this error? Does it happen all the time or does it just appear in your logs? If the latter, it may be the normal result of a client going away (this is logged less noisily in the most recent versions of tornado) – Ben Darnell Dec 12 '15 at 01:15
  • @kAlmAcetA: I am using Python 2.7.8 and tornado '4.0' version – Reetesh Nigam Dec 14 '15 at 04:45
  • @BenDarnell: yes it appear in my logs all the time. I have tried couple of monkey patches but could not resolve it. – Reetesh Nigam Dec 14 '15 at 04:52
  • This error should no longer be logged in Tornado 4.2. – Ben Darnell Dec 14 '15 at 14:58
  • @BenDarnell: Do we have any patch for tornado 4.0 to make this working ? – Reetesh Nigam Dec 15 '15 at 02:54
  • 1
    The log messages are harmless, everything is working. You could dig through the git logs if you want to backport the logging change, but I would really recommend upgrading to 4.3 instead. – Ben Darnell Dec 15 '15 at 03:09
  • @BenDarnell: Thank you – Reetesh Nigam Dec 15 '15 at 03:11
  • @BenDarnell since this is solution (ignore or upgrade), consider posting an answer – kwarunek Jan 03 '16 at 08:23

1 Answers1

0

I have upgraded tornado version to 4.3 and no ssl error I am getting now.

Reetesh Nigam
  • 133
  • 2
  • 2
  • 15