Vulnerability library
Security checkApril 08, 2025

ts-asn1-der has Incorrect DER Encoding of Numbers Leading to Denial of Service and Incorrect Value Representation

Understand the exposure, see the recommended fix, and check whether your own website has related weaknesses.

Medium severitynpm@apeleghq/asn1-der

Check your website

Find this and other vulnerabilities with a free scan.

Your scan runs on your computer. No account required.

Description

Incorrect number DER encoding can lead to denial on service for absolute values in the range 2**31 – 2**32 - 1. The arithmetic in the numBitLen didn’t take into account that values in this range could result in a negative result upon applying the >> operator, leading to an infinite loop.

Recommendation

Update the @apeleghq/asn1-der package to the latest compatible version. Followings are version details:

  • Affected version(s): < 1.0.4
  • Patched version(s): 1.0.4

References

Could your website be exposed too?

SmartScanner can check your website for ts-asn1-der has Incorrect DER Encoding of Numbers Leading to Denial of Service and Incorrect Value Representation and gives you actionable findings to investigate.

Start a free scan

Related Issues

See something that needs correcting? Let us knowUpdated April 08, 2025