
Research
Security News
Lazarus Strikes npm Again with New Wave of Malicious Packages
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
@skbkontur/node-core
Advanced tools
В библиотеке есть всё что вам надо: * Логирование * Метрики и системный мониторинг * Обработка ошибок * Инициализация ClusterConfig'а * Трассировка запросов * Готовый провайдер для ClusterClient
В библиотеке есть всё что вам надо:
Библиотека композирует модули и инициализирует компоненты.
Документация:
Внутри данного модуля реализован набор middleware для веб фреймворка koa2
.
Если вы используете другой фремворк, вам необходимо реализовать middleware для него.
Пример использования с koa2
:
const core = require('@skbkontur/node-core')
const auth = require('./src/middlewares/authentication')
const router = require('./src/middlewares/router')
const config = require('./src/config')
const Koa = require('koa')
const app = new Koa()
const coreApp = core.runApp(process, config)
coreApp.then(async function createApp(coreApp) {
const { logger } = coreApp
core.useCore(app, coreApp)
app.use(auth)
app.use(router())
app.listen(config.port, () => {
logger.info(`Application started at http://localhost:${config.port}`)
})
})
Ниже приведен список всех компонентов coreApp
.
Апи для их использования можно найти в соответствующих репозиториях:
https://www.npmjs.com/package/@skbkontur/cluster-config-client https://www.npmjs.com/package/@skbkontur/winston-kontur-logstash https://www.npmjs.com/package/@skbkontur/span-aggregator-client https://www.npmjs.com/package/@skbkontur/monitoring-client
const {
logger,
clusterConfig,
monitor,
monitoringClient,
spanAggregator,
options
} = coreApp
Если вы используете middleware для koa2
из этого репозитория, то вы имеете доступ к компонентам coreApp из контекста koa
.
app.use((ctx) => {
ctx.core.logger.info('hello')
ctx.core.clusterConfig.getSettingsByPrefix('topology/graphite-prod/')
ctx.core.monitoringClient.send('metricName', 5)
})
FAQs
Основные компоненты для разработки на Node.js
The npm package @skbkontur/node-core receives a total of 0 weekly downloads. As such, @skbkontur/node-core popularity was classified as not popular.
We found that @skbkontur/node-core demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 10 open source maintainers 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
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.
Security News
Opengrep continues building momentum with the alpha release of its Playground tool, demonstrating the project's rapid evolution just two months after its initial launch.