No terminal opening at all #21

Open
TotallyInformation opened this Issue Apr 29, 2012 · 3 comments

Comments

Projects
None yet
3 participants

Hi, I've tried installing this on Debian.

sudo npm install -d tty.js

Although it appears to work OK. When I try accessing in a browser (I've tried FF, chrome and Safari), I get the following output on the shell:

Warning: You should sha1 your usernames/passwords.
   info  - socket.io started
Created shell with pty (/dev/pts/35) master/slave pair (master: 13, pid: 17704)
Closed pty (/dev/pts/35): 13.
Created shell with pty (/dev/pts/35) master/slave pair (master: 20, pid: 17753)
Client disconnected. Killing all pty's...

I wasn't getting a terminal but I've fixed this - your example config file is not too helpful as it doesn't actually work!

The problem I have though is that, although I've specified cert files that I know work (as I'm using them with other Node apps), I don't get an https connection.

I've tried running as a user and as root.

Here is the config file I've got when running as root (with the secure bits changed of course):

{
  "users": {
    "user": "password"
  },
  "https": {
    "key": "/etc/ssl/private/somename.key",
    "cert": "/etc/ssl/private/somename.crt"
  },
  "port": 8082,
  "hostname": "totallyinformation.net",
  "shell": "bash",
  "term": {
    "termName": "xterm",
    "geometry": [80, 30],
  }
}

Any ideas?

Owner

chjj commented Apr 29, 2012

The example config file is supposed to be there as a reference for all of the possible options. It's not intended for actual use. I suppose I should get around to turning it into documentation instead of just an example.

  "https": {
    "key": "/etc/ssl/private/somename.key",
    "cert": "/etc/ssl/private/somename.crt"
  },

Make sure you have read permissions to those files and that they exist. If you don't, tty.js will silently fail and fall back to http. Come to think of it, that probably needs changing too.

Yeah, documentation would be nice ;) But at least a comment to say that the example doesn't work as written without additional work.

I DO have read permissions to the files in question - I know that because they work fine with other node apps.

I suppose that I will have to hack some debugging into your code so I can see what is going wrong. It would be nice if you threw at least some kind of warning if the cert read failed. Actually it would be much SAFER if you bombed out since the last thing you want to do is end up with an insecure connection when you meant to have a secure one.

Cheers, J.

risacher commented Dec 7, 2013

Recommend close: this is really old - two years is too long.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment