src_js/fqdn.js
function getFqdnForIpAddress(ipAddress, cb) {
  dns.reverse(ipAddress, function(err, fqdns) {
    if (err) {
      cb(err, fqdns);
    } else if (fqdns[0].toLowerCase() === localhostIdentifier) {
      getFqdn(localhostIdentifier, cb);
    } else {
      cb(err, fqdns[0]);
    }
  });
}
function getFqdnForIpAddress(ipAddress, cb) {
  dns.reverse(ipAddress, function(err, fqdns) {
    if (err) {
      cb(err, fqdns);
    } else if (fqdns[0].toLowerCase() === localhostIdentifier) {
      getFqdn(localhostIdentifier, cb);
    } else {
      cb(err, fqdns[0]);
    }
  });
}
function getFqdnForIpAddress ( ipAddress , cb ) { dns . reverse ( ipAddress , function ( err , fqdns ) { if ( err ) { cb ( err , fqdns ) ; } else if ( fqdns [ 0 ] . toLowerCase ( ) === localhostIdentifier ) { getFqdn ( localhostIdentifier , cb ) ; } else { cb ( err , fqdns [ 0 ] ) ; } } ) ; }
Do a reverse lookup on the IP address and return the first FQDN.
Do a reverse lookup on the IP address and return the first FQDN .