System.IO.IOException: The authentication or decryption has failed

Hi

Is this a known bug please ? Many thank. fLo

System.IO.IOException: The authentication or decryption has failed. ---> Mono.Security.Protocol.Tls.TlsException: The authentication or decryption has failed

Full error:

[Error] UTorrent: Downloading torrentfile for episode 'The.Big.Bang.Theory.S08E20.720p.HDTV.X264-DIMENSION' failed (https://broadcasthe.net/torrents.php?action=download&id=496311&authkey=xxxxxxxxxxx&torrent_pass=xxxxxxxxx) 

System.Net.WebException: Error: SendFailure (Error writing headers) ---> System.Net.WebException: Error writing headers ---> System.IO.IOException: The authentication or decryption has failed. ---> Mono.Security.Protocol.Tls.TlsException: The authentication or decryption has failed.
  at Mono.Security.Protocol.Tls.RecordProtocol.ProcessAlert (AlertLevel alertLevel, AlertDescription alertDesc) [0x00000] in <filename unknown>:0 
  at Mono.Security.Protocol.Tls.RecordProtocol.InternalReceiveRecordCallback (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at Mono.Security.Protocol.Tls.SslClientStream.EndNegotiateHandshake (IAsyncResult result) [0x00000] in <filename unknown>:0 
  at Mono.Security.Protocol.Tls.SslStreamBase.AsyncHandshakeCallback (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  --- End of inner exception stack trace ---
  at System.Net.HttpWebRequest.EndGetResponse (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 
  at System.Net.HttpWebRequest.GetResponse () [0x00000] in <filename unknown>:0 
  at NzbDrone.Common.Http.HttpClient.Execute (NzbDrone.Common.Http.HttpRequest request) [0x00000] in <filename unknown>:0 

[Error] ReleaseModule: Downloading torrent failed 

NzbDrone.Core.Exceptions.ReleaseDownloadException: Downloading torrent failed ---> System.Net.WebException: Error: SendFailure (Error writing headers) ---> System.Net.WebException: Error writing headers ---> System.IO.IOException: The authentication or decryption has failed. ---> Mono.Security.Protocol.Tls.TlsException: The authentication or decryption has failed.
  at Mono.Security.Protocol.Tls.RecordProtocol.ProcessAlert (AlertLevel alertLevel, AlertDescription alertDesc) [0x00000] in <filename unknown>:0 
  at Mono.Security.Protocol.Tls.RecordProtocol.InternalReceiveRecordCallback (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at Mono.Security.Protocol.Tls.SslClientStream.EndNegotiateHandshake (IAsyncResult result) [0x00000] in <filename unknown>:0 
  at Mono.Security.Protocol.Tls.SslStreamBase.AsyncHandshakeCallback (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  --- End of inner exception stack trace ---
  at System.Net.HttpWebRequest.EndGetResponse (IAsyncResult asyncResult) [0x00000] in <filename unknown>:0 
  at System.Net.HttpWebRequest.GetResponse () [0x00000] in <filename unknown>:0 
  at NzbDrone.Common.Http.HttpClient.Execute (NzbDrone.Common.Http.HttpRequest request) [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at NzbDrone.Core.Download.TorrentClientBase`1[NzbDrone.Core.Download.Clients.UTorrent.UTorrentSettings].DownloadFromWebUrl (NzbDrone.Core.Parser.Model.RemoteEpisode remoteEpisode, System.String torrentUrl) [0x00000] in <filename unknown>:0 
  at NzbDrone.Core.Download.TorrentClientBase`1[NzbDrone.Core.Download.Clients.UTorrent.UTorrentSettings].Download (NzbDrone.Core.Parser.Model.RemoteEpisode remoteEpisode) [0x00000] in <filename unknown>:0 
  at NzbDrone.Core.Download.DownloadService.DownloadReport (NzbDrone.Core.Parser.Model.RemoteEpisode remoteEpisode) [0x00000] in <filename unknown>:0 
  at NzbDrone.Api.Indexers.ReleaseModule.DownloadRelease (NzbDrone.Api.Indexers.ReleaseResource release) [0x00000] in <filename unknown>:0 

Mono:

Mono JIT compiler version 3.10.0 (tarball Wed Nov  5 12:50:04 UTC 2014)
Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
	TLS:           __thread
	SIGSEGV:       altstack
	Notifications: epoll
	Architecture:  amd64
	Disabled:      none
	Misc:          softdebug 
	LLVM:          supported, not enabled.
	GC:            sgen

BTN is currently using an unsupported CloudFlare SSL certificate since they have some back online. It is something they will need to fix (and I believe its something they are still looking into).

ok thanks… until BTN fix there end or there is a work around for Mono, maybe you could add a fallback mechanism so if the Mono call fails then just make a system call to curl/wget if installed. Grab the .torrent that way.

I believe you need curl 7.37+ for this to work.