allow setting of ciphers in credentials

fixes #873
This commit is contained in:
Theo Schlossnagle 2011-04-04 23:27:20 -04:00 committed by Ryan Dahl
parent 2a88dd3bc1
commit d6f5b8a2a6
2 changed files with 4 additions and 0 deletions

View File

@ -68,6 +68,8 @@ exports.createCredentials = function(options) {
if (options.cert) c.context.setCert(options.cert);
if (options.ciphers) c.context.setCiphers(options.ciphers);
if (options.ca) {
if (Array.isArray(options.ca)) {
for (var i = 0, len = options.ca.length; i < len; i++) {

View File

@ -723,6 +723,7 @@ function Server(/* [options], listener */) {
key: self.key,
cert: self.cert,
ca: self.ca,
ciphers: self.ciphers,
secureProtocol: self.secureProtocol,
secureOptions: self.secureOptions,
crl: self.crl
@ -796,6 +797,7 @@ Server.prototype.setOptions = function(options) {
if (options.ca) this.ca = options.ca;
if (options.secureProtocol) this.secureProtocol = options.secureProtocol;
if (options.crl) this.crl = options.crl;
if (options.ciphers) this.ciphers = options.ciphers;
if (options.secureProtocol) this.secureProtocol = options.secureProtocol;
if (options.secureOptions) this.secureOptions = options.secureOptions;
};