バージョン選択

フォーラム

メニュー

オンライン状況

76 人のユーザが現在オンラインです。 (68 人のユーザが フォーラム を参照しています。)
登録ユーザ: 1
ゲスト: 75
red もっと...

サイト内検索

質問 > 管理機能 > open_basedir, is not within the allowed path(s)

管理機能

新規スレッドを追加する

フラット表示 前のトピック | 次のトピック
投稿者 スレッド
dab
投稿日時: 2009/3/31 0:00
対応状況: −−−
半人前
登録日: 2009/1/31
居住地: 京都
投稿: 13
Re: open_basedir, is not within the allowed path(s)
サーバーはJ-Web ( http://aiosl.com/j-web/service.html ) です。
設置依頼を受けての設置ですので、依頼者様がどのようなサービスで契約されているのかは不明ですが、
たぶんメールアドレスの個数とウイルスチェックの有無の違いしかないと思います。

phpinfo()によると、
OSはLinuxとだけ出ていて、ディストリビューションやバージョンなどは不明です。
すみませんが、何が有用な情報なのかわかりませんので、
phpinfo()の中で、有用な情報などがあれば補足します。


調べてみたところ、
data/class/SC_UploadFile.php
83行目以降、function makeTempFile()

102行目
$this->temp_file[$cnt] = $this->makeThumb(
       $_FILES[$keyname]['tmp_name'], $this->width[$cnt], $this->height[$cnt]);

となっていますので、
PHPのmove_uploaded_file()を使って/tmpディレクトリからEC-Cubeをインストールしたディレクトリに移動させるなどすれば対策できるのではないかと思ったのですが、

$dab_tmp_name= IMAGE_TEMP_URL.substr(strrchr($_FILES[$keyname]['tmp_name'], "/"), 1);
move_uploaded_file($_FILES[$keyname]['tmp_name'], $dab_tmp_name);
$_FILES[$keyname]['tmp_name']=$dab_tmp_name;

としてみたところ、

Warning: move_uploaded_file(): SAFE MODE Restriction in effect.
 The script whose uid is 3655 is not allowed to access / owned by uid 0 
in /(略)/data/class/SC_UploadFile.php on line 109
(BBS投稿時に改行追加)

やはりセーフモードとopen_basedirの制限に引っかかったようで、

$this->temp_file[$cnt] = $this->makeThumb(
       $_FILES[$keyname]['tmp_name'], $this->width[$cnt], $this->height[$cnt]);

(結果) 指定されたパスにファイルが見つかりません。

サムネイルを生成する関数でも、ファイルがないというメッセージが表示され、アップロードが中断されました。


参考
http://jp.php.net/manual/ja/reserved.variables.files.php
http://jp.php.net/manual/ja/function.move-uploaded-file.php
フラット表示 前のトピック | 次のトピック


題名 投稿者 日時
   open_basedir, is not within the allowed path(s) dab 2009/3/30 21:45
     Re: open_basedir, is not within the allowed path(s) tao_s 2009/3/30 22:37
       Re: open_basedir, is not within the allowed path(s) seasoft 2009/3/30 22:50
       » Re: open_basedir, is not within the allowed path(s) dab 2009/3/31 0:00
           Re: open_basedir, is not within the allowed path(s) dab 2009/3/31 1:04

 



ログイン


EC-CUBE公式 Amazon Payプラグイン

統計情報

総メンバー数は88,860名です
総投稿数は109,996件です

投稿数ランキング

1
seasoft
7367
2
468
3217
3
AMUAMU
2712
4
nanasess
2313
5
umebius
2085
6
yuh
1819
7
h_tanaka
1646
8
red
1570
9
mcontact
1294
10
tsuji
958
11
fukap
907
12
shutta
835
13
tao_s
799
14 ramrun 789
15 karin 689
16 sumida 641
17
homan
633
18 DELIGHT 572
19
patapata
502
20
flealog
485


ネットショップの壺

EC-CUBEインテグレートパートナー

Copyright© EC-CUBE CO.,LTD. All Rights Reserved.