Skip to content

Instantly share code, notes, and snippets.

View jorangreef's full-sized avatar

Joran Dirk Greef jorangreef

View GitHub Profile
@jorangreef
jorangreef / cipher-server.js
Last active August 29, 2015 14:15
Test io.js TLS ciphers
var constants = require('constants');
var fs = require('fs');
var https = require('https');
// Modified form of current io.js default ciphers which gets A+ on ssllabs (assuming SHA256 certificate signature).
// Downside is it's not explicit which would be much better.
var ciphersImplicit = [
'ECDHE-RSA-AES128-GCM-SHA256',
'ECDHE-RSA-AES128-SHA256',
'ECDHE-RSA-AES128-SHA',
@jorangreef
jorangreef / pause-keep-alive
Created February 24, 2011 17:58
Server.request.pause() causing problems for subsequent requests on keep-alive connections
var http = require('http');
http.createServer(
function(request, response) {
request.pause();
response.writeHead(200, { 'Content-Type': 'text/plain' });
response.write('now press CMD + R and every other request will hang for 2 minutes before returning');
response.end();
}
).listen(4000);