
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).
Struid - "Stringy UUID" By Dale Magee BSD 3-clause License
The Struid is an extension of python's UUID class which is intended to be more "pythonic" than the builtin UUID.
In particular, the struid makes it easy to compare with a string or integer value, e.g:
> a = Struid('deadbeef-d00f-d00f-d00f-c0ffeedecade')
> a == 'deadbeef-d00f-d00f-d00f-c0ffeedecade'
True
> a == 295990755078525382164994183696159263454
True
Struid also has convenience helpers to make it backwards-compatible with the regular uuid library:
>from struid import UUID, uuid4
>uuid4().shortstr()
'💤🎝🐆🕏🍛🐃🐉🎧💿🎻🏐💊💡'
>UUID('💤🎝🐆🕏🍛🐃🐉🎧💿🎻🏐💊💡')
UUID('fe2fdb50-9280-461e-aa46-1b3e06718995')
Struids also have a new shortstr() method, which allows you to compactify your string representations of UUID values down using extended unicode characters (emojis, or any characters you choose)
e.g:
> a = Struid('deadbeef-d00f-d00f-d00f-c0ffeedecade')
> a.shortstr()
'🌨🚩💵👤🚡ᚮ🕓💣🐙😝🕴🕤ᛦ'
And you can also instantiate a struid from a shortstr, or compare with one:
> Struid('🌨🚩💵👤🚡ᚮ🕓💣🐙😝🕴🕤ᛦ')
Struid('deadbeef-d00f-d00f-d00f-c0ffeedecade')
You can change the available characters shortstr() can use by calling struid.set_digits(), e.g:
> import struid
> struid.set_digits("0123456789AbCdEf")
> a=Struid('deadbeef-d00f-d00f-d00f-c0ffeedecade')
> a.shortstr()
'dEAdbEEfd00fd00fd00fC0ffEEdECAdE'
(note that changing the available characters affects the shortstr for all guids, so if you e.g save shortstrings to a file and then change character sets, the shortstrings in the file will no longer match)
Struids are built to be case-insensitive, i.e you must not include both upper and lowercase of the same character in the SHORTSTR_DIGITS, doing so will cause breakage.
FAQs
Struid - 'Stringy-UUID', an enhanced UUID package
We found that struid 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
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.