node.js - How secure is to use req.param secure? -
i building rest api app , wondering if req.param secure user can alter url when getting results simple request.
for example :
app.get('/instruction/:url', function (req, res) { var url = req.params.url; ...stuff here... });
i retrieving data url inserted in api wondering how make sure url introduced secure , not going have injection server.
:url url entered example:
the url parameter used "https.request", example rest api url
http://localhost/instruction/https://restcountries.eu/rest/v1/all
any suggestion ? enough simple parse string ?
Comments
Post a Comment