2016-03-16 93 views
0

我最近決定快速重新設置谷歌身份工具包使用一個新的應用程序,我認爲這將是在公園散步,直到我成爲滯留在401未經授權的錯誤...401未經授權的錯誤在驗證GitKit令牌

爲了確保這是一個乾淨的設置,我完全按照分步設置說明(https://developers.google.com/identity/toolkit/web/configure-service),包括使用openssl pkcs12 -in xxxxx.p12 -nodes -nocerts將.p12文件轉換爲.pem的步驟> privatekey.pem

作爲一個方面說明,我以前已經完成了幾個月的運行,並且似乎無法識別這次的錯誤..認爲它必須是.pem文件,所以我嘗試使用t他.p12甚至.json rsa文件,但我猜gitkit仍然不能接受這些選項

任何想法?

HTTP Error 401: Unauthorized Traceback (most recent call last): File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1529, in call rv = self.router.dispatch(request, response) File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1278, in default_dispatcher return route.handler_adapter(request, response) File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1101, in call handler = self.handler(request, response) File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 528, in init self.initialize(request, response) File "/base/data/home/apps/s~[site]/1.391420460413032384/main.py", line 56, in initialize gitkit_user = gitkit_instance.VerifyGitkitToken(self.request.cookies['gtoken'])
File "/base/data/home/apps/s~[site]/1.391420460413032384/lib/identitytoolkit/gitkitclient.py", line 216, in VerifyGitkitToken certs = self.rpc_helper.GetPublicCert() File "/base/data/home/apps/s~[site]/1.391420460413032384/lib/identitytoolkit/rpchelper.py", line 157, in GetPublicCert headers = {'Authorization': 'Bearer ' + self._GetAccessToken()} File "/base/data/home/apps/s~[site]/1.391420460413032384/lib/identitytoolkit/rpchelper.py", line 207, in _GetAccessToken raw_response = urllib2.urlopen(req, body) File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/urllib2.py", line 127, in urlopen return _opener.open(url, data, timeout) File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/urllib2.py", line 410, in open response = meth(req, response) File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/urllib2.py", line 523, in http_response 'http', request, response, code, msg, hdrs) File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/urllib2.py", line 448, in error return self._call_chain(*args) File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/urllib2.py", line 382, in _call_chain result = func(*args) File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/urllib2.py", line 531, in http_error_default raise HTTPError(req.get_full_url(), code, msg, hdrs, fp) HTTPError: HTTP Error 401: Unauthorized

+0

假設這是設置服務帳戶或引用服務帳戶時出現問題是否公平? – Dennis

回答

0

好了,想到這一點..貌似需要從2015年12月(使用2015年9月),它不再需要從的.p12轉換爲.pem

更新gitkit客戶端版本
相關問題