Skip to content

Commit

Permalink
Allow upload of files with a .json postfix.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelkaye committed Feb 8, 2022
1 parent 589e925 commit 18c8a83
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion submit.go
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ func formPartToPayload(field, data string, p *parsedPayload) {
// * no silly characters (/, ctrl chars, etc)
//
// * nothing starting with '.'
var filenameRegexp = regexp.MustCompile(`^[a-zA-Z0-9_-]+\.(jpg|png|txt)$`)
var filenameRegexp = regexp.MustCompile(`^[a-zA-Z0-9_-]+\.(jpg|png|txt|json)$`)

// saveFormPart saves a file upload to the report directory.
//
Expand Down

0 comments on commit 18c8a83

Please sign in to comment.