Security doubt about Paypal button
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I'm doing a proof of concept of the Paypal button https://developer.paypal.com/docs/classic/paypal-payments-standard/integration-guide/html_example_bu... and I have a question.
What happen if an experienced user changes the value of the input[name="amount"] to another lower value using the javascript console of the web browser, will change the checkout amount?
How can I ensure buyers using this method are paying the right amount, for example, when paying digital products where the product is automatically sent to the buyer.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you're using the online button creator to generate the button code and you save your item button code to PayPal servers, then the amount value cannot be changed as certain variables are protected.
If you're manually creating the code and/or you're using a script to manage the function of your item button code, then you can't save the button code to the PayPal servers. Yes, if the code is clear text, the amount value can be changed. However, you have the final say for approval of the sale and you can cancel it if something is not correct. If you have everything automated, then you may have to also build in some validation checks of your own.

Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.