FirefoxまたはChromeのデバッガーを介してjavascript関数を変更する手順を知っている人はいますか? 深刻なセキュリティ上の懸念はありますか?
質問する
69 次
1 に答える
0
The steps to change JS function using chrome devtools are as follow:
- Open chrome dev tools (you can use right-click and then choose inspect element).
- Open the 'Source' tab.
- Choose the javascript file that contain the function you wish to change.
- Edit the code.
- Click on 'ctrl-s' to save it.
- You are done. If this code is being called from an event on the page (e.g. click on a button) you will be able to see your changes without any reload.
As for security concerns, you should always validate the user input on the server side. On the client you should 'guide' the user to enter the right data but never trust it. There are many cases where someone will be able to change the data 'on the fly' (=man in the middle) so you should never trust the client.
于 2013-01-25T10:16:56.387 に答える