
Research
/Security News
Critical Vulnerability in NestJS Devtools: Localhost RCE via Sandbox Escape
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
github.hscsec.cn/mantyr/rjson
Package rjson implements a backwardly compatible version of JSON with the aim of making it easier for humans to read and write.
The data model is exactly that of JSON's and this package implements all the marshalling and unmarshalling operations supported by the standard library's json package.
The three principal differences are:
- Quotes may be omitted for some object key values (see below).
- Commas are automatically inserted when a newline is encountered after a value (but not an object key).
- Commas are optional at the end of an array or object.
The quotes around an object key may be omitted if the key matches the following regular expression:
[a-zA-Z][a-zA-Z0-9\-_]*
This rule will be relaxed in the future to allow unicode characters, probably following the same rules as Go's identifiers, and probably a few more non-alphabetical characters.
$ go get github.com/mantyr/rjson
package main
import (
"fmt"
"github.com/mantyr/rjson"
)
func main() {
data := []byte(`{
middle : {
src: "pictures/product/123.jpg",
place : '#preview-img', // Added support for JavaScript object parsing
title: "title"
}
}`)
var v struct {
Middle struct {
Src string
Place string
Title string
}
}
err := rjson.Unmarshal(data, &v)
fmt.Println(v) // print {{pictures/product/123.jpg #preview-img title}}
fmt.Println(err) // print <nil>
}
Roger Peppe roger.peppe@canonical.com
FAQs
Unknown package
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
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
Product
Customize license detection with Socket’s new license overlays: gain control, reduce noise, and handle edge cases with precision.
Product
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.