Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

qcobjects-cli

Package Overview
Dependencies
Maintainers
1
Versions
198
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

qcobjects-cli - npm Package Compare versions

Comparing version 0.1.26 to 0.1.27

19

org.quickcorp.qcobjects.main.http.gae.server.js

@@ -276,4 +276,21 @@ /**

this.request.path = req.url;
server.setMaxListeners(9999999999);
CONFIG.set('backendTimeout',CONFIG.get('backendTimeout') || 20000);
server.setTimeout(CONFIG.get('backendTimeout'), ()=>{
// end the stream on timeout
try {
logger.info('A timeout occurred...' + CONFIG.get('backendTimeout').toString());
logger.info('Killing session...');
res.respond([{
':status': 408,
'content-type': 'text/html'
}]);
res.write('<h1>408 - REQUEST TIMEOUT</h1>');
res.end();
}catch (e){
logger.debug('An unhandled error occurred during timeout catching...');
logger.debug(e.message);
}
});
if (this.request.pathname.indexOf('.')<0){

@@ -280,0 +297,0 @@ this.request.scriptname = CONFIG.get('documentRootFileIndex');

@@ -201,6 +201,34 @@ /**

session.origin('https://'+CONFIG.get('domain'),'http://'+CONFIG.get('domain'));
});
server.on('stream', (stream, headers, flags) => {
CONFIG.set('backendTimeout',CONFIG.get('backendTimeout') || 20000);
stream.session.setTimeout(CONFIG.get('backendTimeout'));
stream.session.setMaxListeners(9999999999);
stream.session.on('timeout', () => {
// end the stream on timeout
try {
if (!stream.destroyed){
logger.info('A timeout occurred... '+CONFIG.get('backendTimeout').toString());
logger.info('Killing session...');
stream.respond([{
':status': 408,
'content-type': 'text/html'
}]);
stream.write('<h1>408 - REQUEST TIMEOUT</h1>');
stream.end();
} else {
logger.debug('Session was normally finishing...');
}
}catch(e){
logger.info('An unhandled error occurred during timeout catching...');
logger.info(e.message);
}
});
stream.session.altsvc('h2=":8000"', stream.id);

@@ -207,0 +235,0 @@ stream.session.altsvc('https=":'+CONFIG.get('serverPortHTTPS')+'"', stream.id);

2

package.json
{
"name": "qcobjects-cli",
"version": "0.1.26",
"version": "0.1.27",
"description": "qcobjects cli command line tool",

@@ -5,0 +5,0 @@ "main": "qcobjects-cli.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc