
Research
Supply Chain Attack on Axios Pulls Malicious Dependency from npm
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.
@hexlet/chat-server
Advanced tools
npm i @hexlet/chat-server
npx start-server
Usage: start-server [OPTIONS]
Options:
-v, --version output the version number
-a, --address <address> address to listen on (default: "0.0.0.0")
-p, --port <port> port to listen on (default: 5001)
-s, --static <path> path to static assets files (default: "./build")
-h, --help display help for command
POST /api/v1/signup
axios.post('/api/v1/signup', { username: 'newuser', password: '123456' }).then((response) => {
console.log(response.data); // => { token: ..., username: 'newuser' }
});
/api/v1/login
axios.post('/api/v1/login', { username: 'admin', password: 'admin' }).then((response) => {
console.log(response.data); // => { token: ..., username: 'admin' }
});
GET /api/v1/channels
axios.get('/api/v1/channels', {
headers: {
Authorization: `Bearer ${token}`,
},
}).then((response) => {
console.log(response.data); // =>[{ id: '1', name: 'general', removable: false }, ...]
});
POST /api/v1/channels
const newChannel = { name: 'new channel' };
axios.post('/api/v1/channels', newChannel, {
headers: {
Authorization: `Bearer ${token}`,
},
}).then((response) => {
console.log(response.data); // => { id: '3', name: 'new channel', removable: true }
});
PATCH /api/v1/channels/:id
const editedChannel = { name: 'new name channel' };
axios.patch('/api/v1/channels/3', editedChannel, {
headers: {
Authorization: `Bearer ${token}`,
},
}).then((response) => {
console.log(response.data); // => { id: '3', name: 'new name channel', removable: true }
});
DELETE /api/v1/channels/:id
axios.delete('/api/v1/channels/3', {
headers: {
Authorization: `Bearer ${token}`,
},
}).then((response) => {
console.log(response.data); // => { id: '3' }
});
GET /api/v1/messages
axios.get('/api/v1/messages', {
headers: {
Authorization: `Bearer ${token}`,
},
}).then((response) => {
console.log(response.data); // =>[{ id: '1', body: 'text message', channelId: '1', username: 'admin }, ...]
});
POST /api/v1/messages
const newMessage = { body: 'new message', channelId: '1', username: 'admin };
axios.post('/api/v1/messages', newMessage, {
headers: {
Authorization: `Bearer ${token}`,
},
}).then((response) => {
console.log(response.data); // => { id: '1', body: 'new message', channelId: '1', username: 'admin }
});
PATCH /api/v1/messages/:id
const editedMessage = { body: 'new body message' };
axios.patch('/api/v1/messages/1', editedMessage, {
headers: {
Authorization: `Bearer ${token}`,
},
}).then((response) => {
console.log(response.data); // => { id: '1', body: 'new body message', channelId: '1', username: 'admin }
});
DELETE /api/v1/messages/:id
axios.delete('/api/v1/messages/3', {
headers: {
Authorization: `Bearer ${token}`,
},
}).then((response) => {
console.log(response.data); // => { id: '3' }
});
// subscribe new messages
socket.on('newMessage', (payload) => {
console.log(payload); // => { body: "new message", channelId: 7, id: 8, username: "admin" }
});
// subscribe new channel
socket.on('newChannel', (payload) => {
console.log(payload) // { id: 6, name: "new channel", removable: true }
});
// subscribe remove channel
socket.on('removeChannel', (payload) => {
console.log(payload); // { id: 6 };
});
// subscribe rename channel
socket.on('renameChannel', (payload) => {
console.log(payload); // { id: 7, name: "new name channel", removable: true }
});
This repository is created and maintained by the team and the community of Hexlet, an educational project. Read more about Hexlet.
See most active contributors on hexlet-friends.
FAQs
## Install
The npm package @hexlet/chat-server receives a total of 66 weekly downloads. As such, @hexlet/chat-server popularity was classified as not popular.
We found that @hexlet/chat-server demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 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
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.

Security News
TeamPCP is partnering with ransomware group Vect to turn open source supply chain attacks on tools like Trivy and LiteLLM into large-scale ransomware operations.