liftoff / GateOne

Gate One is an HTML5-powered terminal emulator and SSH client
http://liftoffsoftware.com/Products/GateOne
Other
6.28k stars 924 forks source link

Auth = None acting strange #55

Closed koenkooi closed 12 years ago

koenkooi commented 12 years ago

I'm trying to install gateone on an embedded device and I'm running into some trouble with auth = none:

ÄI 000101 06:17:26 auth:92Ü Creating user directory: /tmp//%anonymous ÄI 000101 06:17:26 web:1359Ü 302 GET /auth?next=%2F (172.20.0.96) 19.30ms ÄI 000101 06:17:26 web:1359Ü 302 GET / (172.20.0.96) 4.40ms ÄI 000101 06:17:26 auth:92Ü Creating user directory: /tmp//%anonymous ÄI 000101 06:17:26 web:1359Ü 302 GET /auth?next=%2F (172.20.0.96) 15.93ms ÄI 000101 06:17:26 web:1359Ü 302 GET / (172.20.0.96) 4.48ms ÄI 000101 06:17:26 auth:92Ü Creating user directory: /tmp//%anonymous ÄI 000101 06:17:26 web:1359Ü 302 GET /auth?next=%2F (172.20.0.96) 16.02ms ÄI 000101 06:17:26 web:1359Ü 302 GET / (172.20.0.96) 4.28ms

Auth = google gives redirects me to google and then gives me a 500 with this in the log:

ÄI 000101 06:19:44 web:1359Ü 302 GET / (172.20.0.96) 10.72ms ÄI 000101 06:19:44 web:1359Ü 302 GET /auth?next=%2F (172.20.0.96) 9.24ms ÄW 000101 06:19:45 iostream:599Ü SSL Error on 10: ÄErrno 1Ü _ssl.c:503: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed ÄW 000101 06:19:45 auth:150Ü Invalid OpenID response: HTTP 599: Connection closed

python 2.7.2, latest tornado from git, pyopenssl 0.13

liftoff commented 12 years ago

What's the architecture you're running on? Also, can you post your entire server.conf?

BTW: That SSL error sounds like you're just missing the necessary root certificate to verify Google's SSL. Make sure that you've installed the requisite root certificates (usually in /usr/share/ca-certificates/).

koenkooi commented 12 years ago

It's an AM335x chip from TI, which is armv7a. More specifically it's this board: http://beagleboard.org/bone

Gateone is installed in /var/lib/gateone

Server.conf:

sso_service = "HTTP" locale = "en_US" pam_service = "login" syslog_facility = "daemon" disable_ssl = False session_logging = True session_dir = "/tmp/gateone" cookie_secret = "ODBmYzQ0ZTMwOTg1NDY0NGJiZTczN2FhNmQ0ZjBkMjUwY" syslog_session_logging = False address = "0.0.0.0" port = 443 user_dir = "/var/lib/gateone/users" log_file_num_backups = 10 logging = "info" dtach = True certificate = "certificate.pem" keyfile = "keyfile.pem" sso_realm = None log_to_stderr = False log_file_max_size = 104857600 session_timeout = "5d" command = "/var/lib/gateone/plugins/ssh/scripts/ssh_connect.py -S '/tmp/gateone/%SESSION%/%SHORT_SOCKET%' --sshfp -a '-oUserKnownHostsFile=%USERDIR%/%USER%/known_hosts'" embedded = False debug = False js_init = "" auth = None log_file_prefix = "/var/log/gateone/webserver.log" pam_realm = "beaglebone"

liftoff commented 12 years ago

I just pushed a commit that changes how user directories are created... Please pull the latest code and let me know if that corrected this issue. I wasn't able to reproduce it but I made a few changes to the auth.py that should make it more robust in this regard. Let me know how it goes, thanks!

koenkooi commented 12 years ago

The latest version gave the following error:

[E 111109 09:46:48 web:1359] 500 GET / (172.20.1.19) 37.98ms [E 111109 09:46:50 web:997] Uncaught exception GET / (172.20.1.19) HTTPRequest(protocol='https', host='beaglebone.local', method='GET', uri='/', version='HTTP/1.1', remoteip='172.20.1.19', body='', headers={'Accept-Language': 'nl-nl', 'Accept-Encoding': 'gzip, deflate', 'Host': 'beaglebone.local', 'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,/_;q=0.8', 'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_2) AppleWebKit/535.8+ (KHTML, like Gecko) Version/5.1.1 Safari/534.51.22', 'Connection': 'keep-alive', 'Cookie': 'user=eyJnb19zZXNzaW9uIjogIlpHSXlOMkpsWkdKak9EQmhORFJtT1RrNE1HWXlZemxpTnpCaE16SmtORFZpTSIsICJnb191cG4iOiAiJWFub255bW91cyJ9|1320831737|720a0fb6aaa111799630014bc77831b6774f9dac', 'Cache-Control': 'max-age=0'}) Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/tornado/web.py", line 954, in _execute getattr(self, self.request.method.lower())(_args, _kwargs) File "/usr/lib/python2.7/site-packages/tornado/web.py", line 1667, in wrapper return method(self, _args, _kwargs) File "./gateone.py", line 603, in get bell_data_uri = create_data_uri(bell) File "/var/lib/gateone/utils.py", line 586, in create_data_uri raise MimeTypeFail("Could not guess mime type of: %s" % filepath) MimeTypeFail: Could not guess mime type of: /var/lib/gateone/static/bell.ogg [E 111109 09:46:50 web:1359] 500 GET / (172.20.1.19) 14.18ms

So after installing mime-support it works!