G
G
grabbee2016-02-18 18:13:40
symfony
grabbee, 2016-02-18 18:13:40

Symfony2 Rest API - NGINX secure_link - how to create routes correctly?

Now I'm dealing with REST APi through FOSRestBundle and simple routes are generated there, like:


site.ru/photo/{id}

When adding parameters, it swears at a non-existing Route
. Previously, he signed the link so that if it changes, requests do not go further than NGINX, for example:

site.ru/photo/{alias_name}/{expire}/{sequre_hash}

Such a link is not valid after {expire} or when editing {alias_name} - and nginx throws 403 for example.
And how is this implemented with FOSRestBundle or with REST APi in general?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry Vasilenko, 2016-02-18
@grabbee

I used to do something like this:

site.ru/photo/{id}?e={expire}&s={sequre_hash}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question