Preventing Google User Signup with Supabase RLS in WeWeb

Add a "Log in with Google" button. This button is configured in Supabase, and you need to create a Row Level Security (RLS) rule in the auth.users table to prevent the creation of users who log in with Google.

The button is integrated into WeWeb.

Currently, I am attempting to implement the following policy:

CREATE POLICY Block_Google_Signup
ON auth.users
FOR INSERT
WITH CHECK (
  ((auth.jwt() ->> 'provider') != 'google')
);


However, when the "Log in with Google" button is clicked, a new user is still being created in the auth.users table, which I want to prevent.
The issue might be with the policy or with the configuration in WeWeb.


Let me know if you'd like further edits or enhancements!
Was this page helpful?