Skip to content

Commit

Permalink
fix: limit backtracking exposure CVE-2021-23424
Browse files Browse the repository at this point in the history
  • Loading branch information
Richard Gebhardt committed Aug 31, 2021
1 parent 99ec49e commit 7cb72a3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion index.js
Expand Up @@ -59,7 +59,7 @@ function ansiHTML (text) {
// Cache opened sequence.
var ansiCodes = []
// Replace with markup.
var ret = text.replace(/\033\[(\d+)*m/g, function (match, seq) {
var ret = text.replace(/\033\[(\d+)m/g, function (match, seq) {
var ot = _openTags[seq]
if (ot) {
// If current sequence has been opened, close it.
Expand Down
2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "ansi-html",
"version": "0.0.7",
"version": "0.0.8",
"description": "An elegant lib that converts the chalked (ANSI) text to HTML.",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit 7cb72a3

Please sign in to comment.