Skip to content
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.

Allow HTTP scheme for localhost URLs #423

Merged
merged 1 commit into from
Jul 4, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions recommended_ruleset.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ module.exports = {
"no-eval": true,
"no-exec-script": true,
"no-function-constructor-with-string-args": true,
"no-http-string": [true, "http://www.example.com/?.*", "http://www.examples.com/?.*"],
"no-http-string": [true, "http://www.example.com/?.*", "http://www.examples.com/?.*", "http://localhost:?.*"],
"no-inner-html": true,
"no-octal-literal": true,
"no-reserved-keywords": true,
Expand Down Expand Up @@ -263,4 +263,3 @@ module.exports = {
"valid-typeof": false,
}
};

2 changes: 1 addition & 1 deletion src/noHttpStringRule.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export class Rule extends Lint.Rules.AbstractRule {
severity: 'Critical',
level: 'Mandatory',
group: 'Security',
recommendation: '[true, "http://www.example.com/?.*", "http://www.examples.com/?.*"],',
recommendation: '[true, "http://www.example.com/?.*", "http://www.examples.com/?.*", "http://localhost:?.*"],',
commonWeaknessEnumeration: '319'
};

Expand Down