Skip to content

Commit a4e2079

Browse files
committed
Merge remote-tracking branch 'allan-barbato/patch-1'
2 parents 6232cb7 + b857b9a commit a4e2079

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

lib/types/route.d.ts

+9-7
Original file line numberDiff line numberDiff line change
@@ -493,9 +493,10 @@ export type ReferrerPolicy = '' | 'no-referrer' | 'no-referrer-when-downgrade' |
493493
* * * * * 'allow-from'
494494
* * * * source - when rule is 'allow-from' this is used to form the rest of the header, otherwise this field is ignored. If rule is 'allow-from' but source is unset, the rule will be automatically
495495
* changed to 'sameorigin'.
496-
* * xss - boolean that controls the 'X-XSS-PROTECTION' header for Internet Explorer. Defaults to true which sets the header to equal '1; mode=block'.
497-
* Note: this setting can create a security vulnerability in versions of Internet Explorer below 8, as well as unpatched versions of IE8. See here and here for more information. If you actively
498-
* support old versions of IE, it may be wise to explicitly set this flag to false.
496+
* * xss - controls the 'X-XSS-Protection' header, where:
497+
* * * 'disable' - the header will be set to '0'. This is the default value.
498+
* * * 'enable' - the header will be set to '1; mode=block'.
499+
* * * false - the header will be omitted
499500
* * noOpen - boolean controlling the 'X-Download-Options' header for Internet Explorer, preventing downloads from executing in your context. Defaults to true setting the header to 'noopen'.
500501
* * noSniff - boolean controlling the 'X-Content-Type-Options' header. Defaults to true setting the header to its only and default option, 'nosniff'.
501502
* [See docs](https://github.com/hapijs/hapi/blob/master/API.md#-routeoptionssecurity)
@@ -533,11 +534,12 @@ export interface RouteOptionsSecureObject {
533534
source: string;
534535
} | undefined;
535536
/**
536-
* boolean that controls the 'X-XSS-PROTECTION' header for Internet Explorer. Defaults to true which sets the header to equal '1; mode=block'.
537-
* Note: this setting can create a security vulnerability in versions of Internet Explorer below 8, as well as unpatched versions of IE8. See here and here for more information. If you actively
538-
* support old versions of IE, it may be wise to explicitly set this flag to false.
537+
* controls the 'X-XSS-Protection' header, where:
538+
* * 'disable' - the header will be set to '0'. This is the default value.
539+
* * 'enable' - the header will be set to '1; mode=block'.
540+
* * false - the header will be omitted
539541
*/
540-
xss?: boolean | undefined;
542+
xss?: 'disable' | 'enable' | false | undefined;
541543
/**
542544
* boolean controlling the 'X-Download-Options' header for Internet Explorer, preventing downloads from executing in your context. Defaults to true setting the header to 'noopen'.
543545
*/

0 commit comments

Comments
 (0)