Skip to content

Commit

Permalink
Verify that HTTP header fields are not empty.
Browse files Browse the repository at this point in the history
  • Loading branch information
kenballus committed Oct 17, 2023
1 parent 9ab2afc commit cf6fcfe
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/llhttp/http.ts
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,7 @@ export class HTTP {
}).otherwise(this.headersCompleted()),
}, onInvalidHeaderFieldChar),
)
.peek(':', p.error(ERROR.INVALID_HEADER_TOKEN, 'Empty header field'))
.otherwise(span.headerField.start(n('header_field')));

n('header_field')
Expand Down

0 comments on commit cf6fcfe

Please sign in to comment.