szn / confluence.md

Markdown to Confluence - upload any .md files to your Confluence cloud page
23 stars 10 forks source link

SSLCertVerifiacation error #11

Closed revoldver closed 7 months ago

revoldver commented 11 months ago

Hello to all!

Got error for local Confluence installation with custom certificates: HTTPSConnectionPool(host='host.example.com', port=443): Max retries exceeded with url: /rest/api/content/0000000?expand=space (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1131)')))

How to skip or disable SSL certificate verification for Confluence host?

Thank you!

szn commented 11 months ago

hi @revoldver,

I don't have a local Confluence to check that so it's a blind shot:

Are you trying to connect to your host via HTTP (port 443/8443) with a broken/no SSL certificate? If so, does your Confluence listen on port 80/8080 (non-ssl HTTP)?

revoldver commented 11 months ago

I trying to connect via HTTPS (port 443), connection via plain HTTP (80) is not possible.

Could you please add ssl_verify as an additional run option via overriding init params for Atlassian class: https://github.com/atlassian-api/atlassian-python-api/blob/master/atlassian/rest_client.py#L53 ?

Thank you!

szn commented 11 months ago

Thanks for a hint. Silly me – I was looking for that option in the documentation, not the source.

Can you please check this fix?

python -m pip install --index-url https://test.pypi.org/simple/ --upgrade confluence.md

Then, you need to use the newly created --no_verify_ssl option.