PHP Scripts open_basedir Restriction in Effect Error PHP הגבלת סקריפטים open_basedir למעשה שגיאה

PHP open_basedir protection tweak is a Safe Mode security measure that prevents users from opening files or scripts located outside of their home directory with PHP, unless the folder has specifically excluded. לצבוט PHP הגנה open_basedir הוא בטוח למדוד מצב האבטחה מונע ממשתמשים לפתוח קבצים או סקריפטים הממוקמים מחוץ לביתם של המדריך עם PHP, אלא אם כן יש את התיקייה במפורש נשלל. PHP open_basedir setting if enabled, will ensure that all file operations to be limited to files under certain directory, and thus prevent php scripts for a particular user from accessing files in unauthorized user's account. הגדרת open_basedir PHP אם הוא מופעל, תוודא שכל הקבצים פעולות יוגבלו קבצים תחת ספריה מסוימת, ובכך למנוע הסקריפטים PHP עבור משתמש מסוים מקבצים גישה לחשבון של משתמש לא מורשה. When a script tries to open a file with, for example, fopen() or gzopen(), the location of the file is checked. כאשר סקריפט מנסה לפתוח קובץ עם, למשל, fopen () או gzopen (), את המיקום של הקובץ הוא בדק. When the file is outside the specified or permissible directory-tree, PHP will refuse to open it and the following errors may occur: כאשר הקובץ הוא מחוץ במדריך המצוין עץ או מותר, PHP מסרבים לפתוח אותו ואת השגיאות הבאות עלולות להתרחש:

Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. Warning: file_exists () [function.file-קיים]: open_basedir ההגבלה בתוקף. File(/home/user_name/public_html/wp-content/uploads/2006/12/picture.jpg) is not within the allowed path(s): (/home/user_name:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/user_name/public_html/wp-admin/inline-uploading.php on line 226 קובץ (/ home/user_name/public_html/wp-content/uploads/2006/12/picture.jpg) היא לא בתוך הנתיב המותר (s): (/ home / user_name: / usr / lib / php: / usr / local / lib / php: / tmp) in / home / user_name / public_html / wp-admin / מוטבעות-uploading.php על קו 226

The above error message appears on a Apache httpd web server error log (error_log) hosting Wordpress blog. הודעת השגיאה הנ"ל מופיעה על יומן של שרת אינטרנט Apache httpd שגיאה (error_log) אירוח בלוג WordPress. However, the problem may happen to all system or websites that use PHP as scripting language. עם זאת, הבעיה עשויה לקרות בכל מערכת או אתרי אינטרנט להשתמש ב PHP בתור שפת סקריפט.

The solution or workaround to open_basedir restriction problem is that disable the PHP open_basedir protection altogether, or to exclude the protection for certain privileged user accounts, or to allow access to the additional directory for PHP scripts. הפתרון או פתרון הבעיה כדי open_basedir ההגבלה היא להשבית את ההגנה PHP open_basedir לגמרי, או לכלול את ההגנה עבור חשבונות המשתמש חסוי מסוימים, או כדי לאפשר גישה לספרייה נוסף עבור הסקריפטים PHP.

If you're using cPanel WebHost Manager (WHM), you can easily disable PHP open_basedir protection or exclude certain users from the protection with WHM. אם אתה משתמש מנהל למארח cPanel (WHM), אתה יכול בקלות לבטל הגנה PHP open_basedir או להוציא משתמשים מסוימים להגנה על עם WHM. Simply go to “Tweak Security” under the “Security” section, then select “Configure” link for “Php open_basedir Tweak”. פשוט ללכת "כוונן אבטחה" תחת סעיף "אבטחה", ולאחר מכן בחר באפשרות "הגדרות" הקישור "PHP open_basedir Tweak". Inside it, you can enable or disable php open_basedir Protection, or exclude and include hosts from the protection. בתוך זה, אתה יכול להפעיל או לבטל הגנה open_basedir PHP, או לכלול וכוללים מארח מן ההגנה.

If you're using Plesk hosting control panel, you may need to manually edit Apache configuration file of vhost.conf and vhost_ssl.conf, and add in or edit the following php_admin_value open_basedir lines to the following: אם אתה משתמש בלוח הבקרה Plesk אירוח, ייתכן שיהיה עליך לערוך ידנית קובץ תצורה של אפאצ 'י vhost.conf ו vhost_ssl.conf, ולהוסיף או לערוך את השורות הבאות open_basedir php_admin_value הבאה:

<Directory /full/path/to/the/directory/httpdocs> <Directory /full/path/to/the/directory/httpdocs>
php_admin_value open_basedir none open_basedir לא php_admin_value
</Directory> </ Directory>

<Directory /full/path/to/the/directory/httpdocs> <Directory /full/path/to/the/directory/httpdocs>
php_admin_value open_basedir /full/path/to/dir:/full/path/to/directory/httpdocs:/tmp open_basedir php_admin_value / מלא / path / to / dir: / מלא / path / to / directory / httpdocs: / tmp
</Directory> </ Directory>

Note: For SSL hosts in the vhost_ssl.conf file, the Directory path will end with “httpsdocs” instead of “httpdocs”. הערה: לקבלת המארחים SSL בקובץ vhost_ssl.conf, את הנתיב מדריך יסתיים "httpsdocs" במקום "httpdocs".

The paths (above is example only and to be replaced with real path) that behind open_basedir are the directories that specifically allowed for the PHP scripts in the vhost domain account to access, so you can add in more directories that files are been stored and needed to be opened by PHP, each seperated by color “:”. השבילים (לעיל הוא דוגמה בלבד להתחלף עם הנתיב האמיתי) כי מאחורי open_basedir את הספריות כי הם הורשו במפורש עבור בחשבון תחום vhost הסקריפטים PHP לגשת, כדי שתוכל להוסיף בספריות יותר כי הקבצים שנשמרו ואת הצורך להיפתח על ידי PHP, מופרדים על ידי כל צבע ":". But be careful as it might expose your system to security fraud. אבל להיזהר כמו שזה עלול לחשוף את המערכת שלך כדי הונאה אבטחה.

Once done, run the command below to make the changes effective, and then restart Apache httpd web server (apache2ctl restart or httpd restart): פעם עשיתי, הפעל את הפקודה שלהלן כדי לבצע את השינויים יעיל, ולאחר מכן הפעל מחדש את שרת האינטרנט Apache httpd (apache2ctl httpd מחדש או להפעיל מחדש):

$PRODUCT_ROOT_D/admin/sbin/websrvmng -v -a PRODUCT_ROOT_D admin $ / / sbin / websrvmng-V -

If you have to manually edit the Apache configuration file to disable PHP open_basedir protection, simply open up the httpd.conf file, and search for the lines that starts with the following characters: אם אתה צריך לערוך באופן ידני את התצורה של אפאצ 'י הקובץ להגנה PHP open_basedir להשבית, פשוט לפתוח את הקובץ httpd.conf, ולחפש את השורות שמתחיל את התווים הבאים:

php_admin_value open_basedir ….. open_basedir php_admin_value ... ..

Replace the whole line under the virtual host for the domain user account that you want to disable protection with the following line to disable it: החלף את הקו כולו תחת לארח את וירטואליים עבור חשבון המשתמש תחום שאתה רוצה עם הגנה להשבית את השורה הבאה כדי לבטל את זה:

php_admin_value open_basedir none open_basedir לא php_admin_value

You can also opt to allow your PHP scripts to access additional directory instead without disabling the protection. אתה יכול גם לבחור לאפשר הסקריפטים PHP שלך לגשת המדריך נוספים במקום מבלי להשבית את ההגנה. Additional directory can be added to the line, separated with color “:”. במדריך ניתן להוסיף לקו, מופרדים עם צבע ":". For example, to add /new_directory to the allow list: לדוגמה, כדי להוסיף / new_directory את רשימת ההיתרים:

php_admin_value open_basedir “/home/user_account/:/usr/lib/php:/usr/local/lib/php:/tmp” open_basedir php_admin_value "/ home / user_account /: / usr / lib / php: / usr / local / lib / php: / tmp"

php_admin_value open_basedir “/home/user_account/:/usr/lib/php:/usr/local/lib/php:/tmp:/new_directory” open_basedir php_admin_value "/ home / user_account /: / usr / lib / php: / usr / local / lib / php: / tmp: / new_directory"

Restart the Apache after finished editing. הפעל מחדש את אפאצ 'י לאחר עריכת גמר. Note that the directory allowed list restriction above is actually a prefix, not a directory name. שים לב במדריך מותר הגבלה הרשימה לעיל הוא למעשה הקידומת, לא שם בספרייה. This means that “open_basedir = /dir/incl” also allows access to “/dir/include” and “/dir/incls” if they exist. פירוש הדבר כי open_basedir "= / dir / כולל" מאפשר גם גישה "/ dir / לכלול" ו "/ dir / incls" אם הם קיימים. When you want to restrict access to only the specified directory, end with a slash. כאשר אתה רוצה להגביל את הגישה רק במדריך המצוין, סוף עם קו נטוי. For example: “open_basedir = /dir/incl/”. לדוגמה: "open_basedir = / / Dir כולל /".

IMPORTANT : The page is machine translated and provided "as is" without warranty. חשוב: הדף מכונת תירגם מתפרסם "כמות שהוא" ללא אחריות. Machine translation may be difficult to understand. תרגום מכונה יכול להיות קשה להבין. Please refer to נא עיין original English article המאמר המקורי באנגלית whenever possible. בכל הזדמנות אפשרית.


3 Responses to “PHP Scripts open_basedir Restriction in Effect Error” 3 תגובות ל "PHP הגבלת סקריפטים open_basedir למעשה שגיאה"

  1. PHP Problem nach backup-DRINGEND - WinBoard - Die Windows Community PHP גיבוי Problem nach-DRINGEND - WinBoard - Die-Windows קהילה
    July 26th, 2009 18:12 26 יולי 2009 18:12
    3 3

    [...] [...] [...] [...]

  2. Amateur Dating Club מועדון דייטינג חובב
    December 21st, 2007 16:58 21 דצמבר 2007 16:58
    2 2

    Great article. מאמר נהדר.
    Thanks for the WHM tip. תודה על הטיפ WHM.

    You saved my ass. הצלת את התחת שלי.

  3. Error open_basedir restriction in effect en Agamum.net מגבלה שגיאה open_basedir בתוקף en Agamum.net
    December 3rd, 2007 16:21 3 דצמבר 2007 16:21
    1 1

    [...] queréis más información sobre este tema, hay un artículo muy interesante sobre este error en My Digital Life. [...] Queréis más información sobre este tema, Articulo האו"ם חציר שגיאה muy interesante sobre este en החיים הדיגיטליים שלי. Etiquetas: Desarrollo, hosting, open_basedir, [...] Etiquetas: ועדכונים, אירוח, open_basedir, [...]

Leave a Reply השאירו תגובה

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> באפשרותך להשתמש בתגים אלה: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime = ""> <em> <i> <q cite=""> <strike> <strong>

Subscribe to comments feature has been disabled. כדי להירשם הערות תכונה הושבת. To receive notification of latest comments posted, subscribe to כדי לקבל הודעה העדכנית של תגובות, כדי להירשם My Digital Life Comments RSS feed החיים שלי דיגיטליות תגובות RSS Feed or או register to receive הרשמה לקבלת new comments in daily email digest. תגובות חדש ב דוא"ל תקציר יומי.
Custom Search

New Articles מאמרים חדשים

Incoming Search Terms for the Article תנאי נכנסות חיפוש עבור מאמרים

open_basedir restriction in effect מגבלה open_basedir בתוקף - -- open_basedir restriction in effect. מגבלה open_basedir בתוקף. - -- open_basedir restriction מגבלה open_basedir - -- php open_basedir restriction in effect מגבלה open_basedir PHP בתוקף - -- open_basedir restriction in effect cpanel מגבלה open_basedir בתוקף cPanel - -- wordpress open_basedir restriction in effect מגבלה open_basedir WordPress בתוקף - -- apache open_basedir open_basedir Apache - -- plesk open_basedir restriction in effect מגבלה open_basedir Plesk בתוקף - -- open_basedir whm WHM open_basedir - -- open_basedir restriction in effect php מגבלה open_basedir בתוקף PHP - -- open_basedir apache Apache open_basedir - -- wordpress Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. WordPress אזהרה: file_exists () [function.file-קיים]: open_basedir ההגבלה בתוקף. - -- open_basedir example לדוגמה open_basedir - -- cpanel open_basedir restriction in effect מגבלה open_basedir cPanel בתוקף - -- open_basedir restriction in effect wordpress מגבלה open_basedir בתוקף WordPress - -- php_admin_value open_basedir php PHP open_basedir php_admin_value - -- open_basedir restriction in effect where מגבלה open_basedir למעשה שם - -- php open_basedir wordpress WordPress open_basedir PHP - -- php disable open_basedir open_basedir להשבית PHP - -- Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. Warning: file_exists () [function.file-קיים]: open_basedir ההגבלה בתוקף. - -- whm open_basedir open_basedir WHM - -- php open_basedir restriction in effect. מגבלה open_basedir PHP בתוקף. - -- php open_basedir restrictions הגבלות open_basedir PHP - -- "open_basedir restriction in effect." "הגבלה open_basedir בתוקף." - -- open_basedir restriction in effect plesk מגבלה open_basedir בתוקף Plesk - -- main(): open_basedir restriction in effect ההגבלה העיקרית (): open_basedir בתוקף - -- open_basedir restriction in effect. מגבלה open_basedir בתוקף. - -- open_basedir restriction מגבלה open_basedir - -- open_basedir restriction in effect. מגבלה open_basedir בתוקף. php php - -- open_basedir restriction in effect. מגבלה open_basedir בתוקף. cpanel cPanel - -- "open_basedir restriction in effect" "הגבלה open_basedir בתוקף" - -- arning: file_exists() [function.file-exists]: open_basedir restriction in effect. arning: file_exists () [function.file-קיים]: open_basedir ההגבלה בתוקף. - -- how to configure open_basedir כיצד להגדיר open_basedir - -- open_basedir open_basedir - -- open_basedir apache problem הבעיה Apache open_basedir - -- open_basedir restriction in effect remove מגבלה open_basedir בתוקף להסיר - -- open_basedir + whm open_basedir + WHM - -- open_basedir restriction in effect. מגבלה open_basedir בתוקף. aioseop.class.php aioseop.class.php - -- php remove open_basedir restriction iis hosting controller PHP להסיר מגבלה open_basedir IIS אירוח בקר - -- php help Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. אזהרה לעזור PHP: file_exists () [function.file-קיים]: open_basedir ההגבלה בתוקף. File קובץ - -- warning file_exists function.file-exists open_basedir restriction in effect. file_exists אזהרה function.file-קיימת מגבלה open_basedir בתוקף. wordpress WordPress - -- wordpress /tmp openbasedir restrictrion / tmp WordPress openbasedir restrictrion - -- apache php directory protection המדריך PHP Apache הגנה - -- apache 2.2 open_basedir Apache 2.2 open_basedir - -- open_basedir restriction in effect. מגבלה open_basedir בתוקף. wordpress WordPress - -- open basedir restriction in effect מגבלה basedir לפתוח בתוקף - -- open_basedir protection הגנה open_basedir - -- open_basedir additional directory המדריך נוספים open_basedir - -- open_basedire restriction in effect מגבלה open_basedire בתוקף - -- pen_basedir restriction in effect. מגבלה pen_basedir בתוקף. - --