Skip to content

Commit c35c3d0

Browse files
committed
Disable features by default
1 parent 1ab5530 commit c35c3d0

File tree

3 files changed

+5
-9
lines changed

3 files changed

+5
-9
lines changed

src/index.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -106,11 +106,7 @@ export default {
106106
if ((!env.AUTH_JWT_SECRET && !env.AUTH_JWKS_ENDPOINT) || authorizationWithoutBearer === undefined) {
107107
return createResponse(undefined, 'Unauthorized request', 400)
108108
}
109-
110-
// Decode to receive the JWT values but this does not verify the signer was authentic,
111-
// that should come in the next step to only allow valid signed JWTs.
112-
// const { payload } = await jwt.decode(authorizationWithoutBearer) as any
113-
109+
114110
if (env.AUTH_JWKS_ENDPOINT && env?.AUTH_ALGORITHM) {
115111
try {
116112
const JWKS = createRemoteJWKSet(new URL(env.AUTH_JWKS_ENDPOINT));

worker-configuration.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ interface Env {
66
REGION: "auto";
77
STUDIO_USER: "admin";
88
STUDIO_PASS: "123456";
9-
ENABLE_ALLOWLIST: 1;
10-
ENABLE_RLS: 1;
9+
ENABLE_ALLOWLIST: 0;
10+
ENABLE_RLS: 0;
1111
EXTERNAL_DB_TYPE: "postgres";
1212
AUTH_ALGORITHM: "RS256";
1313
AUTH_JWKS_ENDPOINT: "";

wrangler.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ STUDIO_USER = "admin"
4343
STUDIO_PASS = "123456"
4444

4545
# Toggle to enable default features
46-
ENABLE_ALLOWLIST = 1
47-
ENABLE_RLS = 1
46+
ENABLE_ALLOWLIST = 0
47+
ENABLE_RLS = 0
4848

4949
# External database source details
5050
# This enables Starbase to connect to an external data source

0 commit comments

Comments
 (0)