Ryotaro-Sanpe666 / google-cloud-sdk

Automatically exported from code.google.com/p/google-cloud-sdk
0 stars 0 forks source link

Authentication failure using [gcloud auth login] #234

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Issue running command [gcloud auth login].

What steps will reproduce the problem?

What is the expected output? What do you see instead?

Please provide any additional information below.

Traceback (most recent call last):
  File "googlecloudsdk/calliope/cli.py", line 580, in Execute
    result = args.cmd_func(cli=self, args=args)
  File "googlecloudsdk/calliope/backend.py", line 1129, in Run
    result = command_instance.Run(args)
  File "googlecloudsdk/calliope/exceptions.py", line 86, in TryFunc
    return func(*args, **kwargs)
  File "googlecloudsdk/gcloud/sdktools/auth/login.py", line 95, in Run
    creds = self.DoWebFlow(args.launch_browser)
  File "googlecloudsdk/gcloud/sdktools/auth/login.py", line 153, in DoWebFlow
    return c_store.AcquireFromWebFlow(launch_browser=launch_browser)
  File "googlecloudsdk/core/credentials/store.py", line 384, in AcquireFromWebFlow
    http=_Http())
  File "googlecloudsdk/core/credentials/flow.py", line 156, in Run
    credential = flow.step2_exchange(code, http=http)
  File "oauth2client/util.py", line 137, in positional_wrapper
    return wrapped(*args, **kwargs)
  File "oauth2client/client.py", line 1993, in step2_exchange
    headers=headers)
  File "httplib2/__init__.py", line 1608, in request
    (response, content) = self._request(conn, authority, uri, request_uri, method, body, headers, redirections, cachekey)
  File "httplib2/__init__.py", line 1350, in _request
    (response, content) = self._conn_request(conn, request_uri, method, body, headers)
  File "httplib2/__init__.py", line 1272, in _conn_request
    conn.connect()
[output truncated]

Original issue reported on code.google.com by bbaing...@gmail.com on 31 Aug 2015 at 4:58

GoogleCodeExporter commented 8 years ago
More info:

WARNING: The output of gcloud info is too long to pre-populate the new issue 
form.
WARNING: Truncating included information. Please consider including the 
remainder:
============== TRUNCATED INFORMATION (PLEASE CONSIDER INCLUDING) ===============
File "httplib2/__init__.py", line 1059, in connect
    raise SSLHandshakeError(e)
SSLHandshakeError: [Errno 1] _ssl.c:504: error:14090086:SSL 
routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed

Installation information:

Google Cloud SDK [0.9.75]

Platform: [Mac OS X, x86_64]
Python Version: [2.7.3 |EPD_free 7.3-1 (32-bit)| (default, Apr 12 2012, 
11:28:34)  [GCC 4.0.1 (Apple Inc. build 5493)]]
Site Packages: [Disabled]

Installation Root: [/private/var/root/google-cloud-sdk]
Installed Components:
  core: [2015.08.23]
  app-engine-python: [1.9.25]
  core-nix: [2015.06.02]
  app: [2015.08.23]
  gcloud: [2015.08.23]
  gsutil-nix: [4.12]
  gsutil: [4.13]
  bq: [2.0.18]
  preview: [2015.08.23]
  bq-nix: [2.0.18]
System PATH: 
[/var/root/google-cloud-sdk/bin:/opt/local/bin:/opt/local/sbin:/opt/local/bin:/o
pt/local/sbin:/Library/Frameworks/Python.framework/Versions/Current/bin:/usr/loc
al/mysql/bin:/Library/Frameworks/Python.framework/Versions/Current/bin:/usr/loca
l/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Library/TeX/texbin]
Cloud SDK on PATH: [True]

Installation Properties: [/private/var/root/google-cloud-sdk/properties]
User Config Directory: [/var/root/.config/gcloud]
User Properties: [/var/root/.config/gcloud/properties]
Current Workspace: [None]
Workspace Config Directory: [None]
Workspace Properties: [None]

Account: [bbaingana@gmail.com]
Project: [helloworld]

Current Properties:
  [core]
    project: [helloworld]
    account: [bbaingana@gmail.com]
    disable_usage_reporting: [False]

Logs Directory: [/var/root/.config/gcloud/logs]
Last Log File: [/var/root/.config/gcloud/logs/2015.08.31/11.54.17.239437.log]
================================================================================
Opening your browser to a new Google Cloud SDK issue.

Original comment by bbaing...@gmail.com on 31 Aug 2015 at 5:03

GoogleCodeExporter commented 8 years ago
Thanks for reporting this. Is there anything unusual about your network 
settings? Firewalls, proxies, etc.?

Original comment by z...@google.com on 31 Aug 2015 at 10:17

GoogleCodeExporter commented 8 years ago
Nothing unusual that I have been able to identify.

Original comment by bbaing...@gmail.com on 1 Sep 2015 at 5:22

GoogleCodeExporter commented 8 years ago
Do you mind trying the following?

1. `ping accounts.google.com`
2. Connect to `https://accounts.google.com` in your browser.
3. `curl https://accounts.google.com`
4. `PYTHONPATH=/var/root/google-cloud-sdk/lib:$PYTHONPATH python -c "import 
httplib2; r=httplib2.Http().request('https://accounts.google.com')"`

Do you have problems with any of these (i.e. any messages related to problems 
with certificates)? Your Python version is relatively old (I think a bunch of 
SSL-related code has changed since 2.7.3). Have you tried with a more recent 
Python? (You can set the CLOUDSDK_PYTHON environment variable to point to 
another Python binary).

Is this problem consistent? Have you tried again recently?

In the mean time, you may be able to work-around by using the 
--no-launch-browser flag. You could also grab service account credentials from 
<https://cloud.google.com/console> (this will definitely work, but is more of a 
pain).

Original comment by z...@google.com on 1 Sep 2015 at 6:37

GoogleCodeExporter commented 8 years ago
I installed a newer version of Python, and I am now able to get authenticated 
successfully. Thank you.

Original comment by bbaing...@gmail.com on 2 Sep 2015 at 7:42

GoogleCodeExporter commented 8 years ago
Glad you were able to work it out, and thanks for updating us.

Original comment by z...@google.com on 2 Sep 2015 at 8:26