如何通过PayPal确保我的支付系统安全?
我使用vue-paypal-check创建前端PayPal支付按钮。
以下是代码:
<Pay-Pal
v-if="paypal_live_id && paypal_sandbox_id"
:amount="amount"
currency="USD"
:client="credentials"
:env="paypal_env"
@payment-authorized="payment_authorized_cb"
@payment-completed="payment_completed_cb"
@payment-cancelled="payment_cancelled_cb"
:items="pay_items"
>
</Pay-Pal>
以下是一些关于Dota的内容:
data(){
return {
paypal_env: this.$GLOBAL_CONST.PAYMENT.PAYPAL_ENV,
paypal_sandbox_id: undefined,
paypal_live_id: undefined,
}
},
computed: {
credentials() {
return {
sandbox: this.paypal_sandbox_id,
production: this.paypal_live_id,
}
},
},
支付成功的回调方法:
payment_completed_cb(res){
some method to access API for payment success // there will request the API for change the order status or reduce the balance.
},
但我有一个问题,如果某个客户对技术很了解,他会直接调用payment_completed_cb
而不是通过PayPal支付。
我该如何防止这种情况发生?