How to use the tls.createServer function in tls

To help you get started, we’ve selected a few tls examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github graalvm / graaljs / graal-nodejs / benchmark / tls / tls-connect.js View on Github external
function main(conf) {
  dur = conf.dur;
  concurrency = conf.concurrency;
  const options = {
    key: fixtures.readKey('rsa_private.pem'),
    cert: fixtures.readKey('rsa_cert.crt'),
    ca: fixtures.readKey('rsa_ca.crt'),
    ciphers: 'AES256-GCM-SHA384'
  };

  const server = tls.createServer(options, onConnection);
  server.listen(common.PORT, onListening);
}
github MTASZTAKI / ApertusVR / 3rdParty / nodejs / 8.0.0 / source / benchmark / tls / tls-connect.js View on Github external
function main(conf) {
  dur = +conf.dur;
  concurrency = +conf.concurrency;

  var cert_dir = path.resolve(__dirname, '../../test/fixtures');
  var options = {
    key: fs.readFileSync(`${cert_dir}/test_key.pem`),
    cert: fs.readFileSync(`${cert_dir}/test_cert.pem`),
    ca: [ fs.readFileSync(`${cert_dir}/test_ca.pem`) ],
    ciphers: 'AES256-GCM-SHA384'
  };

  server = tls.createServer(options, onConnection);
  server.listen(common.PORT, onListening);
}
github pmq20 / node-packer / vendor / node / benchmark / tls / tls-connect.js View on Github external
function main(conf) {
  dur = +conf.dur;
  concurrency = +conf.concurrency;

  var cert_dir = path.resolve(__dirname, '../../test/fixtures');
  var options = {
    key: fs.readFileSync(cert_dir + '/test_key.pem'),
    cert: fs.readFileSync(cert_dir + '/test_cert.pem'),
    ca: [ fs.readFileSync(cert_dir + '/test_ca.pem') ],
    ciphers: 'AES256-GCM-SHA384'
  };

  server = tls.createServer(options, onConnection);
  server.listen(common.PORT, onListening);
}
github pmq20 / node-packer / node8 / benchmark / tls / tls-connect.js View on Github external
function main(conf) {
  dur = +conf.dur;
  concurrency = +conf.concurrency;

  var cert_dir = path.resolve(__dirname, '../../test/fixtures');
  var options = {
    key: fs.readFileSync(`${cert_dir}/test_key.pem`),
    cert: fs.readFileSync(`${cert_dir}/test_cert.pem`),
    ca: [ fs.readFileSync(`${cert_dir}/test_ca.pem`) ],
    ciphers: 'AES256-GCM-SHA384'
  };

  server = tls.createServer(options, onConnection);
  server.listen(common.PORT, onListening);
}
github pmq20 / node-packer / vendor / node-v6.8.0 / benchmark / tls / tls-connect.js View on Github external
function main(conf) {
  dur = +conf.dur;
  concurrency = +conf.concurrency;

  var cert_dir = path.resolve(__dirname, '../../test/fixtures'),
    options = { key: fs.readFileSync(cert_dir + '/test_key.pem'),
                cert: fs.readFileSync(cert_dir + '/test_cert.pem'),
                ca: [ fs.readFileSync(cert_dir + '/test_ca.pem') ],
                ciphers: 'AES256-GCM-SHA384' };

  server = tls.createServer(options, onConnection);
  server.listen(common.PORT, onListening);
}

tls

[![Build Status](https://secure.travis-ci.org/rolandpoulter/js-utils.png)](http://travis-ci.org/rolandpoulter/js-utils)

Unknown
Latest version published 11 years ago

Package Health Score

41 / 100
Full package analysis