PHP Scripts open_basedir Restriction in Effect Error PHP Skripte open_basedir ograničenje na snazi Greška
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 zaštita štipanje je sigurnosna Safe Mode mjera koja sprečava korisnike od otvaranja datoteke ili skripte koja se nalazi izvan svoje kuće imenik sa PHP-u, osim ako je izričito isključeno mapu. 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. PHP open_basedir postavljanje ako je omogućen, će osigurati da svi varalica operacije biti ograničen na datoteke pod određenim direktorija, i na taj način spriječiti php original za određenog korisnika iz datoteke u neovlašteni pristup korisničkom računu. When a script tries to open a file with, for example, fopen() or gzopen(), the location of the file is checked. Kada skripta će pokušati otvoriti datoteku s, na primjer, fopen () ili gzopen (), se provjerava lokaciju datoteke. When the file is outside the specified or permissible directory-tree, PHP will refuse to open it and the following errors may occur: Kada je datoteka izvan navedenih ili dozvoljena-stablo direktorija, PHP će odbiti da ga otvoriti i svibanj pojaviti sljedeće pogreške:
Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. Warning: file_exists () [function.file-exists]: open_basedir restriction in effect. 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 File (/ home/user_name/public_html/wp-content/uploads/2006/12/picture.jpg) nije dozvoljeno unutar put (a): (/ home / korisničko_ime: / usr / lib / php: / usr / local / lib / php: / tmp) in / home / korisničko_ime / public_html / wp-admin / inline-uploading.php on line 226
The above error message appears on a Apache httpd web server error log (error_log) hosting Wordpress blog. Iznad poruka o pogrešci pojavljuje se na Apache HTTP tkanje poslužitelj greška klada (error_) Wordpress blog hosting. However, the problem may happen to all system or websites that use PHP as scripting language. Međutim, problem svibanj dogoditi se na sve sustava ili web-mjesta koja koriste kao PHP skriptni jezik.
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. Rješenje ili workaround to open_basedir restriction problem je u tome onemogućiti zaštita PHP open_basedir ukupno, ili isključiti zaštitu za određene privilegiranih korisničkih računa, ili omogućiti pristup dodatnim direktorij za PHP skripte.
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. Ako ste koristeći cPanel WebHost Voditelj (WHM), lako možete onemogućiti PHP open_basedir zaštiti ili isključiti određenim korisnicima iz zaštite s WHM. Simply go to “Tweak Security” under the “Security” section, then select “Configure” link for “Php open_basedir Tweak”. Jednostavno idite na "Praćka sigurnost" pod "Sigurnost" odjeljak, a zatim odaberite "Configure" link za "Php open_basedir Praćka". Inside it, you can enable or disable php open_basedir Protection, or exclude and include hosts from the protection. Unutra, to možete omogućiti ili onemogućiti php open_basedir zaštitu, ili isključiti i uključiti domaćini iz zaštite.
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: Ako koristite Plesk hosting control panel, svibanj vam je potrebno za ručno uređivati Apache oblik varalica od vhost.conf i vhost_ssl.conf, te dodati ili urediti sljedeće php_admin_value open_basedir linije na sljedeće:
<Directory /full/path/to/the/directory/httpdocs> <Directory /full/path/to/the/directory/httpdocs>
php_admin_value open_basedir none php_admin_value open_basedir none
</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 php_admin_value open_basedir / full / path / to / dir: / full / path / do / direktorija / httpdocs: / tmp
</Directory> </ Directory>
Note: For SSL hosts in the vhost_ssl.conf file, the Directory path will end with “httpsdocs” instead of “httpdocs”. Napomena: Za SSL domaćini u vhost_ssl.conf datoteci, Directory put će završiti sa "httpsdocs" umjesto "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 “:”. Staze (gore je samo primjer i biti zamijenjen sa pravi put) da se iza open_basedir su direktorija koji izričito dopušten za PHP skripti u vhost domeni račun za pristup, tako da možete dodati u više direktorija koji su bili pohranjeni nacrti i potrebni biti otvorena po PHP-u, svaka odvojena po boji ":". But be careful as it might expose your system to security fraud. Ali budite oprezni, jer može izložiti svoj sustav za sigurnost prijevara.
Once done, run the command below to make the changes effective, and then restart Apache httpd web server (apache2ctl restart or httpd restart): Jedanput ispunjavanja, trčanje naredba ispod kako bi promjene na snazi, i tada ponovno pokretanje Apache HTTP tkanje poslužitelj (apache2ctl ponovno pokretanje ili httpd restart):
$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: Ako morate ručno urediti Apache oblik varalica to onesposobiti PHP open_basedir zaštitu, jednostavno otvoriti httpd.conf fascikl, i potraga za linije koje počinje sljedeće znakove:
php_admin_value open_basedir ….. php_admin_value open_basedir ... ..
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: Opet staviti cijeli redak pod virtual host za domene korisnički račun koji želite onemogućiti zaštite sa slijedeće crta to ga isključiti:
php_admin_value open_basedir none php_admin_value open_basedir none
You can also opt to allow your PHP scripts to access additional directory instead without disabling the protection. Također možete odlučiti za dopustiti tvoj PHP original to pristup dodatnim imenik umjesto onesposobljavanje bez zaštite. Additional directory can be added to the line, separated with color “:”. Dodatni imenik može biti dodan u liniju, odvojen s color ":". For example, to add /new_directory to the allow list: Na primjer, za dodavanje / new_directory to dopustiti liste:
php_admin_value open_basedir “/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"
php_admin_value open_basedir “/home/user_account/:/usr/lib/php:/usr/local/lib/php:/tmp:/new_directory” php_admin_value open_basedir "/ home / user_account /: / usr / lib / php: / usr / local / lib / php: / tmp: / new_directory"
Restart the Apache after finished editing. Ponovno pokretanje Apache nakon završiti uređivanje. Note that the directory allowed list restriction above is actually a prefix, not a directory name. Bilješka taj direktorij dopušteno ograničenje popisa gore je zapravo prefiks, a ne ime direktorija. This means that “open_basedir = /dir/incl” also allows access to “/dir/include” and “/dir/incls” if they exist. To znači da "open_basedir = / dir / uključ" također omogućava pristup "/ dir / include" i "/ dir / incls" ako oni postoje. When you want to restrict access to only the specified directory, end with a slash. Kada želite ograničiti pristup samo određenom direktoriju, kraj s udarac. For example: “open_basedir = /dir/incl/”. Na primjer: "open_basedir = / dir / uključ /".
IMPORTANT : The page is machine translated and provided "as is" without warranty. VAŽNO: stranica je stroj prevedeno i pružena "kakav je" sa garantni. Machine translation may be difficult to understand. Strojno prevođenje svibanj biti teško za razumjeti. Please refer to Molimo pogledajte original English article izvorni Engleski jezik članak whenever possible. kad god je to moguće.
Related Articles Vezani članci
- Group Policy Login or Logon Scripts Not Running, Not Working or Not Executing Group Policy Prijava ili Prijava Scripts Ne Trčanje, Ne Rad ili Ne Executing
- cPanel WHM Failed to Receive Status Information From Apache Error cPanel WHM Nije ispunilo proročanstvo to Primiti Stanje Information From Apache Greška
- PHP Parse Error: syntax error, unexpected $end PHP Parsiranje Greška: sintaktička pogreška, neočekivan $ kraj
- winnt_accept: Asynchronous AcceptEx failed Error in Apache Log winnt_accept: Asinkroni AcceptEx propustila Greška u Apache Prijava
- Request URL /server-status or 404 Page Not Found Apache Error Request URL / server-status ili 404 Stranica Ne Postaviti Apache Greška
- Apache Warn NameVirtualHost *:80 Has No VirtualHosts Error When Start Apache Upozori NameVirtualHost *: 80 nema VirtualHosts Greška Našto Start
- Bypass and Remove 3 Plays or 3 Days Restriction on Zune WiFi Sharing Zaobići pa Premeštanje 3 Plays ili 3 Dani Ograničenje na Zune WiFi Šerif
- gmmktime Error in WordPress and MagpieRSS gmmktime Greška in WordPress i MagpieRSS
- Fix Internal Server Error When Accessing Easy Apache in cPanel WebHosting Manager Škripac Internal Server Error prilikom pristupa Easy Apache u WebHosting cPanel Manager
- PHP Allowed Memory Size Exchausted Fatal Error PHP Dopustiti Pamćenje Veličina Exchausted Fatal Error










































July 26th, 2009 18:12 26. srpanj 2009 18:12
[...] [...] [...] [...]
December 21st, 2007 16:58 21 prosinac 2007 16:58
Great article. Velik članak.
Thanks for the WHM tip. Hvala za savjet WHM.
You saved my ass. Te prišteđen moj magarac.
December 3rd, 2007 16:21 3. prosinca 2007 16:21
[...] 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, hay un artículo muy interesante sobre este greška en Moj Koji se tiče prsta Život. Etiquetas: Desarrollo, hosting, open_basedir, [...] Etiquetas: Desarrollo, hosting, open_basedir, [...]