T
T
Timur Asgard2017-03-24 20:11:26
Laravel
Timur Asgard, 2017-03-24 20:11:26

How to implement ajax request authorization?

Hey! I can not figure out how to implement AJAX request authorization in any way.
Task input data:
There is some functionality with the /api/post/create endpoint, and you need to somehow implement request authorization when you try to access this API method via AJAX.
Disclaimer:
It would be possible to use the oAuth authentication mechanism with subsequent authorization of requests, but this is too cumbersome, as for me ...
PS
API and AJAX are all one server and one domain, in general, one big CMS

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alex Bond, 2017-03-24
@AlexBond

1. Sessions
2. Generation of key strings for the request
3. Generation of RSA keys (for particularly evil individuals)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question