最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - delete firebase authenticated user from web application - Stack Overflow

programmeradmin5浏览0评论

I want to add the option to remove A user from firebase authenticated Users list - from my web application. The authentication method I used is email and password authentication.

the application is mobile single page application, based on js/html/css files (browser application).

  1. can I use firebase Admin SDK to delete A user?
  2. is there A better way of doing it? what is the best practice?

Thanks Michael.

I want to add the option to remove A user from firebase authenticated Users list - from my web application. The authentication method I used is email and password authentication.

the application is mobile single page application, based on js/html/css files (browser application).

  1. can I use firebase Admin SDK to delete A user?
  2. is there A better way of doing it? what is the best practice?

Thanks Michael.

Share Improve this question asked Jun 23, 2017 at 12:49 Michael GabbayMichael Gabbay 4651 gold badge5 silver badges24 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 4

The Firebase Admin SDK can be used to delete a user.

But it should only be used in trusted environments, since it allows full access to most of the Firebase services in your project. Typical trusted environments are: a server you control, or Cloud Functions for Firebase.

So a mon way to do this is to build a Cloud Function that deletes the user (using the Admin SDK) and then call that function from your web app. You will have to ensure that only trusted users can call the functionality then, typically by checking their UID or email address against a known list of trusted users.

发布评论

评论列表(0)

  1. 暂无评论