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.
css-face-string
Advanced tools
Generate a css string with font-face declaration from JS data.
Useful for generating font faces programatically. Works in node.js and the browser.
Useful with browserify and insert-css
var cfs = require('css-face-string')
cfs.file({
name: 'Inconsolata',
files: [{ url: './inconsolata.ttf', format: 'truetype' }
,{ url: './inconsolata.woff', format: 'woff' }]
})
//> @font-face {font-family: "Inconsolata";src: url("./inconsolata.ttf") format("truetype"), url("./inconsolata.woff") format("woff");
cfs.url("http://fonts.googleapis.com/css?family=Averia+Sans+Libre:400,300italic,700")
//> @import url(http://fonts.googleapis.com/css?family=Averia+Sans+Libre:400,300italic,700);
// No sugar:
cfs(cfs.types.FILE, {
name: 'Inconsolata',
files: [{ url: './inconsolata.ttf', format: 'truetype' }]
})
cfs(cfs.types.URL,
"http://fonts.googleapis.com/css?family=Averia+Sans+Libre:400,300italic,700")
npm install --save css-face-string
FAQs
Generates a string with font face css
The npm package css-face-string receives a total of 0 weekly downloads. As such, css-face-string popularity was classified as not popular.
We found that css-face-string 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.