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

Connecting the authorities step Error #104

Open
alvaro-marting opened this issue Dec 21, 2016 · 3 comments
Open

Connecting the authorities step Error #104

alvaro-marting opened this issue Dec 21, 2016 · 3 comments

Comments

@alvaro-marting
Copy link

We are following the tutorial on the deployment on the development box literally and when trying to connect the authorities, we get this error, we are working on the Next branch as suggested with the new version of the system as was published a few days ago, we get the following error when running 'eotest':

using the following authorities:

  1. nvotes.com (this is us, acting as orchestra director)
  2. nvotes.com

Creating election 3682
Traceback (most recent call last):
File "/usr/bin/eotest.py", line 490, in
main(sys.argv[1:])
File "/usr/bin/eotest.py", line 485, in main
eval(command + "(args)")
File "", line 1, in
File "/usr/bin/eotest.py", line 452, in full
pkFile = create(args)
File "/usr/bin/eotest.py", line 361, in create
startElection(electionId, startUrl, startData)
File "/usr/bin/eotest.py", line 279, in startElection
r = session.request('post', url, data=json.dumps(data), verify=CALIST, cert=(CERT, KEY))
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/adapters.py", line 487, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='nvotes.com', port=5000): Max retries exceeded with url: /public_api/election (Caused by NewConnectionError('<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7f687e027610>: Failed to establish a new connection: [Errno 110] Connection timed out',))
Connection to 127.0.0.1 closed.

I have revised a similar issue but the problem appears to be different. Probably related to the packages, but that is only a guess.

@Findeton
Copy link
Contributor

Hi @dalmaxor I don't understand the part where you say that both election authorities are nvotes.com, nvotes.com servers don't act as election authorities. If you are following this small tutorial you should have created two VMs, one for each authority. Can you please specify your setup/configuration? are you running agora on VMs?

@alvaro-marting
Copy link
Author

alvaro-marting commented Dec 22, 2016

Thank you for the quick response @Findeton ,
I have Auth1 and Auth2 running on Vagrant as specified in https://github.com/agoravoting/agora-dev-box/blob/next/doc/devel_deployment.md , and everything appeared fine until the Test the connections step, in which the Authorities were unable to connect between them.

I skipped the Base provisioning step, maybe it has to do with the fact that the config.yml isn't copied for the authorities in the following step and therefore I have a config.yml that isn't accurate on both my authorities?

I'll retry again from the base provisioning and edit the message if that was the issue.

-- EDIT --

Now i have done the base provisioning, and yes, the nVotes attempting to connect to another nVotes instance was due to that, now then, the error has changed and it looks like there is some problem with the python version on the machines, python 3.16 was released a little while ago, maybe that update messed up something in the system? The log of the error:

/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/packages/urllib3/util/ssl_.py:334: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warningsSNIMissingWarning /home/eorchestra/venv/local/lib/python2.7/site-packages/requests/packages/urllib3/util/ssl_.py:132: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings InsecurePlatformWarning Traceback (most recent call last): File "/usr/bin/eotest.py", line 490, in <module> main(sys.argv[1:]) File "/usr/bin/eotest.py", line 485, in main eval(command + "(args)") File "<string>", line 1, in <module> File "/usr/bin/eotest.py", line 452, in full pkFile = create(args) File "/usr/bin/eotest.py", line 361, in create startElection(electionId, startUrl, startData) File "/usr/bin/eotest.py", line 279, in startElection r = session.request('post', url, data=json.dumps(data), verify=CALIST, cert=(CERT, KEY)) File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 488, in request resp = self.send(prep, **send_kwargs) File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 609, in send r = adapter.send(request, **kwargs) File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/adapters.py", line 497, in send raise SSLError(e, request=request) requests.exceptions.SSLError: hostname 'auth1' doesn't match either of 'nvotes.com', 'nvotes.com'

Should I downgrade the python version to 3.15 on the 3 machines?

@nfortea
Copy link

nfortea commented Aug 28, 2017

Hi @dalmaxor,
Could you repair your SNIMissingWarning? I have a similar error.
> Creating election 3291 /home/eorchestra/venv/local/lib/python2.7/site-packages/urllib3/util/ssl_.py:335: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject NameIndication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings SNIMissingWarning /home/eorchestra/venv/local/lib/python2.7/site-packages/urllib3/util/ssl_.py:133: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. Formore information, see https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings InsecurePlatformWarning Traceback (most recent call last): File "/usr/bin/eotest.py", line 490, in <module> main(sys.argv[1:]) File "/usr/bin/eotest.py", line 485, in main eval(command + "(args)") File "<string>", line 1, in <module> File "/usr/bin/eotest.py", line 452, in full pkFile = create(args) File "/usr/bin/eotest.py", line 361, in create startElection(electionId, startUrl, startData) File "/usr/bin/eotest.py", line 279, in startElection r = session.request('post', url, data=json.dumps(data), verify=CALIST, cert=(CERT, KEY)) File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 513, in request resp = self.send(prep, **send_kwargs) File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/sessions.py", line 623, in send r = adapter.send(request, **kwargs) File "/home/eorchestra/venv/local/lib/python2.7/site-packages/requests/adapters.py", line 514, in send raise SSLError(e, request=request) requests.exceptions.SSLError: [Errno 1] _ssl.c:510: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed

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

No branches or pull requests

3 participants