Compare commits
2 Commits
cb2e3ea581
...
c5bc610e2f
| Author | SHA1 | Date | |
|---|---|---|---|
| c5bc610e2f | |||
| a86a24ca34 |
@@ -66,6 +66,9 @@ class ChargeController(
|
||||
header.split(",")[0].trim() // 첫 번째 값이 클라이언트 IP
|
||||
}
|
||||
|
||||
println(remoteIp)
|
||||
println(payverseInboundIp)
|
||||
|
||||
if (remoteIp != payverseInboundIp) {
|
||||
throw ResponseStatusException(HttpStatus.NOT_FOUND)
|
||||
}
|
||||
|
||||
@@ -343,9 +343,7 @@ class ChargeService(
|
||||
}
|
||||
|
||||
val body = response.body?.string() ?: throw SodaException("결제정보에 오류가 있습니다.")
|
||||
println(body)
|
||||
val verifyResponse = objectMapper.readValue(body, PayverseVerifyResponse::class.java)
|
||||
println(verifyResponse)
|
||||
|
||||
val customerId = "${serverEnv}_user_${member.id!!}"
|
||||
val isSuccess = verifyResponse.resultStatus == "SUCCESS" &&
|
||||
@@ -354,7 +352,6 @@ class ChargeService(
|
||||
verifyResponse.productName == charge.title &&
|
||||
verifyResponse.customerId == customerId &&
|
||||
verifyResponse.requestAmount.compareTo(charge.can!!.price) == 0
|
||||
println(isSuccess)
|
||||
|
||||
if (isSuccess) {
|
||||
// verify 함수의 232~248 라인과 동일 처리
|
||||
|
||||
Reference in New Issue
Block a user