Announcement

Collapse
No announcement yet.

Archive is not working - fast-CGI (Nginx + PHP-FPM)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Archive is not working - fast-CGI (Nginx + PHP-FPM)

    Hello my forum is working in fast-cgi mode (nginx and php-fpm). Please tell me how to make forum archive working on this setup without param cgi.fix_pathinfo set to 1 because it makes the site vulnerable (detail description http://cnedelcu.blogspot.ru/2010/05/nginx-php-via-fastcgi-important.html ) and I have already got many malware on my forum because of this and it takes a lot of time to determine how I got hacked and now with this param set to 0 I always got error (no input file specified) when trying to open any url of archive where rewrite is needed. So I need correct config for nginx and php-fpm. Please help me.

  • #2
    It most likely won't work. It was designed to work with Apache. With today's modern search engines, the Archive doesn't provide much benefit. When it was created ten years ago, search engines weren't as intelligent.
    Translations provided by Google.

    Wayne Luke
    The Rabid Badger - a vBulletin Cloud demonstration site.
    vBulletin 5 API - Full / Mobile
    Vote for your favorite feature requests and the bugs you want to see fixed.

    Comment


    • #3
      It works just fine, add these rewrite rules to your vhost.conf file, add above your fastcgi block

      Code:
              location /archive {
                      rewrite ^/archive/index.php/t-([0-9]+)\.html /archive/index.php?t-$1.html last;
                      rewrite ^/archive/index.php/f-([0-9]+)\.html /archive/index.php?f-$1.html last;
              }
      Gentoo Geek

      Comment


      • #4
        This code have working page navigation in archive:
        Code:
                location /archive {
                        rewrite ^/archive/index.php/t-([0-9]+)\.html /archive/index.php?t-$1.html last;
                        rewrite ^/archive/index.php/f-([0-9]+)\.html /archive/index.php?f-$1.html last;
                        rewrite ^/archive/index.php/t-([0-9]+)-p-([0-9]+)\.html /archive/index.php?t-$1-p-$2.html last;
                        rewrite ^/archive/index.php/f-([0-9]+)-p-([0-9]+)\.html /archive/index.php?f-$1-p-$2.html last;
                }

        Comment

        widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
        Working...
        X