Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SSL Certificate Not Sent #1573

Closed
2 of 4 tasks
Minweiwangaaaa opened this issue Dec 6, 2022 · 0 comments · Fixed by #1631
Closed
2 of 4 tasks

SSL Certificate Not Sent #1573

Minweiwangaaaa opened this issue Dec 6, 2022 · 0 comments · Fixed by #1631

Comments

@Minweiwangaaaa
Copy link

Bug summary

error

  File "/Library/Python/3.9/site-packages/jira/resilientsession.py", line 69, in raise_on_error
    raise JIRAError(
jira.exceptions.JIRAError: JiraError HTTP 400 url: https://jira.xxxx.com/rest/api/2/serverInfo
	text: <html>
<head>
<title>400 Required SSL Certificate Not Sent</title>

My code:

  passaa = "xxxxxx=="
   uPass = base64.b64decode(passaa).decode('UTF-8')

   jira_options = {
       'server': 'https://jira.xxxxxx.com/',
       'verify': './akamai.cer',
       'basic_auth':('myname', uPass)
   }

   jira = JIRA(jira_options)

Is there an existing issue for this?

  • I have searched the existing issues

Jira Instance type

Jira Server or Data Center (Self-hosted)

Jira instance version

Atlassian Jira Project Management Software (v8.8.1#808001-sha1:e5cdcf9)

jira-python version

3.4.1

Python Interpreter version

3.8

Which operating systems have you used?

  • Linux
  • macOS
  • Windows

Reproduction steps

My code:

 
   passaa = "xxxxxx=="
    uPass = base64.b64decode(passaa).decode('UTF-8')

    jira_options = {
        'server': 'https://jira.xxxxxx.com/',
        'verify': './akamai.cer',
        'basic_auth':('myname', uPass)
    }

    jira = JIRA(jira_options)


### Stack trace

```python
Traceback (most recent call last):
  File "/Users/xxxx/PycharmProjects/pythonProject/fortify.py", line 378, in <module>
    postToJira('aaaa')
  File "/Users/xxxxx/PycharmProjects/pythonProject/fortify.py", line 371, in postToJira
    jira = JIRA(jira_options)
  File "/Library/Python/3.9/site-packages/jira/client.py", line 574, in __init__
    si = self.server_info()
  File "/Library/Python/3.9/site-packages/jira/client.py", line 3059, in server_info
    j = self._get_json("serverInfo")
  File "/Library/Python/3.9/site-packages/jira/client.py", line 3764, in _get_json
    r = self._session.get(url, params=params)
  File "/Library/Python/3.9/site-packages/requests/sessions.py", line 600, in get
    return self.request("GET", url, **kwargs)
  File "/Library/Python/3.9/site-packages/jira/resilientsession.py", line 223, in request
    elif raise_on_error(response, **processed_kwargs):
  File "/Library/Python/3.9/site-packages/jira/resilientsession.py", line 69, in raise_on_error
    raise JIRAError(
jira.exceptions.JIRAError: JiraError HTTP 400 url: https://jira.xxxx.com/rest/api/2/serverInfo
	text: <html>
<head>
<title>400 Required SSL Certificate Not Sent</title>
</head>
<body bgcolor="white">
<center>

Expected behaviour

Traceback (most recent call last):
File "/Users/xxxx/PycharmProjects/pythonProject/fortify.py", line 378, in
postToJira('aaaa')
File "/Users/xxxxx/PycharmProjects/pythonProject/fortify.py", line 371, in postToJira
jira = JIRA(jira_options)
File "/Library/Python/3.9/site-packages/jira/client.py", line 574, in init
si = self.server_info()
File "/Library/Python/3.9/site-packages/jira/client.py", line 3059, in server_info
j = self._get_json("serverInfo")
File "/Library/Python/3.9/site-packages/jira/client.py", line 3764, in _get_json
r = self._session.get(url, params=params)
File "/Library/Python/3.9/site-packages/requests/sessions.py", line 600, in get
return self.request("GET", url, **kwargs)
File "/Library/Python/3.9/site-packages/jira/resilientsession.py", line 223, in request
elif raise_on_error(response, **processed_kwargs):
File "/Library/Python/3.9/site-packages/jira/resilientsession.py", line 69, in raise_on_error
raise JIRAError(
jira.exceptions.JIRAError: JiraError HTTP 400 url: https://jira.xxxx.com/rest/api/2/serverInfo
text:

<title>400 Required SSL Certificate Not Sent</title>

Additional Context

No response

jongracecox pushed a commit to jongracecox/jira that referenced this issue Mar 27, 2023
This commit fixes an issue where the `verify` option is not passed along
with requests issued by the ResilientSession class. This commit adds the
`verify` option into the request args inside the `_jira_prepare`
function.

The commit includes a unit test that verifies that `session.verify` is
correclty handed over to requests during subsequent Jira API calls.
jongracecox pushed a commit to jongracecox/jira that referenced this issue Mar 28, 2023
This commit fixes an issue where the `verify` option is not passed along
with requests issued by the ResilientSession class. This commit adds the
`verify` option into the request args inside the `_jira_prepare`
function.

The commit includes a unit test that verifies that `session.verify` is
correclty handed over to requests during subsequent Jira API calls.
@adehad adehad linked a pull request May 17, 2023 that will close this issue
adehad pushed a commit that referenced this issue May 17, 2023
Co-authored-by: Jon Grace-Cox <Jon.Grace-Cox@dunnhumby.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant