djoos / EscapeWSSEAuthenticationBundle

Symfony bundle to implement WSSE authentication
http://symfony.com/doc/current/cookbook/security/custom_authentication_provider.html
137 stars 59 forks source link

Authorize multiple requests with a token #88

Closed xvrcjs closed 7 years ago

xvrcjs commented 7 years ago

Hello,

I am having a problem with the bundle, I have managed to install it but the token I receive serves me for a single request, I need to authorize several requests with a single token.

I appreciate any help you can give me

djoos commented 7 years ago

Hi @xvrcjs,

thanks for reaching out!

Each request has its own token, a nonce token - a nonce may only be used once. When you want to fire off several requests, you'll have to generate a token for each request...

Hope this helps! David

xvrcjs commented 7 years ago

Thanks @djoos for responding so quickly.

There will be some way to resolve so that you do not have to generate a token for each request?

Thanks!

djoos commented 7 years ago

Hi,

each request will need its token, so you'll have to generate one for each request...

I'm not too familiar with batch requests (see something the like of https://developers.facebook.com/docs/php/howto/example_batch_request), but that could potentially be a solution for you, having 1 batched request of several calls? It might be worth looking into this, but to be clear: that still means that each request to the server requires a unique token, but by batching them up you basically send multiple requests over 1 batch request.

I'll close this issue for now as this "issue" is not related to the bundle, but inherent to nonces.

Looking forward to hearing back from you!

Hope this helps, David

xvrcjs commented 7 years ago

Thanks @djoos