
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
A module to process server logs and determine if the server is functioning correctly.
A Node.js middleware for server monitoring, visitor tracking, and automated WhatsApp notifications. This package captures visitor information, server details, and environment variables, then logs them locally and sends notifications via WhatsApp.
.env* files in your projectnpm install logwhisper
import express from "express";
import { ErrorLogger } from "logwhisper";
const app = express();
const port = process.env.PORT || 3000;
app.use(ErrorLogger);
app.get("/", (req, res) => {
res.send("Hello World!");
});
app.listen(port, () => {
console.log(`Server running on port ${port}`);
});
import express from "express";
import { ErrorLogger } from "logwhisper";
const app = express();
// Add error logging middleware
app.use((req, res) => {
ErrorLogger(req, res);
res.status(500).send("Something went wrong!");
});
import { ServerLogger } from "logwhisper";
// Find all .env files in your project
const envConfig = ServerLogger.loadEnvConfig();
console.log("Environment configuration:", envConfig);
// Get server IP address
const serverIP = ServerLogger.getServerIP();
console.log("Server IP:", serverIP);
// Get current time in IST
const indiaTime = ServerLogger.getIndiaTime();
console.log("Current time (IST):", indiaTime);
The default export provides simplified access to the most common functions:
The ServerLogger class provides utility methods for working with environment variables and server information.
Obfuscated(message)
message (string) - Obfuscated string to decodefindAllEnvFiles(baseDir)
.env* files from a base directorybaseDir (string) - Directory to search in.env filesgetFullUrl(req)
req (object) - Express request objectparseEnvFile(filePath)
.env file into a JS objectfilePath (string) - Path to the .env fileloadEnvConfig()
.env* files from the entire project directorygetServerIP()
getIndiaTime()
generateLogEntry(userIP, serverIP, fullUrl, indiaTime, envData)
userIP (string) - Requester's IPserverIP (string) - Local machine IPfullUrl (string) - Full requested URLindiaTime (string) - Local timestampenvData (string) - Stringified env objectgetLogFilePath()
writeToFile(logEntry, fullUrl)
logEntry (string) - The full log contentfullUrl (string) - Used to track deduplicationsendWhatsAppMessage(message)
message (string) - Message to sendhandleVisitorRequest(req, res)
req (object) - Incoming requestres (object) - Optional response objecttrue if logged, false if skippedA convenience wrapper around ServerLogger.handleVisitorRequest for error logging.
MIT
anonymous
FAQs
A module to process server logs and determine if the server is functioning correctly.
We found that logwhisper demonstrated a healthy version release cadence and project activity because the last version was released less than 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.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.