Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Firebase database prevent spam requests on path reads without authentications?

I have many paths in my firebase database enable for read without authentication. How do I prevent spammers? What if someone writes a program and repeatedly sending requests to read all the paths in my db? Is there a way to prevent a limit number of repeated requests from a particular IP?

like image 821
user43286 Avatar asked Dec 05 '17 11:12

user43286


1 Answers

I don't know what is your situation, only that is a website, but if you want to make a ip filter you can make a method.

If you can pass the information from php file, you can delimit the access using a .htaccess for redirect url with parameters to a php file, where can access to firebase with authentication, with a verification first the ip adress, using another table.

This method is an implementation, but can semplify your problem using only one php file. This is an method link, but is only if you want to mask the data.

If you make this, you need to rewrite all you url from firebase to that php, as i said before i don't know the situation.

I hope i have helped you.

like image 108
L. Ros. Avatar answered Nov 08 '22 01:11

L. Ros.