Visualizzazione risultati 1 fino 3 di 3

Discussione: Problemi con installazione Grav

  1. #1
    Guest

    Predefinito Problemi con installazione Grav

    Stavo provando a installare Grav sul mio sito Altervista e ho ricevuto il seguente messaggio di errore:

    Internal Server Error

    The server encountered an internal error or misconfiguration and was unable to complete your request.

    Please contact the server administrator, info@altervista.org and inform them of the time the error occurred, and anything you might have done that may have caused the error.

    More information about this error may be available in the server error log.

    Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

    Non riesco a capire cosa sia successo e come posso fare a risolverlo.

  2. #2
    darbula non è connesso AlterGuru 2500
    Data registrazione
    24-04-2011
    Messaggi
    2,896

    Predefinito

    Ciao ogni software possiede dei requisiti da soddisfare, accertati 1)Dal pannello altervista.
    2)Dal punto 1 (sezione gestione file) di usare almeno la versione php 5.6 attualmente apache non usa mod_ssl (usa un reverse proxy, CloudFlare)
    3)Dal punto 1 abilita il server to server se hai bisogno delle connessioni esterne.
    4)Dal punto 1 abilita CloudFlare e https
    5)Dal punto 1 (sezione database) abilita InnoDB.
    6)Abilita in ogni file htaccess il RewriteBase / (Devi togliere il # e lo spazio iniziale).
    7)Abilita in ogni file htaccess X-Forwarded-Proto (Devi togliere il # e lo spazio iniziale).
    8)Abilita in ogni file htaccess il RewriteRule dopo il punto 7 (Devi togliere il # e lo spazio iniziale).
    mod_rewrite non compare tra i moduli ma esiste.
    Bisogna vedere che controlli fa tale software, chiedi info anche al loro forum.
    Codice:
    <IfModule mod_rewrite.c>
    
    RewriteEngine On
    
    ## Begin RewriteBase
    # If you are getting 500 or 404 errors on subpages, you may have to uncomment the RewriteBase entry
    # You should change the '/' to your appropriate subfolder. For example if you have
    # your Grav install at the root of your site '/' should work, else it might be something
    # along the lines of: RewriteBase /<your_sub_folder>
    ##
    
    RewriteBase /
    
    ## End - RewriteBase
    
    ## Begin - X-Forwarded-Proto
    # In some hosted or load balanced environments, SSL negotiation happens upstream.
    # In order for Grav to recognize the connection as secure, you need to uncomment
    # the following lines.
    #
    RewriteCond %{HTTP:X-Forwarded-Proto} https
    RewriteRule .* - [E=HTTPS:on]
    #
    ## End - X-Forwarded-Proto
    
    ## Begin - Exploits
    # If you experience problems on your site block out the operations listed below
    # This attempts to block the most common type of exploit `attempts` to Grav
    #
    # Block out any script trying to base64_encode data within the URL.
    RewriteCond %{QUERY_STRING} base64_encode[^(]*\([^)]*\) [OR]
    # Block out any script that includes a <script> tag in URL.
    RewriteCond %{QUERY_STRING} (<|%3C)([^s]*s)+cript.*(>|%3E) [NC,OR]
    # Block out any script trying to set a PHP GLOBALS variable via URL.
    RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
    # Block out any script trying to modify a _REQUEST variable via URL.
    RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
    # Return 403 Forbidden header and show the content of the root homepage
    RewriteRule .* index.php [F]
    #
    ## End - Exploits
    
    ## Begin - Index
    # If the requested path and file is not /index.php and the request
    # has not already been internally rewritten to the index.php script
    RewriteCond %{REQUEST_URI} !^/index\.php
    # and the requested path and file doesn't directly match a physical file
    RewriteCond %{REQUEST_FILENAME} !-f
    # and the requested path and file doesn't directly match a physical folder
    RewriteCond %{REQUEST_FILENAME} !-d
    # internally rewrite the request to the index.php script
    RewriteRule .* index.php [L]
    ## End - Index
    
    ## Begin - Security
    # Block all direct access for these folders
    RewriteRule ^(\.git|cache|bin|logs|backup|webserver-configs|tests)/(.*) error [F]
    # Block access to specific file types for these system folders
    RewriteRule ^(system|vendor)/(.*)\.(txt|xml|md|html|yaml|yml|php|pl|py|cgi|twig|sh|bat)$ error [F]
    # Block access to specific file types for these user folders
    RewriteRule ^(user)/(.*)\.(txt|md|yaml|yml|php|pl|py|cgi|twig|sh|bat)$ error [F]
    # Block all direct access to .md files:
    RewriteRule \.md$ error [F]
    # Block all direct access to files and folders beginning with a dot
    RewriteRule (^|/)\.(?!well-known) - [F]
    # Block access to specific files in the root folder
    RewriteRule ^(LICENSE\.txt|composer\.lock|composer\.json|\.htaccess)$ error [F]
    ## End - Security
    
    </IfModule>
    
    # Begin - Prevent Browsing and Set Default Resources
    Options -Indexes
    DirectoryIndex index.php index.html index.htm
    # End - Prevent Browsing and Set Default Resources
    Requisiti
    Ultima modifica di darbula : 16-11-2018 alle ore 21.11.03

  3. #3
    Guest

    Predefinito

    Wow! Grazie: sembra funzionare, ora.

Regole di scrittura

  • Non puoi creare nuove discussioni
  • Non puoi rispondere ai messaggi
  • Non puoi inserire allegati.
  • Non puoi modificare i tuoi messaggi
  •