
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
@anh4n/server
Advanced tools
The server package provides an already configured Node Express server.
npm install @anh4n/server
// index-controller.js
import { Controller } from '@anh4n/server';
export class IndexController {
public init(server) {
server.get('/', this.indexAction);
}
public indexAction(req, res) {
res.send('Hello World');
}
}
// index-controller.js
import { Controller } from '@anh4n/server';
import { exampleInteractor } from '@usecases/example';
export class IndexController {
public init(server) {
server.get('/', this.indexAction);
}
public async indexAction(req, res, next) {
try {
await exampleInteractor();
res.send('Hello World');
} catch (e) {
return next(e);
}
}
}
// index.js
import { Server, initApp } from '@anh4n/server';
import { IndexController } from './index-controller';
initApp(() => {
const app = new Server();
app.addController(new IndexController()); // Register Controller
app.start(); // Start Server
});
This wrapper catches all errors and outputs them formatted.
This method can be used to register a controller on the server.
A middleware can be registered with this method.
See: http://expressjs.com/de/api.html#app.use
If no parameter is given, this method starts the server on port 3000.
Get the Express app.
Get the HTTP server.
FAQs
@anh4n/server
We found that @anh4n/server 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
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.