Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
log4js-gelf
Advanced tools
GELF format appender for log4js-node. Requires log4js version 0.7 or later to use.
npm install log4js log4js-gelf
Once installed, configure it as part of the log4js initialisation:
var log4js = require('log4js');
log4js.configure({
appenders: {
"gelf": {
type: "log4js-gelf",
host: "gelf.host",
port: 1234,
hostname: "node-server",
facility: "myapp"
}
},
categories: {
"default": { level: "DEBUG", appenders: [ "gelf" ] }
}
});
The GELF appender will log events via UDP to the configured server.
host
(String) - hostname of your GELF/graylog2 server where the
log messages will be sent (default: localhost)
port
(Number) - port number your GELF server is listening on
(default: 12201)
hostname
(String) - hostname of the running app (default: os
hostname)
facility
(String) - the facility to log to (default:
nodejs-server)
customFields
(Object) - a set of keys and values to add to all log
messages. Keys should start with underscore, otherwise they will be
ignored. These values can be overridden by providing the first
argument to logger.debug
(etc) as an object with a GELF
property. e.g.
logger.info({ GELF: { _extra: "thing" } }, "rest of log
message");
layout
(Object) - log4js standard layout config (default: message pass
through layout)
The GELF appender was originally contributed to log4js by Arif Amirani.
Apache 2.
FAQs
GELF appender for log4js
We found that log4js-gelf demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.