mirror of
https://github.com/NuSkooler/enigma-bbs.git
synced 2025-07-22 02:35:56 +02:00
* SSH semi functional
This commit is contained in:
parent
3833f9910e
commit
0f1fe31fe5
5 changed files with 53 additions and 46 deletions
|
@ -14,17 +14,17 @@ function getActiveConnections() {
|
|||
return clientConnections.length;
|
||||
}
|
||||
|
||||
function addNewClient(client) {
|
||||
function addNewClient(client, clientSock) {
|
||||
var id = client.session.id = clientConnections.push(client) - 1;
|
||||
|
||||
// Create a client specific logger
|
||||
client.log = logger.log.child( { clientId : id } );
|
||||
|
||||
var connInfo = { ip : client.input.remoteAddress };
|
||||
var connInfo = { ip : clientSock.remoteAddress };
|
||||
|
||||
if(client.log.debug()) {
|
||||
connInfo.port = client.input.localPort;
|
||||
connInfo.family = client.input.localFamily;
|
||||
connInfo.port = clientSock.localPort;
|
||||
connInfo.family = clientSock.localFamily;
|
||||
}
|
||||
|
||||
client.log.info(connInfo, 'Client connected');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue