node.js - Which PassportJS authentication strategy for both login and without login APIs? -


i building android application client , hapijs framework/mongodb back-end.
in application reading data must accessible without login , when user want write app has login , authorized.
security concern if don't use authentication apis without login may causes ddos attack or hacker force server processes.
think solution accept requests application not sure possible or not.
, don't know 1 of passportjs strategies me.

you can user passport-local npm module authentication in node non-authenticated service can use "api_key" , can generate unique "api_token" authorize requests application only.


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -