Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
nestjs-fingerprint
Advanced tools
Server-side fingerprinting library for framework NestJs
npm install --save nestjs-fingerprint
or
yarn add nestjs-fingerprint
app.module.ts
import { Module } from '@nestjs/common';
import { NestjsFingerprintModule } from 'nestjs-fingerprint';
import { AppController } from './app.controller';
import { AppService } from './app.service';
@Module({
imports: [
NestjsFingerprintModule.forRoot({
params: ['headers', 'userAgent', 'ipAddress'],
cookieOptions: {
name: 'your_cookie_name', // optional
httpOnly: true, // optional
},
}),
],
controllers: [AppController],
providers: [AppService],
})
export class AppModule {}
app.controller.ts
import { Controller, Get } from '@nestjs/common';
import { Fingerprint, IFingerprint, RealIp } from 'nestjs-fingerprint';
@Controller()
export class AppController {
@Get()
getFingerprint(@Fingerprint() fp: IFingerprint): IFingerprint {
return fp;
}
@Get('my-ip-address')
getMyIpAddress(@RealIp() ipAddress: string): string {
return ipAddress;
}
}
Fingerprint example:
{
"id": "79c0678d8672fafb932a97a1368d7bf3",
"headers": {
"accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7",
"language": "en-US,en;q=0.9"
},
"userAgent": {
"browser": {
"family": "Chrome",
"version": "xxx"
},
"device": {
"family": "Other",
"version": "0"
},
"os": {
"family": "Windows",
"major": "10",
"minor": "0"
}
},
"ipAddress": {
"value": "xxx.xxx.xxx.xxx"
}
}
MIT © l1ttps
FAQs
Server-side fingerprinting library for framework NestJs
The npm package nestjs-fingerprint receives a total of 544 weekly downloads. As such, nestjs-fingerprint popularity was classified as not popular.
We found that nestjs-fingerprint 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’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.