Problem with .htaccess

hosting

#1

Hello,

I would like owncloud install on my website. When I arrive on page when i make au usernam, passeword and Msql don't work. I have a 500 error. I have look the log_erreur and fund that: [Thu
Sep 15 14:00:36.341433 2016] [core:alert] [pid 8295] [client
84.74.17.146:56648]
/home/sites/hebfree.org/aux-naturelles/public_html/webshare/.htaccess:
php_value not allowed here.

but I don't change de php_value and my host not want change because security.

So, what can I do in my .htaccess to work ?

Thank's for your help and excuse me for my english.


#2

Hi,

this gives you some pointers:

You need to remove all php_value from the .htaccess file. However you should note that it is not guaranteed that ownCloud will run on such a shared hoster with that limitations.

In general you should also check if running a cloud software like ownCloud on your website is compliant with the policies of your hoster.


#3

Hello,

I have remouve the php_value but I have always the 500 error code. You can see my code under.

<IfModule mod_headers.c>
  <IfModule mod_setenvif.c>
    <IfModule mod_fcgid.c>
       SetEnvIfNoCase ^Authorization$ "(.+)" XAUTHORIZATION=$1
       RequestHeader set XAuthorization %{XAUTHORIZATION}e env=XAUTHORIZATION
    </IfModule>
    <IfModule mod_proxy_fcgi.c>
       SetEnvIfNoCase Authorization "(.+)" HTTP_AUTHORIZATION=$1
    </IfModule>
  </IfModule>

  <IfModule mod_env.c>
    # Add security and privacy related headers
    Header set X-Content-Type-Options "nosniff"
    Header set X-XSS-Protection "1; mode=block"
    Header set X-Robots-Tag "none"
    Header set X-Frame-Options "SAMEORIGIN"
    Header set X-Download-Options "noopen"
    Header set X-Permitted-Cross-Domain-Policies "none"
    SetEnv modHeadersAvailable true
  </IfModule>

  # Add cache control for CSS and JS files
  <FilesMatch "\.(css|js)$">
    Header set Cache-Control "max-age=7200, public"
  </FilesMatch> 
  <IfModule mod_env.c>
    SetEnv htaccessWorking true
  </IfModule>
  <IfModule mod_env.c>
    SetEnv htaccessWorking true
  </IfModule>
</IfModule>
<IfModule mod_rewrite.c>
  RewriteEngine on
  RewriteRule .* - [env=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
  RewriteRule ^\.well-known/host-meta /public.php?service=host-meta [QSA,L]
  RewriteRule ^\.well-known/host-meta\.json /public.php?service=host-meta-json [QSA,L]
  RewriteRule ^\.well-known/carddav /remote.php/dav/ [R=301,L]
  RewriteRule ^\.well-known/caldav /remote.php/dav/ [R=301,L]
  RewriteRule ^remote/(.*) remote.php [QSA,L]
  RewriteRule ^(?:build|tests|config|lib|3rdparty|templates)/.* - [R=404,L]
  RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge/.*
  RewriteRule ^(?:\.|autotest|occ|issue|indie|db_|console).* - [R=404,L]
</IfModule>
<IfModule mod_mime.c>
  AddType image/svg+xml svg svgz
  AddEncoding gzip svgz
</IfModule>
<IfModule mod_dir.c>
  DirectoryIndex index.php index.html
</IfModule>
AddDefaultCharset utf-8
Options -Indexes
<IfModule pagespeed_module>
  ModPagespeed Off
</IfModule>

Can I try to code in UTF-8 the file or juste to remouve the nomber for exemple 513M ? It's possible to have a problème in the htaccess ?


#4

Then check your logfiles again. They are showing you any other issues.


#5

In my log I have this error:

Fri Sep 16 21:43:05.177807 2016] [core:alert] [pid 19935] [client 84.74.249.229:57999] /home/sites/hebfree.org/aux-naturelles/public_html/webshare/.htaccess: DirectoryIndex not allowed here
[Fri Sep 16 22:27:44.291469 2016] [core:alert] [pid 15869] [client 84.74.249.229:59713] /home/sites/hebfree.org/aux-naturelles/public_html/webshare/.htaccess: php_value not allowed here, referer: http://webshare.aux-naturelles.ch/setup-owncloud.php?step=2&directory=.
[Fri Sep 16 22:40:13.476549 2016] [core:alert] [pid 22615] [client 84.74.249.229:59838] /home/sites/hebfree.org/aux-naturelles/public_html/webshare/.htaccess: php_value not allowed here, referer: http://webshare.aux-naturelles.ch/

and for in log I have this error:
84.74.249.229 - - [16/Sep/2016:22:39:32 +0200] "GET /core/fonts/OpenSans-Regular.woff HTTP/1.1" 200 20544
84.74.249.229 - - [16/Sep/2016:22:39:32 +0200] "GET /core/fonts/OpenSans-Semibold.woff HTTP/1.1" 200 69888
84.74.249.229 - - [16/Sep/2016:22:39:32 +0200] "GET /core/fonts/OpenSans-Light.woff HTTP/1.1" 200 62844
84.74.249.229 - - [16/Sep/2016:22:39:32 +0200] "GET /core/img/background.jpg HTTP/1.1" 200 133536
84.74.249.229 - - [16/Sep/2016:22:39:32 +0200] "GET /core/img/breadcrumb.svg HTTP/1.1" 200 455
84.74.249.229 - - [16/Sep/2016:22:39:32 +0200] "GET /core/vendor/zxcvbn/zxcvbn.js HTTP/1.1" 200 329737
84.74.249.229 - - [16/Sep/2016:22:40:13 +0200] "GET /index.php HTTP/1.1" 500 531


#6

Remove all DirectoryIndex and php_value from the .htaccess file (see the hint already posted above).


#7

Hello

I have removed all DirectoryIndex and php_value but it doesn't work.:sweat:

Are you a other solution or can sand by mail my htaccess.

For your information, I manage a other website in a other host and it's work.


#8

Then this is valid again: