key파일 생성 디렉토리 체크 코드 추가
This commit is contained in:
@ -4,6 +4,9 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
|||||||
if(!$config['cf_cert_use'] || $config['cf_cert_hp'] != 'kcb')
|
if(!$config['cf_cert_use'] || $config['cf_cert_hp'] != 'kcb')
|
||||||
alert('기본환경설정에서 KCB 휴대폰본인확인 서비스로 설정해 주십시오.');
|
alert('기본환경설정에서 KCB 휴대폰본인확인 서비스로 설정해 주십시오.');
|
||||||
|
|
||||||
|
// key 디렉토리 체크
|
||||||
|
include_once('./key_dir_check.php');
|
||||||
|
|
||||||
/**************************************************************************
|
/**************************************************************************
|
||||||
* okname 생년월일 본인 확인서비스 파라미터
|
* okname 생년월일 본인 확인서비스 파라미터
|
||||||
**************************************************************************/
|
**************************************************************************/
|
||||||
|
|||||||
@ -4,6 +4,9 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
|||||||
if(!$config['cf_cert_use'] || $config['cf_cert_ipin'] != 'kcb')
|
if(!$config['cf_cert_use'] || $config['cf_cert_ipin'] != 'kcb')
|
||||||
alert('기본환경설정에서 KCB 아이핀 본인확인 서비스로 설정해 주십시오.');
|
alert('기본환경설정에서 KCB 아이핀 본인확인 서비스로 설정해 주십시오.');
|
||||||
|
|
||||||
|
// key 디렉토리 체크
|
||||||
|
include_once('./key_dir_check.php');
|
||||||
|
|
||||||
// 실행모듈
|
// 실행모듈
|
||||||
if(strtoupper(substr(PHP_OS, 0, 3)) !== 'WIN') {
|
if(strtoupper(substr(PHP_OS, 0, 3)) !== 'WIN') {
|
||||||
if(PHP_INT_MAX == 2147483647) // 32-bit
|
if(PHP_INT_MAX == 2147483647) // 32-bit
|
||||||
|
|||||||
25
plugin/okname/key_dir_check.php
Normal file
25
plugin/okname/key_dir_check.php
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
<?php
|
||||||
|
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||||
|
|
||||||
|
$key_dir = G4_OKNAME_PATH.'/key';
|
||||||
|
if(!is_dir($key_dir)) {
|
||||||
|
alert_close(G4_PLUGIN_DIR.'/'.G4_OKNAME_DIR.' 에 key 디렉토리를 생성해 주십시오.\\n\\n디렉토리 생성 후 쓰기권한을 부여해 주십시오. 예: chmod 707 key');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (strtoupper(substr(PHP_OS, 0, 3)) !== 'WIN') {
|
||||||
|
$sapi_type = php_sapi_name();
|
||||||
|
if (substr($sapi_type, 0, 3) == 'cgi') {
|
||||||
|
if (!(is_readable($key_dir) && is_executable($key_dir)))
|
||||||
|
{
|
||||||
|
$msg = G4_PLUGIN_DIR.'/'.G4_OKNAME_DIR.'/key 디렉토리의 퍼미션을 705로 변경하여 주십시오.\\nchmod 705 key 또는 chmod uo+rx key';
|
||||||
|
alert_close($msg);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (!(is_readable($key_dir) && is_writeable($key_dir) && is_executable($key_dir)))
|
||||||
|
{
|
||||||
|
$msg = G4_PLUGIN_DIR.'/'.G4_OKNAME_DIR.'/key 디렉토리의 퍼미션을 707로 변경하여 주십시오.\\n\\nchmod 707 key 또는 chmod uo+rwx key';
|
||||||
|
alert_close($msg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
Reference in New Issue
Block a user