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.
crdtoapi is a tool that creates an OpenAPI definitions file from kubernetes CustomResourceDefinitions.
Use kubernetes CRD definitions to create OpenAPI schema file.
npm install --location=global crdtoapi
# add npm bin path to your PATH, or use full
# excutable path, e.g. $(npm bin --location=global)/crdtoapi
crdtoapi --help
# create an OpenAPI file
crdtoapi -i ./examples/forklift/
# create an OpenAPI file using flags
crdtoapi -i ./examples/forklift/ -o openapi.yaml \
--title "Forklift API" \
--description "Migration toolkit for virtualization (Forklift) API definitions." \
--license "Apache-2.0" \
--apiVersion "2.4.0" \
--contactEmail "kubev2v-dev@redhat.com"
Use kubernetes CRD definitions to create Typescript resource constants.
crdtomodel --help
# create typescropt constant files in ./tmp dir
mkdir tmp
crdtomodel -i ./examples/forklift/ -o ./tmp
OpensAPI comunity provide many tools, for example
openapi-generator-cli
is a tool for auto code generation using OpenAPI definition files.
# use openapi-generator-cli:
# npm i --location=global @openapitools/openapi-generator-cli
openapi-generator-cli generate \
-g typescript-fetch \
--skip-validate-spec \
-o generated \
-i openapi.yaml
Run this scripts to lint and publish the package.
npm install
npm run lint:fix
npm run build
npm publish
FAQs
CustomResourceDefinitions to OpensAPI
The npm package crdtoapi receives a total of 324 weekly downloads. As such, crdtoapi popularity was classified as not popular.
We found that crdtoapi demonstrated a healthy version release cadence and project activity because the last version was released less than 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.