eslint-plugin-browser-security 1.1.0 โ†’ 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +92 -133
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,18 +1,39 @@
1
- # eslint-plugin-browser-security
1
+ <p align="center">
2
+ <a href="https://eslint.interlace.tools" target="blank"><img src="https://eslint.interlace.tools/eslint-interlace-logo-light.svg" alt="ESLint Interlace Logo" width="120" /></a>
3
+ </p>
2
4
 
3
- <div align="center">
4
- <img src="https://eslint.interlace.tools/images/og-browser.png" alt="ESLint Interlace - eslint-plugin-browser-security" width="100%" />
5
- </div>
5
+ <p align="center">
6
+ Browser-specific security rules to prevent XSS and other client-side attacks.
7
+ </p>
6
8
 
7
- > **๐Ÿ“˜ Full Documentation:** [https://eslint.interlace.tools/](https://eslint.interlace.tools/)
8
- >
9
- > ๐Ÿ” Security-focused ESLint plugin for browser applications. Detects XSS vulnerabilities, postMessage abuse, storage API token exposure, cookie security issues, WebSocket vulnerabilities, and more.
9
+ <p align="center">
10
+ <a href="https://www.npmjs.com/package/eslint-plugin-browser-security" target="_blank"><img src="https://img.shields.io/npm/v/eslint-plugin-browser-security.svg" alt="NPM Version" /></a>
11
+ <a href="https://www.npmjs.com/package/eslint-plugin-browser-security" target="_blank"><img src="https://img.shields.io/npm/dm/eslint-plugin-browser-security.svg" alt="NPM Downloads" /></a>
12
+ <a href="https://opensource.org/licenses/MIT" target="_blank"><img src="https://img.shields.io/badge/License-MIT-yellow.svg" alt="Package License" /></a>
13
+ <a href="https://app.codecov.io/gh/ofri-peretz/eslint/components?components%5B0%5D=browser-security" target="_blank"><img src="https://codecov.io/gh/ofri-peretz/eslint/graph/badge.svg?component=browser-security" alt="Codecov" /></a>
14
+ <a href="https://github.com/ofri-peretz/eslint" target="_blank"><img src="https://img.shields.io/badge/Since-Dec_2025-blue?logo=rocket&logoColor=white" alt="Since Dec 2025" /></a>
15
+ </p>
10
16
 
11
- [![npm version](https://img.shields.io/npm/v/eslint-plugin-browser-security.svg)](https://www.npmjs.com/package/eslint-plugin-browser-security)
12
- [![npm downloads](https://img.shields.io/npm/dm/eslint-plugin-browser-security.svg)](https://www.npmjs.com/package/eslint-plugin-browser-security)
13
- [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
14
- [![codecov](https://codecov.io/gh/ofri-peretz/eslint/graph/badge.svg?component=browser_security)](https://app.codecov.io/gh/ofri-peretz/eslint/components?components%5B0%5D=browser_security)
15
- [![Dec 2025](https://img.shields.io/badge/Dec_2025-blue?logo=rocket&logoColor=white)](https://github.com/ofri-peretz/eslint)
17
+ ## Description
18
+
19
+ This plugin provides a suite of browser-specific security rules designed to prevent Cross-Site Scripting (XSS) and other client-side vulnerabilities. It scans your code for dangerous patterns, such as unsafe DOM manipulation and insecure storage practices, offering real-time feedback to developers. Using this plugin ensures that your frontend applications adhere to modern security standards and protect user data effectively.
20
+
21
+ ## Philosophy
22
+
23
+ **Interlace** fosters **strength through integration**. Instead of stacking isolated rules, we **interlace** security directly into your workflow to create a resilient fabric of code. We believe tools should **guide rather than gatekeep**, providing educational feedback that strengthens the developer with every interaction.
24
+
25
+ ## Getting Started
26
+
27
+ - To check out the [guide](https://eslint.interlace.tools/docs/browser-security), visit [eslint.interlace.tools](https://eslint.interlace.tools). ๐Ÿ“š
28
+ - ่ฆๆŸฅ็œ‹ไธญๆ–‡ [ๆŒ‡ๅ—](https://eslint.interlace.tools/docs/browser-security), ่ฏท่ฎฟ้—ฎ [eslint.interlace.tools](https://eslint.interlace.tools). ๐Ÿ“š
29
+ - [๊ฐ€์ด๋“œ](https://eslint.interlace.tools/docs/browser-security) ๋ฌธ์„œ๋Š” [eslint.interlace.tools](https://eslint.interlace.tools)์—์„œ ํ™•์ธํ•˜์‹ค ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ๐Ÿ“š
30
+ - [ใ‚ฌใ‚คใƒ‰](https://eslint.interlace.tools/docs/browser-security)ใฏ [eslint.interlace.tools](https://eslint.interlace.tools)ใงใ”็ขบ่ชใใ ใ•ใ„ใ€‚ ๐Ÿ“š
31
+ - Para ver la [guรญa](https://eslint.interlace.tools/docs/browser-security), visita [eslint.interlace.tools](https://eslint.interlace.tools). ๐Ÿ“š
32
+ - ู„ู„ุงุทู„ุงุน ุนู„ู‰ [ุงู„ุฏู„ูŠู„](https://eslint.interlace.tools/docs/browser-security)ุŒ ู‚ู… ุจุฒูŠุงุฑุฉ [eslint.interlace.tools](https://eslint.interlace.tools). ๐Ÿ“š
33
+
34
+ ```bash
35
+ npm install eslint-plugin-browser-security --save-dev
36
+ ```
16
37
 
17
38
  ## ๐Ÿ’ก What You Get
18
39
 
@@ -33,108 +54,6 @@ Modern browser applications face unique security challenges across storage APIs,
33
54
  - **Cookie Security**: Identifies insecure cookie handling in JavaScript
34
55
  - **LLM-Optimized**: All rules include AI-friendly remediation guidance
35
56
 
36
- ## ๐Ÿ“ฆ Installation
37
-
38
- ```bash
39
- npm install eslint-plugin-browser-security --save-dev
40
- # or
41
- pnpm add -D eslint-plugin-browser-security
42
- # or
43
- yarn add -D eslint-plugin-browser-security
44
- ```
45
-
46
- ## ๐Ÿš€ Quick Start
47
-
48
- ### Flat Config (ESLint 9+)
49
-
50
- ```javascript
51
- // eslint.config.js
52
- import browserSecurity from 'eslint-plugin-browser-security';
53
-
54
- export default [
55
- {
56
- plugins: {
57
- 'browser-security': browserSecurity,
58
- },
59
- rules: {
60
- 'browser-security/no-eval': 'error',
61
- 'browser-security/no-innerhtml': 'error',
62
- 'browser-security/no-sensitive-localstorage': 'error',
63
- 'browser-security/require-postmessage-origin-check': 'error',
64
- },
65
- },
66
- ];
67
- ```
68
-
69
- ### Using Recommended Config
70
-
71
- ```javascript
72
- // eslint.config.js
73
- import browserSecurity from 'eslint-plugin-browser-security';
74
-
75
- export default [browserSecurity.configs.recommended];
76
- ```
77
-
78
- ## ๐Ÿ” Rules (21 total)
79
-
80
- ๐Ÿ’ผ = Set in `recommended` | ๐Ÿ”ง = Auto-fixable | ๐Ÿ’ก = Has suggestions
81
-
82
- ### XSS Prevention
83
-
84
- | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
85
- | :------------------------------------------- | :----: | :------: | :--: | :---------------------------------------------------- | :-: | :-: | :-: | :-: | :-: |
86
- | [no-eval](./docs/rules/no-eval.md) | CWE-95 | A03:2021 | | Prevent code injection via `eval()`, `new Function()` | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
87
- | [no-innerhtml](./docs/rules/no-innerhtml.md) | CWE-79 | A03:2021 | | Prevent XSS via `innerHTML`, `outerHTML` | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
88
-
89
- ### postMessage Security
90
-
91
- | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
92
- | :----------------------------------------------------------------------------------- | :-----: | :------: | :--: | :------------------------------------------------ | :-: | :-: | :-: | :-: | :-: |
93
- | [require-postmessage-origin-check](./docs/rules/require-postmessage-origin-check.md) | CWE-346 | A01:2021 | | Require origin validation in postMessage handlers | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
94
- | [no-postmessage-wildcard-origin](./docs/rules/no-postmessage-wildcard-origin.md) | CWE-346 | A01:2021 | | Prevent wildcard targetOrigin in postMessage | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
95
- | [no-postmessage-innerhtml](./docs/rules/no-postmessage-innerhtml.md) | CWE-79 | A03:2021 | | Prevent XSS via innerHTML in postMessage handlers | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
96
-
97
- ### Storage Security
98
-
99
- | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
100
- | :------------------------------------------------------------------------- | :-----: | :------: | :--: | :--------------------------------------- | :-: | :-: | :-: | :-: | :-: |
101
- | [no-sensitive-localstorage](./docs/rules/no-sensitive-localstorage.md) | CWE-922 | A02:2021 | | Prevent sensitive data in localStorage | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
102
- | [no-sensitive-sessionstorage](./docs/rules/no-sensitive-sessionstorage.md) | CWE-922 | A02:2021 | | Prevent sensitive data in sessionStorage | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
103
- | [no-sensitive-indexeddb](./docs/rules/no-sensitive-indexeddb.md) | CWE-922 | A02:2021 | | Prevent sensitive data in IndexedDB | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
104
- | [no-jwt-in-storage](./docs/rules/no-jwt-in-storage.md) | CWE-922 | A02:2021 | | Prevent JWT tokens in browser storage | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
105
-
106
- ### Cookie Security
107
-
108
- | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
109
- | :------------------------------------------------------------------------- | :------: | :------: | :--: | :------------------------------------------- | :-: | :-: | :-: | :-: | :-: |
110
- | [no-sensitive-cookie-js](./docs/rules/no-sensitive-cookie-js.md) | CWE-1004 | A02:2021 | | Prevent sensitive data in cookies via JS | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
111
- | [no-cookie-auth-tokens](./docs/rules/no-cookie-auth-tokens.md) | CWE-1004 | A02:2021 | | Prevent auth tokens in JS-accessible cookies | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
112
- | [require-cookie-secure-attrs](./docs/rules/require-cookie-secure-attrs.md) | CWE-614 | A05:2021 | | Require Secure and SameSite attributes | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
113
-
114
- ### WebSocket Security
115
-
116
- | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
117
- | :--------------------------------------------------------------- | :-----: | :------: | :--: | :-------------------------------- | :-: | :-: | :-: | :-: | :-: |
118
- | [require-websocket-wss](./docs/rules/require-websocket-wss.md) | CWE-319 | A02:2021 | | Require secure WebSocket (wss://) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
119
- | [no-websocket-innerhtml](./docs/rules/no-websocket-innerhtml.md) | CWE-79 | A03:2021 | | Prevent XSS in WebSocket handlers | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
120
- | [no-websocket-eval](./docs/rules/no-websocket-eval.md) | CWE-95 | A03:2021 | | Prevent RCE in WebSocket handlers | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
121
-
122
- ### File API & Workers Security
123
-
124
- | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
125
- | :----------------------------------------------------------------------------- | :-----: | :------: | :--: | :---------------------------------- | :-: | :-: | :-: | :-: | :-: |
126
- | [no-filereader-innerhtml](./docs/rules/no-filereader-innerhtml.md) | CWE-79 | A03:2021 | | Prevent XSS with FileReader data | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
127
- | [require-blob-url-revocation](./docs/rules/require-blob-url-revocation.md) | CWE-401 | A04:2021 | | Require revoking Blob URLs | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
128
- | [no-dynamic-service-worker-url](./docs/rules/no-dynamic-service-worker-url.md) | CWE-829 | A08:2021 | | Prevent dynamic service worker URLs | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
129
- | [no-worker-message-innerhtml](./docs/rules/no-worker-message-innerhtml.md) | CWE-79 | A03:2021 | | Prevent XSS in Worker handlers | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
130
-
131
- ### CSP Security
132
-
133
- | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
134
- | :----------------------------------------------------------- | :----: | :------: | :--: | :------------------------------ | :-: | :-: | :-: | :-: | :-: |
135
- | [no-unsafe-inline-csp](./docs/rules/no-unsafe-inline-csp.md) | CWE-79 | A03:2021 | | Disallow 'unsafe-inline' in CSP | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
136
- | [no-unsafe-eval-csp](./docs/rules/no-unsafe-eval-csp.md) | CWE-95 | A03:2021 | | Disallow 'unsafe-eval' in CSP | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
137
-
138
57
  ## ๐Ÿ” Detection Examples
139
58
 
140
59
  ### โŒ Vulnerable Code
@@ -174,14 +93,12 @@ window.addEventListener('message', (event) => {
174
93
  });
175
94
  ```
176
95
 
177
- ## ๐Ÿ—‚๏ธ OWASP Coverage
96
+ ## โš™๏ธ Configuration Presets
178
97
 
179
- | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
180
- | :--------------------------------- | :-: | :-------------------------: | :--: | :---------- | :-: | :-: | :-: | :-: | :-: |
181
- | `no-eval` | | A03: Injection | | | | | | | |
182
- | `no-innerhtml` | | A03: Injection | | | | | | | |
183
- | `no-sensitive-localstorage` | | A02: Cryptographic Failures | | | | | | | |
184
- | `require-postmessage-origin-check` | | A01: Broken Access Control | | | | | | | |
98
+ | Preset | Description |
99
+ | :------------ | :-------------------------------------------------- |
100
+ | `recommended` | Recommended security configuration |
101
+ | `strict` | Strict security configuration - all rules as errors |
185
102
 
186
103
  ## ๐Ÿค– LLM-Optimized Messages
187
104
 
@@ -206,22 +123,64 @@ All rules include structured remediation guidance designed for AI assistants:
206
123
  โ€ข OWASP XSS Prevention: https://owasp.org/...
207
124
  ```
208
125
 
209
- ## ๐Ÿ”— Related Packages
126
+ By providing this structured context (CWE, OWASP, Fix), we enable AI tools to **reason** about the security flaw rather than hallucinating. This allows Copilot/Cursor to suggest the _exact_ correct fix immediately.
127
+
128
+ ## Rules
129
+
130
+ **Legend**
131
+
132
+ | Icon | Description |
133
+ | :--: | :----------------------------------------------------------------- |
134
+ | ๐Ÿ’ผ | **Recommended**: Included in the recommended preset. |
135
+ | โš ๏ธ | **Warns**: Set towarn in recommended preset. |
136
+ | ๐Ÿ”ง | **Auto-fixable**: Automatically fixable by the `--fix` CLI option. |
137
+ | ๐Ÿ’ก | **Suggestions**: Providing code suggestions in IDE. |
138
+ | ๐Ÿšซ | **Deprecated**: This rule is deprecated. |
139
+
140
+ | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
141
+ | :------------------------------------------------------------------------------------------------------------------------------ | :------: | :------: | :--: | :----------------------------------------------------------------------------------- | :-: | :-: | :-: | :-: | :-: |
142
+ | [no-eval](https://eslint.interlace.tools/docs/browser-security/rules/no-eval) | CWE-95 | A03:2025 | 9.8 | [no-eval](./docs/rules/no-eval.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | ๐Ÿšซ |
143
+ | [no-innerhtml](https://eslint.interlace.tools/docs/browser-security/rules/no-innerhtml) | CWE-79 | A03:2025 | 6.1 | [no-innerhtml](./docs/rules/no-innerhtml.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
144
+ | [require-postmessage-origin-check](https://eslint.interlace.tools/docs/browser-security/rules/require-postmessage-origin-check) | CWE-346 | A01:2025 | 8.8 | [require-postmessage-origin-check](./docs/rules/require-postmessage-origin-check.md) | ๐Ÿ’ผ | | | | |
145
+ | [no-postmessage-wildcard-origin](https://eslint.interlace.tools/docs/browser-security/rules/no-postmessage-wildcard-origin) | CWE-346 | A01:2025 | 8.8 | [no-postmessage-wildcard-origin](./docs/rules/no-postmessage-wildcard-origin.md) | ๐Ÿ’ผ | | | | |
146
+ | [no-postmessage-innerhtml](https://eslint.interlace.tools/docs/browser-security/rules/no-postmessage-innerhtml) | CWE-79 | A03:2025 | 6.1 | [no-postmessage-innerhtml](./docs/rules/no-postmessage-innerhtml.md) | ๐Ÿ’ผ | | | | |
147
+ | [no-sensitive-localstorage](https://eslint.interlace.tools/docs/browser-security/rules/no-sensitive-localstorage) | CWE-922 | A02:2025 | 7.5 | [no-sensitive-localstorage](./docs/rules/no-sensitive-localstorage.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
148
+ | [no-sensitive-sessionstorage](https://eslint.interlace.tools/docs/browser-security/rules/no-sensitive-sessionstorage) | CWE-922 | A02:2025 | 7.5 | [no-sensitive-sessionstorage](./docs/rules/no-sensitive-sessionstorage.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
149
+ | [no-sensitive-indexeddb](https://eslint.interlace.tools/docs/browser-security/rules/no-sensitive-indexeddb) | CWE-922 | A02:2025 | 7.5 | [no-sensitive-indexeddb](./docs/rules/no-sensitive-indexeddb.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
150
+ | [no-jwt-in-storage](https://eslint.interlace.tools/docs/browser-security/rules/no-jwt-in-storage) | CWE-922 | A02:2025 | 7.5 | [no-jwt-in-storage](./docs/rules/no-jwt-in-storage.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
151
+ | [no-sensitive-cookie-js](https://eslint.interlace.tools/docs/browser-security/rules/no-sensitive-cookie-js) | CWE-1004 | A02:2025 | 5.3 | [no-sensitive-cookie-js](./docs/rules/no-sensitive-cookie-js.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
152
+ | [no-cookie-auth-tokens](https://eslint.interlace.tools/docs/browser-security/rules/no-cookie-auth-tokens) | CWE-1004 | A02:2025 | 5.3 | [no-cookie-auth-tokens](./docs/rules/no-cookie-auth-tokens.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
153
+ | [require-cookie-secure-attrs](https://eslint.interlace.tools/docs/browser-security/rules/require-cookie-secure-attrs) | CWE-614 | A05:2025 | 5.3 | [require-cookie-secure-attrs](./docs/rules/require-cookie-secure-attrs.md) | ๐Ÿ’ผ | | | | ๐Ÿšซ |
154
+ | [require-websocket-wss](https://eslint.interlace.tools/docs/browser-security/rules/require-websocket-wss) | CWE-319 | A02:2025 | 7.5 | [require-websocket-wss](./docs/rules/require-websocket-wss.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | ๐Ÿšซ |
155
+ | [no-websocket-innerhtml](https://eslint.interlace.tools/docs/browser-security/rules/no-websocket-innerhtml) | CWE-79 | A03:2025 | 6.1 | [no-websocket-innerhtml](./docs/rules/no-websocket-innerhtml.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
156
+ | [no-websocket-eval](https://eslint.interlace.tools/docs/browser-security/rules/no-websocket-eval) | CWE-95 | A03:2025 | 9.8 | [no-websocket-eval](./docs/rules/no-websocket-eval.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
157
+ | [no-filereader-innerhtml](https://eslint.interlace.tools/docs/browser-security/rules/no-filereader-innerhtml) | CWE-79 | A03:2025 | 6.1 | [no-filereader-innerhtml](./docs/rules/no-filereader-innerhtml.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
158
+ | [require-blob-url-revocation](https://eslint.interlace.tools/docs/browser-security/rules/require-blob-url-revocation) | CWE-401 | A04:2025 | 5.3 | [require-blob-url-revocation](./docs/rules/require-blob-url-revocation.md) | ๐Ÿ’ผ | โš ๏ธ | | ๐Ÿ’ก | |
159
+ | [no-dynamic-service-worker-url](https://eslint.interlace.tools/docs/browser-security/rules/no-dynamic-service-worker-url) | CWE-829 | A08:2025 | 7.5 | [no-dynamic-service-worker-url](./docs/rules/no-dynamic-service-worker-url.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
160
+ | [no-worker-message-innerhtml](https://eslint.interlace.tools/docs/browser-security/rules/no-worker-message-innerhtml) | CWE-79 | A03:2025 | 6.1 | [no-worker-message-innerhtml](./docs/rules/no-worker-message-innerhtml.md) | ๐Ÿ’ผ | | | | |
161
+ | [no-unsafe-inline-csp](https://eslint.interlace.tools/docs/browser-security/rules/no-unsafe-inline-csp) | CWE-79 | A03:2025 | 6.1 | [no-unsafe-inline-csp](./docs/rules/no-unsafe-inline-csp.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
162
+ | [no-unsafe-eval-csp](https://eslint.interlace.tools/docs/browser-security/rules/no-unsafe-eval-csp) | CWE-95 | A03:2025 | 9.8 | [no-unsafe-eval-csp](./docs/rules/no-unsafe-eval-csp.md) | ๐Ÿ’ผ | | | ๐Ÿ’ก | |
163
+
164
+ ## ๐Ÿ”— Related ESLint Plugins
210
165
 
211
166
  Part of the **Interlace ESLint Ecosystem** โ€” AI-native security plugins with LLM-optimized error messages:
212
167
 
213
- | Plugin | Downloads | Description | Rule | CWE | OWASP | CVSS | Description | ๐Ÿ’ผ | โš ๏ธ | ๐Ÿ”ง | ๐Ÿ’ก | ๐Ÿšซ |
214
- | :--------------------------------------------------------------------------------------------------- | :-------: | :---------: | :--: | :-- | :---: | :--: | :---------: | :-: | :-: | --- | --- | --- |
215
- | [`eslint-plugin-secure-coding`](https://www.npmjs.com/package/eslint-plugin-secure-coding) | | | | | | | | | |
216
- | [`eslint-plugin-jwt`](https://www.npmjs.com/package/eslint-plugin-jwt) | | | | | | | | | |
217
- | [`eslint-plugin-crypto`](https://www.npmjs.com/package/eslint-plugin-crypto) | | | | | | | | | |
218
- | [`eslint-plugin-pg`](https://www.npmjs.com/package/eslint-plugin-pg) | | | | | | | | | |
219
- | [`eslint-plugin-express-security`](https://www.npmjs.com/package/eslint-plugin-express-security) | | | | | | | | | |
220
- | [`eslint-plugin-nestjs-security`](https://www.npmjs.com/package/eslint-plugin-nestjs-security) | | | | | | | | | |
221
- | [`eslint-plugin-lambda-security`](https://www.npmjs.com/package/eslint-plugin-lambda-security) | | | | | | | | | |
222
- | [`eslint-plugin-vercel-ai-security`](https://www.npmjs.com/package/eslint-plugin-vercel-ai-security) | | | | | | | | | |
223
- | [`eslint-plugin-import-next`](https://www.npmjs.com/package/eslint-plugin-import-next) | | | | | | | | | |
168
+ | Plugin | Downloads | Description |
169
+ | :--------------------------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :----------------------------------------- |
170
+ | [`eslint-plugin-secure-coding`](https://www.npmjs.com/package/eslint-plugin-secure-coding) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-secure-coding.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-secure-coding) | General security rules & OWASP guidelines. |
171
+ | [`eslint-plugin-pg`](https://www.npmjs.com/package/eslint-plugin-pg) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-pg.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-pg) | PostgreSQL security & best practices. |
172
+ | [`eslint-plugin-crypto`](https://www.npmjs.com/package/eslint-plugin-crypto) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-crypto.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-crypto) | NodeJS Cryptography security rules. |
173
+ | [`eslint-plugin-jwt`](https://www.npmjs.com/package/eslint-plugin-jwt) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-jwt.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-jwt) | JWT security & best practices. |
174
+ | [`eslint-plugin-vercel-ai-security`](https://www.npmjs.com/package/eslint-plugin-vercel-ai-security) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-vercel-ai-security.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-vercel-ai-security) | Vercel AI SDK security rules. |
175
+ | [`eslint-plugin-express-security`](https://www.npmjs.com/package/eslint-plugin-express-security) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-express-security.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-express-security) | Express.js security hardening rules. |
176
+ | [`eslint-plugin-lambda-security`](https://www.npmjs.com/package/eslint-plugin-lambda-security) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-lambda-security.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-lambda-security) | AWS Lambda security best practices. |
177
+ | [`eslint-plugin-nestjs-security`](https://www.npmjs.com/package/eslint-plugin-nestjs-security) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-nestjs-security.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-nestjs-security) | NestJS security rules & patterns. |
178
+ | [`eslint-plugin-import-next`](https://www.npmjs.com/package/eslint-plugin-import-next) | [![downloads](https://img.shields.io/npm/dt/eslint-plugin-import-next.svg?style=flat-square)](https://www.npmjs.com/package/eslint-plugin-import-next) | Next-gen import sorting & architecture. |
224
179
 
225
180
  ## ๐Ÿ“„ License
226
181
 
227
182
  MIT ยฉ [Ofri Peretz](https://github.com/ofri-peretz)
183
+
184
+ <p align="center">
185
+ <a href="https://eslint.interlace.tools/docs/browser-security"><img src="https://eslint.interlace.tools/images/og-browser-security.png" alt="ESLint Interlace Plugin" width="300" /></a>
186
+ </p>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-plugin-browser-security",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "description": "Security-focused ESLint plugin for browser applications. Detects XSS vulnerabilities, postMessage abuse, localStorage/sessionStorage/IndexedDB token exposure, cookie security issues, WebSocket security, Blob URL leaks, Service Worker risks, and CSP misconfigurations.",
5
5
  "type": "commonjs",
6
6
  "main": "./src/index.js",