Merge branch 'gnuboard:master' into master
This commit is contained in:
@ -1,6 +1,5 @@
|
||||
<?php
|
||||
include_once('./_common.php');
|
||||
include_once(G5_LIB_PATH.'/json.lib.php');
|
||||
|
||||
if(!$member['mb_id'])
|
||||
die(json_encode(array('error' => '회원 로그인 후 이용해 주십시오.')));
|
||||
@ -66,4 +65,4 @@ if($result && $cp['cz_type'])
|
||||
// 다운로드 증가
|
||||
sql_query(" update {$g5['g5_shop_coupon_zone_table']} set cz_download = cz_download + 1 where cz_id = '$cz_id' ");
|
||||
|
||||
die(json_encode(array('error' => '')));
|
||||
die(json_encode(array('error' => '')));
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
<?php
|
||||
include_once('./_common.php');
|
||||
include_once(G5_LIB_PATH.'/json.lib.php');
|
||||
|
||||
define('G5_IS_SHOP_AJAX_LIST', true);
|
||||
|
||||
@ -76,4 +75,4 @@ $data['item'] = $content;
|
||||
$data['error'] = '';
|
||||
$data['page'] = $page;
|
||||
|
||||
die(json_encode($data));
|
||||
die(json_encode($data));
|
||||
|
||||
@ -38,7 +38,11 @@ foreach($data as $key=>$value) {
|
||||
$_POST[$key][$k] = $params[$key][$k] = clean_xss_tags(strip_tags($v));
|
||||
}
|
||||
} else {
|
||||
$_POST[$key] = $params[$key] = clean_xss_tags(strip_tags($value));
|
||||
if(in_array($key, array('od_memo'))){
|
||||
$_POST[$key] = $params[$key] = clean_xss_tags(strip_tags($value), 0, 0, 0, 0);
|
||||
} else {
|
||||
$_POST[$key] = $params[$key] = clean_xss_tags(strip_tags($value));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -32,10 +32,11 @@ class HttpClient {
|
||||
$data = substr($data, 1); // remove leading "&"
|
||||
$url_data = parse_url($url);
|
||||
|
||||
// host 가 inicis.com 의 주소가 아니라면 false 반환
|
||||
// [scheme] => https, [host] => fcstdpay.inicis.com, [path] => /api/payAuth
|
||||
if (preg_match("#inicis\.com$#", $url_data["host"]) == false) {
|
||||
// error_log(print_r($url_data, 1));
|
||||
// host 가 .inicis.com 의 주소가 아니라면 false 반환
|
||||
// [scheme] => https
|
||||
// [host] => fcstdpay.inicis.com || stdpay.inicis.com || ksstdpay.inicis.com
|
||||
// [path] => /api/payAuth
|
||||
if (! is_inicis_url_return($url)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@ -46,6 +46,7 @@
|
||||
* Ability to define "_NANO_SHA2_UPPER" to yeild upper case hashes.
|
||||
* 2009-08-01: Added ability to attempt to use mhash() prior to running pure
|
||||
* php code.
|
||||
* 2022-05-19: PHP 8.1 부터 deprecate 되는 mhash() 삭제
|
||||
*
|
||||
* NOTE: Some sporadic versions of PHP do not handle integer overflows the
|
||||
* same as the majority of builds. If you get hash results of:
|
||||
@ -211,11 +212,7 @@ if (!class_exists('nanoSha2'))
|
||||
|
||||
// check for php's internal sha256 function, ignore if ig_func==true
|
||||
if ($ig_func == false) {
|
||||
if (version_compare(PHP_VERSION,'5.1.2','>=')) {
|
||||
return hash("sha256", $str, false);
|
||||
} else if (function_exists('mhash') && defined('MHASH_SHA256')) {
|
||||
return base64_encode(bin2hex(mhash(MHASH_SHA256, $str)));
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
<?php
|
||||
include_once('./_common.php');
|
||||
include_once(G5_LIB_PATH.'/json.lib.php');
|
||||
include_once(G5_SHOP_PATH.'/settle_inicis.inc.php');
|
||||
|
||||
if($default['de_pg_service'] != 'inicis' && ! ($default['de_inicis_lpay_use'] || $default['de_inicis_kakaopay_use']) )
|
||||
@ -29,4 +28,4 @@ $mKey = hash("sha256", $signKey);
|
||||
$params = "oid=" . $orderNumber . "&price=" . $price . "×tamp=" . $timestamp;
|
||||
$sign = hash("sha256", $params);
|
||||
|
||||
die(json_encode(array('error'=>'', 'mKey'=>$mKey, 'timestamp'=>$timestamp, 'sign'=>$sign)));
|
||||
die(json_encode(array('error'=>'', 'mKey'=>$mKey, 'timestamp'=>$timestamp, 'sign'=>$sign)));
|
||||
|
||||
@ -62,6 +62,8 @@ if($cancelFlag == "true")
|
||||
|
||||
}
|
||||
|
||||
if(! (isset($inipay) && method_exists($inipay, 'SetField'))) return;
|
||||
|
||||
$TID = $tno;
|
||||
$inipay->SetField("type", "cancel"); // 고정
|
||||
if( $default['de_kakaopay_cancelpwd'] ){
|
||||
|
||||
@ -1,36 +1,38 @@
|
||||
<?php
|
||||
include_once('./_common.php');
|
||||
include_once(G5_LIB_PATH.'/json.lib.php');
|
||||
include(G5_SHOP_PATH.'/kakaopay/incKakaopayCommon.php');
|
||||
|
||||
// 카카오페이를 사용하지 않을 경우
|
||||
if( ! $default['de_kakaopay_enckey'] ) die('카카오페이를 사용하지 않습니다.');
|
||||
|
||||
if( ! ($default['de_kakaopay_mid'] && $default['de_kakaopay_key']) ){
|
||||
die(json_encode(array('error'=>'올바른 방법으로 이용해 주십시오.')));
|
||||
}
|
||||
|
||||
$orderNumber = get_session('ss_order_id');
|
||||
$price = preg_replace('#[^0-9]#', '', $_POST['price']);
|
||||
|
||||
if(strlen($price) < 1)
|
||||
die(json_encode(array('error'=>'가격이 올바르지 않습니다.')));
|
||||
|
||||
//
|
||||
//###################################
|
||||
// 2. 가맹점 확인을 위한 signKey를 해시값으로 변경 (SHA-256방식 사용)
|
||||
//###################################
|
||||
$mKey = hash("sha256", $default['de_kakaopay_key']);
|
||||
|
||||
/*
|
||||
//*** 위변조 방지체크를 signature 생성 ***
|
||||
oid, price, timestamp 3개의 키와 값을
|
||||
key=value 형식으로 하여 '&'로 연결한 하여 SHA-256 Hash로 생성 된값
|
||||
ex) oid=INIpayTest_1432813606995&price=819000×tamp=2012-02-01 09:19:04.004
|
||||
* key기준 알파벳 정렬
|
||||
* timestamp는 반드시 signature생성에 사용한 timestamp 값을 timestamp input에 그대로 사용하여야함
|
||||
*/
|
||||
$params = "oid=" . $orderNumber . "&price=" . $price . "×tamp=" . $timestamp;
|
||||
$sign = hash("sha256", $params);
|
||||
|
||||
die(json_encode(array('error'=>'', 'mKey'=>$mKey, 'timestamp'=>$timestamp, 'sign'=>$sign)));
|
||||
<?php
|
||||
include_once('./_common.php');
|
||||
include(G5_SHOP_PATH.'/kakaopay/incKakaopayCommon.php');
|
||||
|
||||
// 카카오페이를 사용하지 않을 경우
|
||||
if (!$default['de_kakaopay_enckey']) {
|
||||
die('카카오페이를 사용하지 않습니다.');
|
||||
}
|
||||
|
||||
if (!($default['de_kakaopay_mid'] && $default['de_kakaopay_key'])) {
|
||||
die(json_encode(array('error' => '올바른 방법으로 이용해 주십시오.')));
|
||||
}
|
||||
|
||||
$orderNumber = get_session('ss_order_id');
|
||||
$price = preg_replace('#[^0-9]#', '', $_POST['price']);
|
||||
|
||||
if (strlen($price) < 1) {
|
||||
die(json_encode(array('error' => '가격이 올바르지 않습니다.')));
|
||||
}
|
||||
|
||||
//
|
||||
//###################################
|
||||
// 2. 가맹점 확인을 위한 signKey를 해시값으로 변경 (SHA-256방식 사용)
|
||||
//###################################
|
||||
$mKey = hash("sha256", $default['de_kakaopay_key']);
|
||||
|
||||
/*
|
||||
//*** 위변조 방지체크를 signature 생성 ***
|
||||
oid, price, timestamp 3개의 키와 값을
|
||||
key=value 형식으로 하여 '&'로 연결한 하여 SHA-256 Hash로 생성 된값
|
||||
ex) oid=INIpayTest_1432813606995&price=819000×tamp=2012-02-01 09:19:04.004
|
||||
* key기준 알파벳 정렬
|
||||
* timestamp는 반드시 signature생성에 사용한 timestamp 값을 timestamp input에 그대로 사용하여야함
|
||||
*/
|
||||
$params = "oid=" . $orderNumber . "&price=" . $price . "×tamp=" . $timestamp;
|
||||
$sign = hash("sha256", $params);
|
||||
|
||||
die(json_encode(array('error'=>'', 'mKey'=>$mKey, 'timestamp'=>$timestamp, 'sign'=>$sign)));
|
||||
|
||||
@ -13,7 +13,7 @@ set_session('P_AMT', '');
|
||||
set_session('P_HASH', '');
|
||||
|
||||
$oid = isset($_REQUEST['P_NOTI']) ? trim($_REQUEST['P_NOTI']) : '';
|
||||
$p_req_url = isset($_REQUEST['P_REQ_URL']) ? trim($_REQUEST['P_REQ_URL']) : '';
|
||||
$p_req_url = isset($_REQUEST['P_REQ_URL']) ? is_inicis_url_return(trim($_REQUEST['P_REQ_URL'])) : '';
|
||||
|
||||
if( ! $p_req_url || !preg_match('/^https\:\/\//i', $p_req_url)){
|
||||
alert("잘못된 요청 URL 입니다.");
|
||||
@ -91,7 +91,7 @@ if($_REQUEST['P_STATUS'] != '00') {
|
||||
|
||||
$ch = curl_init();
|
||||
curl_setopt($ch, CURLOPT_PORT, 443);
|
||||
curl_setopt($ch, CURLOPT_URL, $_REQUEST['P_REQ_URL']);
|
||||
curl_setopt($ch, CURLOPT_URL, $p_req_url);
|
||||
curl_setopt($ch, CURLOPT_POST, 1);
|
||||
curl_setopt($ch, CURLOPT_POSTFIELDS, $post_data);
|
||||
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
/* ============================================================================== */
|
||||
/* = PAGE : 라이브버리 PAGE = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = Copyright (c) 2010.02 KCP Inc. All Rights Reserverd. = */
|
||||
/* = Copyright (c) 2010.02 KCP Inc. All Rights Reserved. = */
|
||||
/* ============================================================================== */
|
||||
|
||||
/* ============================================================================== */
|
||||
@ -10,21 +10,21 @@
|
||||
/* ============================================================================== */
|
||||
class C_PP_CLI_T
|
||||
{
|
||||
var $m_payx_common;
|
||||
var $m_payx_card;
|
||||
var $m_ordr_data;
|
||||
var $m_rcvr_data;
|
||||
var $m_escw_data;
|
||||
var $m_modx_data;
|
||||
var $m_encx_data;
|
||||
var $m_encx_info;
|
||||
public $m_payx_common;
|
||||
public $m_payx_card;
|
||||
public $m_ordr_data;
|
||||
public $m_rcvr_data;
|
||||
public $m_escw_data;
|
||||
public $m_modx_data;
|
||||
public $m_encx_data;
|
||||
public $m_encx_info;
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - 처리 결과 값 - */
|
||||
/* -------------------------------------------------------------------- */
|
||||
var $m_res_data;
|
||||
var $m_res_cd;
|
||||
var $m_res_msg;
|
||||
public $m_res_data;
|
||||
public $m_res_cd;
|
||||
public $m_res_msg;
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - 생성자 - */
|
||||
|
||||
@ -10,20 +10,20 @@
|
||||
/* ====================================================================== */
|
||||
class C_PAYPLUS_CLI_T
|
||||
{
|
||||
var $m_payx_data;
|
||||
var $m_ordr_data;
|
||||
var $m_rcvr_data;
|
||||
var $m_escw_data;
|
||||
var $m_modx_data;
|
||||
var $m_encx_data;
|
||||
var $m_encx_info;
|
||||
public $m_payx_data;
|
||||
public $m_ordr_data;
|
||||
public $m_rcvr_data;
|
||||
public $m_escw_data;
|
||||
public $m_modx_data;
|
||||
public $m_encx_data;
|
||||
public $m_encx_info;
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - 처리 결과 값 - */
|
||||
/* -------------------------------------------------------------------- */
|
||||
var $m_res_data;
|
||||
var $m_res_cd;
|
||||
var $m_res_msg;
|
||||
public $m_res_data;
|
||||
public $m_res_cd;
|
||||
public $m_res_msg;
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - 생성자 - */
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
<?php
|
||||
include_once('./_common.php');
|
||||
include_once(G5_LIB_PATH.'/json.lib.php');
|
||||
|
||||
// LG유플러스 공통 설정
|
||||
require_once(G5_SHOP_PATH.'/settle_lg.inc.php');
|
||||
@ -88,4 +87,4 @@ $payReqMap['LGD_PAYKEY'] = '';
|
||||
|
||||
$_SESSION['PAYREQ_MAP'] = $payReqMap;
|
||||
|
||||
die(json_encode(array('LGD_HASHDATA' => $LGD_HASHDATA, 'error' => '')));
|
||||
die(json_encode(array('LGD_HASHDATA' => $LGD_HASHDATA, 'error' => '')));
|
||||
|
||||
@ -20,7 +20,7 @@ if ($is_member && $count) {
|
||||
$ad_subject = isset($_POST['ad_subject'][$k]) ? clean_xss_tags($_POST['ad_subject'][$k]) : '';
|
||||
|
||||
$sql = " update {$g5['g5_shop_order_address_table']}
|
||||
set ad_subject = '$ad_subject' ";
|
||||
set ad_subject = '".sql_real_escape_string($ad_subject)."' ";
|
||||
|
||||
if(!empty($_POST['ad_default']) && $ad_id === $_POST['ad_default']) {
|
||||
sql_query(" update {$g5['g5_shop_order_address_table']} set ad_default = '0' where mb_id = '{$member['mb_id']}' ");
|
||||
|
||||
@ -542,7 +542,7 @@ $od_b_addr1 = clean_xss_tags($od_b_addr1);
|
||||
$od_b_addr2 = clean_xss_tags($od_b_addr2);
|
||||
$od_b_addr3 = clean_xss_tags($od_b_addr3);
|
||||
$od_b_addr_jibeon = preg_match("/^(N|R)$/", $od_b_addr_jibeon) ? $od_b_addr_jibeon : '';
|
||||
$od_memo = clean_xss_tags($od_memo);
|
||||
$od_memo = clean_xss_tags($od_memo, 1, 1, 0, 0);
|
||||
$od_deposit_name = clean_xss_tags($od_deposit_name);
|
||||
$od_tax_flag = $default['de_tax_flag_use'];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user