Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
npm i mdzjs
import {defineConfig} from "vite"
import {MDZ} from "mdzjs"
export default defineConfig({
plugins : [
MDZ()
]
})
---
title : MDZ
background : tomato
---
import InteractiveBlock from "./InteractiveBlock.js";
**MDZ** (Markdown for ***zikojs***) is a format that allows you to append Zikojs Elements directly within Markdown.
It combines the simplicity of Markdown syntax with the power and flexibility of ***Javascript***
Here’s an example of an interactive block rendered within this MDZ file:
<InteractiveBlock data="Hello from MDZ" color="darkblue"/>
### Features of MDZ:
1- **Simple Integration :** Write Markdown as usual, and inject ZikoJS elements wherever needed.
2- **Frontmatter Support :** In this example, the title of the document is set dynamically through the frontmatter.
3- **Extensible :** Create custom components like InteractiveBlock and use them in any Markdown file.
// InteractiveBlock.js
import {Flex, input, text} from "ziko"
export default ({data, color})=>{
let txt = text(data).style({color})
let inp = input(data).style({
padding : "5px",
background : "transparent",
outline :"none",
boxShadow :"1px 1px 1px white",
fontSize : "inherit"
})
inp.onInput(e=>txt.setValue(e.value))
return Flex(
inp,
txt
).vertical(0, "space-around").size("60%").style({
border : "2px darkblue solid",
padding : "10px",
minHeight : "100px",
margin : "auto"
})
}
// main.js
import { useTitle } from "ziko"
import UI,{title, background} from "./test.mdz"
title && useTitle(title)
UI().style({
border : "2px darkblue solid",
width : "70%",
margin : "auto",
padding : "10px",
fontFamily : "Cheeronsta",
background : background ?? "orange"
}).vertical(-1, "space-around")
FAQs
```bash npm i mdzjs ```
We found that mdzjs demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 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.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.