Skip to content

Commit c33d161

Browse files
author
Jeremy Judeaux
committed
force cipher AES128-GCM-SHA256 in https tests
1 parent 1dabda2 commit c33d161

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Diff for: test/lib-https-proxy-test.js

+6
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ describe('lib/http-proxy.js', function() {
3535
ssl: {
3636
key: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-key.pem')),
3737
cert: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-cert.pem')),
38+
ciphers: 'AES128-GCM-SHA256',
3839
}
3940
}).listen(ports.proxy);
4041

@@ -65,6 +66,7 @@ describe('lib/http-proxy.js', function() {
6566
var source = https.createServer({
6667
key: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-key.pem')),
6768
cert: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-cert.pem')),
69+
ciphers: 'AES128-GCM-SHA256',
6870
}, function (req, res) {
6971
expect(req.method).to.eql('GET');
7072
expect(req.headers.host.split(':')[1]).to.eql(ports.proxy);
@@ -105,6 +107,7 @@ describe('lib/http-proxy.js', function() {
105107
var source = https.createServer({
106108
key: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-key.pem')),
107109
cert: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-cert.pem')),
110+
ciphers: 'AES128-GCM-SHA256',
108111
}, function(req, res) {
109112
expect(req.method).to.eql('GET');
110113
expect(req.headers.host.split(':')[1]).to.eql(ports.proxy);
@@ -119,6 +122,7 @@ describe('lib/http-proxy.js', function() {
119122
ssl: {
120123
key: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-key.pem')),
121124
cert: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-cert.pem')),
125+
ciphers: 'AES128-GCM-SHA256',
122126
},
123127
secure: false
124128
}).listen(ports.proxy);
@@ -150,6 +154,7 @@ describe('lib/http-proxy.js', function() {
150154
var source = https.createServer({
151155
key: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-key.pem')),
152156
cert: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-cert.pem')),
157+
ciphers: 'AES128-GCM-SHA256',
153158
}).listen(ports.source);
154159

155160
var proxy = httpProxy.createProxyServer({
@@ -191,6 +196,7 @@ describe('lib/http-proxy.js', function() {
191196
var ownServer = https.createServer({
192197
key: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-key.pem')),
193198
cert: fs.readFileSync(path.join(__dirname, 'fixtures', 'agent2-cert.pem')),
199+
ciphers: 'AES128-GCM-SHA256',
194200
}, function (req, res) {
195201
proxy.web(req, res, {
196202
target: 'http://127.0.0.1:' + ports.source

0 commit comments

Comments
 (0)