|  | @ -117,19 +117,13 @@ io.on('connection', function(socket){ | 
			
		
	
		
		
			
				
					|  |  |     } |  |  |     } | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  |     var term; |  |  |     var term; | 
			
		
	
		
		
			
				
					
					|  |  |     if (process.getuid() === 0) { |  |  | 
 | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |         term = pty.spawn('/bin/login', [], { |  |  |     term = pty.spawn('ssh', [sshuser + sshhost, '-p', sshport, '-o', 'PreferredAuthentications=' + sshauth], { | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |             name: 'xterm-256color', |  |  |         name: 'xterm-256color', | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |             cols: 80, |  |  |         cols: 80, | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |             rows: 30 |  |  |         rows: 30 | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |         }); |  |  |     }); | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |     } else { |  |  | 
 | 
			
				
				
			
		
	
		
		
			
				
					|  |  |         term = pty.spawn('ssh', [sshuser + sshhost, '-p', sshport, '-o', 'PreferredAuthentications=' + sshauth], { |  |  |  | 
			
		
	
		
		
			
				
					|  |  |             name: 'xterm-256color', |  |  |  | 
			
		
	
		
		
			
				
					|  |  |             cols: 80, |  |  |  | 
			
		
	
		
		
			
				
					|  |  |             rows: 30 |  |  |  | 
			
		
	
		
		
			
				
					|  |  |         }); |  |  |  | 
			
		
	
		
		
			
				
					|  |  |     } |  |  |  | 
			
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					|  |  |     console.log((new Date()) + " PID=" + term.pid + " STARTED on behalf of user=" + sshuser); |  |  |     console.log((new Date()) + " PID=" + term.pid + " STARTED on behalf of user=" + sshuser); | 
			
		
	
		
		
			
				
					|  |  |     term.on('data', function(data) { |  |  |     term.on('data', function(data) { | 
			
		
	
		
		
			
				
					|  |  |         socket.emit('output', data); |  |  |         socket.emit('output', data); | 
			
		
	
	
		
		
			
				
					|  | 
 |