How to secure Ajax link requests?

前端 未结 8 1001
刺人心
刺人心 2020-12-08 04:04

Imagine the next scenario: a user wants to register to a webpage and fills a form. While he is filling the form, jQuery keeps checking through a regular expression if fields

相关标签:
8条回答
  • 2020-12-08 04:53

    The JavaScript code on your website is executed on the computer of the user, so there is no way you could stop him from digging through your code. Even if you use a code obfuscator (for example, https://www.javascriptobfuscator.com/), the hacker could debug your application and record all requests send to the server.

    Everything security-relevant has to happen on the server. You could limit the amount of requests from a specific IP address.

    0 讨论(0)
  • 2020-12-08 04:56

    check.php should depending on the setup either only be accessible internally, or verify from where the connection is made. Take a look at this previous question- I hope it might be what you're looking for. how to verify the requesting server in php?

    0 讨论(0)
提交回复
热议问题