]> TLD Linux GIT Repositories - packages/php.git/blob - php-ini.patch
- TLDized
[packages/php.git] / php-ini.patch
1 diff -ur php-5.6.0.orig/php.ini php-5.6.0/php.ini
2 --- php-5.6.0.orig/php.ini      2014-08-27 13:31:35.000000000 +0000
3 +++ php-5.6.0/php.ini   2014-09-15 08:41:06.585000000 +0000
4 @@ -82,6 +82,20 @@
5  ; much more verbose when it comes to errors. We recommend using the
6  ; development version only in development environments, as errors shown to
7  ; application users can inadvertently leak otherwise secure information.
8 +;
9 +; This is the default settings file for new PHP installations from
10 +; TLD Linux.
11 +;
12 +; It's based mainly on php.ini-production, but with some changes made with
13 +; security in mind (see below, consult also http://php.net/manual/en/security.php).
14 +;
15 +; Please note, that in TLD installations /etc/php/php.ini file
16 +; contains global settings for all SAPIs (cgi, cli, apache...),
17 +; and after reading this file, SAPI-specific file (/etc/php/php-cgi-fcgi.ini,
18 +; /etc/php/php-cli.ini, /etc/php/php-apache.ini...) is INCLUDED
19 +; (so you don't have to duplicate whole large file to override only
20 +; few options)
21 +
22  
23  ; This is php.ini-production INI file.
24  
25 @@ -149,7 +163,7 @@
26  ;   Production Value: 5
27  
28  ; short_open_tag
29 -;   Default Value: On
30 +;   Default Value: Off
31  ;   Development Value: Off
32  ;   Production Value: Off
33  
34 @@ -175,7 +189,7 @@
35  ;user_ini.filename = ".user.ini"
36  
37  ; To disable this feature set this option to empty value
38 -;user_ini.filename =
39 +user_ini.filename =
40  
41  ; TTL for user-defined php.ini files (time-to-live) in seconds. Default is 300 seconds (5 minutes)
42  ;user_ini.cache_ttl = 300
43 @@ -195,7 +209,7 @@
44  ; documents, however this remains supported for backward compatibility reasons.
45  ; Note that this directive does not control the <?= shorthand tag, which can be
46  ; used regardless of this directive.
47 -; Default Value: On
48 +; Default Value: Off
49  ; Development Value: Off
50  ; Production Value: Off
51  ; http://php.net/short-open-tag
52 @@ -363,7 +377,7 @@
53  ; threat in any way, but it makes it possible to determine whether you use PHP
54  ; on your server or not.
55  ; http://php.net/expose-php
56 -expose_php = On
57 +expose_php = Off
58  
59  ;;;;;;;;;;;;;;;;;;;
60  ; Resource Limits ;
61 @@ -732,7 +746,7 @@
62  
63  ; Directory in which the loadable extensions (modules) reside.
64  ; http://php.net/extension-dir
65 -; extension_dir = "./"
66 +;extension_dir = "/usr/lib/php"
67  ; On windows:
68  ; extension_dir = "ext"
69  
70 @@ -746,53 +760,6 @@
71  ; http://php.net/enable-dl
72  enable_dl = Off
73  
74 -; cgi.force_redirect is necessary to provide security running PHP as a CGI under
75 -; most web servers.  Left undefined, PHP turns this on by default.  You can
76 -; turn it off here AT YOUR OWN RISK
77 -; **You CAN safely turn this off for IIS, in fact, you MUST.**
78 -; http://php.net/cgi.force-redirect
79 -;cgi.force_redirect = 1
80 -
81 -; if cgi.nph is enabled it will force cgi to always sent Status: 200 with
82 -; every request. PHP's default behavior is to disable this feature.
83 -;cgi.nph = 1
84 -
85 -; if cgi.force_redirect is turned on, and you are not running under Apache or Netscape
86 -; (iPlanet) web servers, you MAY need to set an environment variable name that PHP
87 -; will look for to know it is OK to continue execution.  Setting this variable MAY
88 -; cause security issues, KNOW WHAT YOU ARE DOING FIRST.
89 -; http://php.net/cgi.redirect-status-env
90 -;cgi.redirect_status_env =
91 -
92 -; cgi.fix_pathinfo provides *real* PATH_INFO/PATH_TRANSLATED support for CGI.  PHP's
93 -; previous behaviour was to set PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok
94 -; what PATH_INFO is.  For more information on PATH_INFO, see the cgi specs.  Setting
95 -; this to 1 will cause PHP CGI to fix its paths to conform to the spec.  A setting
96 -; of zero causes PHP to behave as before.  Default is 1.  You should fix your scripts
97 -; to use SCRIPT_FILENAME rather than PATH_TRANSLATED.
98 -; http://php.net/cgi.fix-pathinfo
99 -;cgi.fix_pathinfo=1
100 -
101 -; FastCGI under IIS (on WINNT based OS) supports the ability to impersonate
102 -; security tokens of the calling client.  This allows IIS to define the
103 -; security context that the request runs under.  mod_fastcgi under Apache
104 -; does not currently support this feature (03/17/2002)
105 -; Set to 1 if running under IIS.  Default is zero.
106 -; http://php.net/fastcgi.impersonate
107 -;fastcgi.impersonate = 1
108 -
109 -; Disable logging through FastCGI connection. PHP's default behavior is to enable
110 -; this feature.
111 -;fastcgi.logging = 0
112 -
113 -; cgi.rfc2616_headers configuration option tells PHP what type of headers to
114 -; use when sending HTTP response code. If set to 0, PHP sends Status: header that
115 -; is supported by Apache. When this option is set to 1, PHP will send
116 -; RFC2616 compliant header.
117 -; Default is zero.
118 -; http://php.net/cgi.rfc2616-headers
119 -;cgi.rfc2616_headers = 0
120 -
121  ;;;;;;;;;;;;;;;;
122  ; File Uploads ;
123  ;;;;;;;;;;;;;;;;
124 @@ -870,49 +837,8 @@
125  ; If you only provide the name of the extension, PHP will look for it in its
126  ; default extension directory.
127  ;
128 -; Windows Extensions
129 -; Note that ODBC support is built in, so no dll is needed for it.
130 -; Note that many DLL files are located in the extensions/ (PHP 4) ext/ (PHP 5)
131 -; extension folders as well as the separate PECL DLL download (PHP 5).
132 -; Be sure to appropriately set the extension_dir directive.
133 -;
134 -;extension=php_bz2.dll
135 -;extension=php_curl.dll
136 -;extension=php_fileinfo.dll
137 -;extension=php_gd2.dll
138 -;extension=php_gettext.dll
139 -;extension=php_gmp.dll
140 -;extension=php_intl.dll
141 -;extension=php_imap.dll
142 -;extension=php_interbase.dll
143 -;extension=php_ldap.dll
144 -;extension=php_mbstring.dll
145 -;extension=php_exif.dll      ; Must be after mbstring as it depends on it
146 -;extension=php_mysql.dll
147 -;extension=php_mysqli.dll
148 -;extension=php_oci8_12c.dll  ; Use with Oracle Database 12c Instant Client
149 -;extension=php_openssl.dll
150 -;extension=php_pdo_firebird.dll
151 -;extension=php_pdo_mysql.dll
152 -;extension=php_pdo_oci.dll
153 -;extension=php_pdo_odbc.dll
154 -;extension=php_pdo_pgsql.dll
155 -;extension=php_pdo_sqlite.dll
156 -;extension=php_pgsql.dll
157 -;extension=php_pspell.dll
158 -;extension=php_shmop.dll
159 -
160 -; The MIBS data available in the PHP distribution must be installed. 
161 -; See http://www.php.net/manual/en/snmp.installation.php 
162 -;extension=php_snmp.dll
163 -
164 -;extension=php_soap.dll
165 -;extension=php_sockets.dll
166 -;extension=php_sqlite3.dll
167 -;extension=php_sybase_ct.dll
168 -;extension=php_tidy.dll
169 -;extension=php_xmlrpc.dll
170 -;extension=php_xsl.dll
171 +; Ideally in TLD Linux you should install appropriate php-<extension> or
172 +; php-pecl-<extension> package.
173  
174  ;;;;;;;;;;;;;;;;;;;
175  ; Module Settings ;
176 @@ -950,19 +876,19 @@
177  ; Use of this INI entry is deprecated, use global input_encoding instead.
178  ; If empty, default_charset or input_encoding or iconv.input_encoding is used.
179  ; The precedence is: default_charset < intput_encoding < iconv.input_encoding
180 -;iconv.input_encoding =
181 +iconv.input_encoding = UTF-8
182  
183  ; Use of this INI entry is deprecated, use global internal_encoding instead.
184  ; If empty, default_charset or internal_encoding or iconv.internal_encoding is used.
185  ; The precedence is: default_charset < internal_encoding < iconv.internal_encoding
186 -;iconv.internal_encoding =
187 +iconv.internal_encoding = UTF-8
188  
189  ; Use of this INI entry is deprecated, use global output_encoding instead.
190  ; If empty, default_charset or output_encoding or iconv.output_encoding is used.
191  ; The precedence is: default_charset < output_encoding < iconv.output_encoding
192  ; To use an output encoding conversion, iconv's output handler must be set
193  ; otherwise output encoding conversion cannot be performed.
194 -;iconv.output_encoding =
195 +iconv.output_encoding = UTF-8
196  
197  [intl]
198  ;intl.default_locale =
199 @@ -1176,6 +1102,9 @@
200  ; http://php.net/mysql.connect-timeout
201  mysql.connect_timeout = 60
202  
203 +; The name of the character set to use as the default character set.
204 +;mysql.connect_charset=utf8
205 +
206  ; Trace mode. When trace_mode is active (=On), warnings for table/index scans and
207  ; SQL-Errors will be displayed.
208  ; http://php.net/mysql.trace-mode
209 @@ -1215,6 +1144,9 @@
210  ; http://php.net/mysqli.default-socket
211  mysqli.default_socket =
212  
213 +; The name of the character set to use as the default character set.
214 +;mysqli.connect_charset=utf8
215 +
216  ; Default host for mysql_connect() (doesn't apply in safe mode).
217  ; http://php.net/mysqli.default-host
218  mysqli.default_host =
219 @@ -1381,7 +1313,7 @@
220  
221  [browscap]
222  ; http://php.net/browscap
223 -;browscap = extra/browscap.ini
224 +browscap = /etc/php/browscap.ini
225  
226  [Session]
227  ; Handler used to store/retrieve data.
228 @@ -1841,7 +1773,7 @@
229  
230  ; Sets the directory name where SOAP extension will put cache files.
231  ; http://php.net/soap.wsdl-cache-dir
232 -soap.wsdl_cache_dir="/tmp"
233 +soap.wsdl_cache_dir="/var/cache/php"
234  
235  ; (time to live) Sets the number of second while cached file will be used
236  ; instead of original one.