Y
Y
yuriy_zuikov2015-12-02 15:05:47
Google Chrome
yuriy_zuikov, 2015-12-02 15:05:47

How to identify a chrome extension?

Good afternoon. Help advice. Wrote an extension for chrome to collect statistics. Statistics are sent to my site. The site from which statistics will be collected has a unique ID, this ID is indicated by the user when registering on my site, and the user is now identified by this ID. The problem is that the usual enumeration of IDs can send any user, any statistics. How can I determine that the request came from my extension, and not a fake request? Is there any way to do without authorization in the extension?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dmitry Belyaev, 2015-12-02
@bingo347

If the ID is tied to one specific browser, then you can generate a token and change it with each request
requested with the correct token - everything is OK, we are working, keep the token in the response for the next request

Y
yuriy_zuikov, 2015-12-02
@yuriy_zuikov

You can step by step. The user opens the site, the extension understands what needs to be done, collects statistics and sends a request params[id], params[statistic].
Dmitry, if we are talking about the same thing, when and where should I generate a token. Maybe how to obfuscate js ( habrahabr.ru/post/112530/) and generate it somehow.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question