verify failed (_ssl.c:590

Support for the Debian/Ubuntu package, created by JCFP.
Forum rules
Help us help you:
  • Are you using the latest stable version of SABnzbd? Downloads page.
  • Tell us what system you run SABnzbd on.
  • Adhere to the forum rules.
  • Do you experience problems during downloading?
    Check your connection in Status and Interface settings window.
    Use Test Server in Config > Servers.
    We will probably ask you to do a test using only basic settings.
  • Do you experience problems during repair or unpacking?
    Enable +Debug logging in the Status and Interface settings window and share the relevant parts of the log here using [ code ] sections.
Post Reply
jwhitt12
Full Member
Full Member
Posts: 107
Joined: April 18th, 2012, 6:44 pm

verify failed (_ssl.c:590

Post by jwhitt12 »

I am running with ubuntu 16.04 I am getting the following error on post processing:

Loading config from /home/greg/video/scripts/autoProcessTV.cfg

Opening URL: https://localhost:8081/home/postprocess ... 64-FLEET.1
Unable to open URL: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)>

I suspect my https is setup wrong. I have not sent my log as its working just fine, except for the post processing. My scripts have not changed for 2 years. My ini data can be found at:
http://pastebin.com/yRRwJgSn

I can also manually post process, from sickbeard, with no problem.

thank you...............
User avatar
sander
Release Testers
Release Testers
Posts: 8830
Joined: January 22nd, 2008, 2:22 pm

Re: verify failed (_ssl.c:590

Post by sander »

Ubuntu 16.04 has python 2.7.9+, which by default checks certificates.
You can't have a valid certificate on "localhost"
Result: refused.

Easy solution: use http instead of https on localhost
Other solution: read and implement https://forums.sabnzbd.org/viewtopic.ph ... 565#p98483 in the script.
jwhitt12
Full Member
Full Member
Posts: 107
Joined: April 18th, 2012, 6:44 pm

Re: verify failed (_ssl.c:590

Post by jwhitt12 »

sander;
I tried your fix. Don't know if its working yet but I have faith! Thank you!

(I posted this on the site you sent me to. My mistake ............... <sigh>
jwhitt12
Full Member
Full Member
Posts: 107
Joined: April 18th, 2012, 6:44 pm

Re: verify failed (_ssl.c:590

Post by jwhitt12 »

sander;
it didn't work. I got:

Loading config from /home/greg/video/scripts/autoProcessTV.cfg

Opening URL: https://localhost:8081/home/postprocess ... .x264-BATV
Unable to open URL: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)>

The changed code in SABNzbd looks like:

import re

opt_out_of_certificate_verification = True
if opt_out_of_certificate_verification:
try:
import ssl
ssl._create_default_https_context = ssl._create_unverified_context
except:
pass

try:
import Cheetah

Just want to make sure I am dealing with the right sabnzbd.py as I found another in .sabnzbd
which was 10.?kb long with completely different code than the SABnzbd.py

In the same topic where your fix was there was a suggestion to import some valid certificates from "https://pypi.python.org/pypi/certifi" and was wondering your thoughts on that one.

I also don't understand. This stuff is written for python and I am pretty clueless about programming for that (I do plain vanilla 'c') Anyway, I can goto sickbeard and manually do the post processing with no problem. All they need is the right folder and then you can choose which you want processed and it does it and returns the results. My misunderstanding is why there isn't a script that would do the same thing. Since this stuff is all open source why not just go into their source, grab the code (admitting same) and script it. (should add this is, probably, the thought of somebody without a clue <G>)

I also noted, in the site you sent me to, is that this problem is well known and I assume that somebody is dealing with it as we speak? This being the case I am quite willing to simply wait until a solution is figured out and dealt with.

Anyway, thanks for the help!
User avatar
sander
Release Testers
Release Testers
Posts: 8830
Joined: January 22nd, 2008, 2:22 pm

Re: verify failed (_ssl.c:590

Post by sander »

You're trying to fix it in SABnzbd, which is the incorrect place; SABnzbd has been fixed already a year ago.

You should fix it in "autoProcessTV.cfg", which is probably SickBeard, right?

Anyway: as I said, easier to use HTTP, not HTTPS.
jwhitt12
Full Member
Full Member
Posts: 107
Joined: April 18th, 2012, 6:44 pm

Re: verify failed (_ssl.c:590

Post by jwhitt12 »

I don't know how to change from https to https. In the setup it seems that if one is to use ssl it automatically becomes https. I changed my settings, in the auto process tv scripts (.py and .cfg) setting ssl to '0' from '1', etc. I have no idea what I am doing but those are the only changes I could find. Your thought on using http instead of https would be of real value as I may have missed something.

I won't know the results until sickbeard runs and things happen - THEN I will find out <G>

Thanks again ..............
jwhitt12
Full Member
Full Member
Posts: 107
Joined: April 18th, 2012, 6:44 pm

Re: verify failed (_ssl.c:590

Post by jwhitt12 »

I now have a complete mess. In sabnzbd I have a bunch of errors that look like:
2016-08-15 17:10:57,452::INFO::[downloader:673] Thread [email protected]: Article [email protected] missing (error=430)
2016-08-15 17:10:57,453::INFO::[decoder:261] <Article: article=[email protected], bytes=793230, partnum=18, art_id=None> => missing from all servers, discarding
2016-08-15 17:10:57,461::INFO::[downloader:673] Thread [email protected]: Article [email protected] missing (error=430)

I have no idea what all this means. I tested my connection, with my server and it connected just fine. There were 3 things to download. Two could not be completed and one had: download failed - not on your server. When I looked at the actual files there was one that had completed but remained in the uncomplete folder anyway.

for the heck of it my sickbeard error log had:
2016-08-15 17:23:09 CP Server Thread-7 :: git fetch origin returned : error: insufficient permission for adding an object to repository database .git/objects
fatal: failed to write object
fatal: unpack-objects failed
2016-08-15 17:23:09 CP Server Thread-7 :: Unable to contact github, can't check for update
2016-08-15 17:22:50 CP Server Thread-7 :: git fetch origin returned : error: insufficient permission for adding an object to repository database .git/objects
fatal: failed to write object
fatal: unpack-objects failed
2016-08-15 17:22:50 CP Server Thread-7 :: Unable to contact github, can't check for update
2016-08-15 16:42:54 CP Server Thread-5 :: TraktNotifier: coercing to Unicode: need string or buffer, instance found
2016-08-15 15:57:56 CHECKVERSION :: git fetch origin returned : error: insufficient permission for adding an object to repository database .git/objects
fatal: failed to write object
fatal: unpack-objects failed
2016-08-15 15:57:56 CHECKVERSION :: Unable to contact github, can't check for update
I got this error even when I manually tried to check the version. I will check this with the sickbeard folks.

Obviously I have now messed up something seriously with both sickbeard and sabnzbd.
jwhitt12
Full Member
Full Member
Posts: 107
Joined: April 18th, 2012, 6:44 pm

Re: verify failed (_ssl.c:590

Post by jwhitt12 »

I may have fixed the problem (won't know for a while) I have no idea what I did to do that but it seems to work.
Post Reply