@rebasepro/rls-check 0.10.1-canary.0
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.
- package/LICENSE +21 -0
- package/bin/rls-check.js +12 -0
- package/package.json +59 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Rebase
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/bin/rls-check.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* `npx @rebasepro/rls-check <connection-string>`
|
|
4
|
+
*
|
|
5
|
+
* Deliberately thin: no staleness check, no dependency loading, nothing that
|
|
6
|
+
* could add latency or a failure mode to a first-run `npx` on a stranger's
|
|
7
|
+
* machine. All behaviour, including argument parsing and exit codes, is in
|
|
8
|
+
* `src/cli.ts`.
|
|
9
|
+
*/
|
|
10
|
+
const { runCli } = await import("../dist/index.es.js");
|
|
11
|
+
|
|
12
|
+
process.exitCode = await runCli(process.argv.slice(2));
|
package/package.json
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@rebasepro/rls-check",
|
|
3
|
+
"version": "0.10.1-canary.0",
|
|
4
|
+
"description": "Audit Row-Level Security on any PostgreSQL database — finds tables served without RLS, permissive tautologies, unqualified columns in policy subqueries, RLS-bypassing views and unprotected junction tables. Read-only.",
|
|
5
|
+
"main": "./dist/index.es.js",
|
|
6
|
+
"module": "./dist/index.es.js",
|
|
7
|
+
"types": "./dist/index.d.ts",
|
|
8
|
+
"type": "module",
|
|
9
|
+
"source": "src/index.ts",
|
|
10
|
+
"bin": {
|
|
11
|
+
"rls-check": "bin/rls-check.js"
|
|
12
|
+
},
|
|
13
|
+
"publishConfig": {
|
|
14
|
+
"access": "public"
|
|
15
|
+
},
|
|
16
|
+
"//files": "No workspace deps and no `src` — this is the one package that must `npx` cold on a stranger's machine in seconds, so the install is `pg` and nothing else.",
|
|
17
|
+
"files": [
|
|
18
|
+
"dist",
|
|
19
|
+
"bin",
|
|
20
|
+
"README.md"
|
|
21
|
+
],
|
|
22
|
+
"repository": {
|
|
23
|
+
"type": "git",
|
|
24
|
+
"url": "https://github.com/rebasepro/rebase.git",
|
|
25
|
+
"directory": "packages/rls-check"
|
|
26
|
+
},
|
|
27
|
+
"engines": {
|
|
28
|
+
"node": ">=20"
|
|
29
|
+
},
|
|
30
|
+
"keywords": [
|
|
31
|
+
"postgres",
|
|
32
|
+
"postgresql",
|
|
33
|
+
"rls",
|
|
34
|
+
"row-level-security",
|
|
35
|
+
"security",
|
|
36
|
+
"audit",
|
|
37
|
+
"linter",
|
|
38
|
+
"supabase",
|
|
39
|
+
"policy"
|
|
40
|
+
],
|
|
41
|
+
"author": "rebase.pro",
|
|
42
|
+
"license": "MIT",
|
|
43
|
+
"dependencies": {
|
|
44
|
+
"pg": "^8.16.3"
|
|
45
|
+
},
|
|
46
|
+
"devDependencies": {
|
|
47
|
+
"@types/node": "^22.10.2",
|
|
48
|
+
"@types/pg": "^8.11.10",
|
|
49
|
+
"typescript": "^5.7.2",
|
|
50
|
+
"vite": "^7.1.7",
|
|
51
|
+
"vitest": "^3.2.4"
|
|
52
|
+
},
|
|
53
|
+
"scripts": {
|
|
54
|
+
"test": "vitest run",
|
|
55
|
+
"build": "vite build && tsc --emitDeclarationOnly -p tsconfig.prod.json && node ../../scripts/assert-build-output.mjs",
|
|
56
|
+
"clean": "rm -rf dist && find ./src -name '*.js' -type f | xargs rm -f",
|
|
57
|
+
"typecheck": "tsc --noEmit -p tsconfig.json"
|
|
58
|
+
}
|
|
59
|
+
}
|