Hacker News new | ask | show | jobs
by rrgok 1285 days ago
I've created also an issue on github[0] but didn't get any reply yet. So, I'll try here.

How to do Custom Authentication? For example, LDAP Auth is not possible in the current version. And I still don't quite understand the API to implement it myself. Can you kindly provide me some pointers on how to do that? I don't need LDAP specifically, but just a dummy custom authentication code?

0. https://github.com/supabase/supabase/issues/9958

2 comments

Sorry about the lack of response on that issue - I'll move this to the the GoTrue repo so the Auth team own it.

I don't want to answer here without the advice of the Auth team because custom authentication code has the potential of being unsafe. I've flagged it with them and they will make sure that you get a response.

I understand. I've been reading the GoTrue API and GoTrue-js client library to find a workaround with MagicLinks. But can't find a safe way either.

I appreciate the answer!

Here's an older repo[0] I put together to show how to do some custom auth stuff. Take a look and see if you can use some ideas from here.

0. https://github.com/burggraf/supabase-roll-your-own-auth

Note this was written before edge functions were released, so it may make more sense to make these calls from edge functions, depending on what you're trying to do.
This is awesome, thank you very much. I've been looking to MagicLinks too, but I didn't know if they were safe the way I wanted to use it. Anyway, I will take inspiration from your repo.

LDAP auth is the only thing stopping me from using Supabase.