Title: Nginx compatibility
Last modified: September 1, 2016

---

# Nginx compatibility

 *  Resolved [anfieldleung](https://wordpress.org/support/users/anfieldleung/)
 * (@anfieldleung)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/)
 * Hi,
 * Is it WP Cassify not compatible with Nginx? I got “CAS Authentication failed !”
   or “page not found” error in my WP multisite under Nginx. The credential is correct
   and it passed CAS, the error show on a redirected page like [http://domain.com/ticket=xxxxxxxxxxxx-cas](http://domain.com/ticket=xxxxxxxxxxxx-cas).
   
   It works fine in my WP multisite on apache of another network site.
 * [https://wordpress.org/plugins/wp-cassify/](https://wordpress.org/plugins/wp-cassify/)

Viewing 10 replies - 1 through 10 (of 10 total)

 *  Plugin Author [Alain-Aymerick FRANCOIS](https://wordpress.org/support/users/aaf017/)
 * (@aaf017)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568405)
 * Hi,
 * I’m not competent on WP with Nginx. But, i think it may be a rewrite rule problem.
   In your example, question mark is missing in url before ticket get parameter :“
   [http://domain.com/ticket=xxxxxxxxxxxx-cas&#8221](http://domain.com/ticket=xxxxxxxxxxxx-cas&#8221);.
 * It should be like this :
 * “[http://domain.com/?ticket=xxxxxxxxxxxx-cas&#8221](http://domain.com/?ticket=xxxxxxxxxxxx-cas&#8221);.
 * Best regards.
 *  Thread Starter [anfieldleung](https://wordpress.org/support/users/anfieldleung/)
 * (@anfieldleung)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568407)
 * Sorry there is a “?” in front of the ticket. I just deleted the “?” by mistake
   when modifying the URL before sent
 * It is “[http://domain.com/?ticket=xxxxxxxxxxxx-cas&#8221](http://domain.com/?ticket=xxxxxxxxxxxx-cas&#8221);
 *  Thread Starter [anfieldleung](https://wordpress.org/support/users/anfieldleung/)
 * (@anfieldleung)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568409)
 * I found this error message in log
 *     ```
       5843#5843: *167 FastCGI sent in stderr: "PHP message: PHP Warning:  DOMDocument::loadXML(): Space required after the Public Identifier in Entity, line: 1 in /home/<WP server path>/wp_cassify_plugin.php on line 820
       ```
   
 *  Plugin Author [Alain-Aymerick FRANCOIS](https://wordpress.org/support/users/aaf017/)
 * (@aaf017)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568410)
 * There is a problem with CAS Server xml response.
 * You can try to enable “dump last xml cas server response” option in debug settings.
 * Then you try to connect. After that, close browser and re-auth with local admin
   wordpress account. In WP Cassify debug settings, you can show the last xml cas
   server response in textarea.
 *  Plugin Author [Alain-Aymerick FRANCOIS](https://wordpress.org/support/users/aaf017/)
 * (@aaf017)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568413)
 * You can also try this.
 * In your wp-config.php :
 * @ini_set(‘display_errors’,’Off’);
    @ini_set(‘log_errors’,’On’); // (Adapt path
   to your config) @ini_set(‘error_log’,’/var/www/your-website/phperrors.log’);
 * In file classes/wp_cassify_plugin.php, at line 346, write this :
    error_log( 
   print_r( $cas_server_xml_response, TRUE ) );
 * Try to connect and then send me phperrors.log content.
 *  Thread Starter [anfieldleung](https://wordpress.org/support/users/anfieldleung/)
 * (@anfieldleung)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568424)
 * Here you are
 *     ```
       <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
       <html><head>
       <title>302 Found</title>
       </head><body>
       <h1>Found</h1>
       <p>The document has moved <a href="https://[my cas]/serviceValidate?ticket=ST-1245-ZfdSOdgBHOsMDbw1ZnA1-cas&service=http://[my WP]/wp-admin/">here</a>.</p>
       </body></html>
       ```
   
 *  Plugin Author [Alain-Aymerick FRANCOIS](https://wordpress.org/support/users/aaf017/)
 * (@aaf017)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568432)
 * Hi,
 * Now, you’ve the answer. WordPress platform can’t join CAS Server to validate 
   the ticket.
 * Is it the same machine wich host wordpress blog and CAS server ?
 * What’s configuration of your CAS Server (Tomcat behind Apache or NGINX, or Tomcat
   only in front) ? Have you enable something like Apache Mod Security ?
 * I don’t know why your CAS Server make 302 redirect when WordPress try to join
   him.
 * From my point of view, it seems to be a network problem with your specific configuration
   not a plugin bug.
 * Best regards
 *  Thread Starter [anfieldleung](https://wordpress.org/support/users/anfieldleung/)
 * (@anfieldleung)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568434)
 * Hi,
 * The CAS is Tomcat behind Apache and we didn’t enable Apache Mod Security.
    The
   CAS is working fine with WP on Apache. So I think there is something to config
   in Nignx, do you have any suggestion how to do the configuration on Nginx?
 *  Plugin Author [Alain-Aymerick FRANCOIS](https://wordpress.org/support/users/aaf017/)
 * (@aaf017)
 * [10 years ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568438)
 * Unfortunately, i use only Apache config in my job. I’m not an Nginx Expert.
 * So, Have you tried to make a wget on CAS home url from your WordPress host ?
 * If you have also 302 redirect, i’m not sure but it may be have some problem with
   your Nginx configuration.
 * It’s possible to see your nginx configuration file ?
 * See that :[http://serverfault.com/questions/612690/tomcat7-nginx-ssl-causes-redirect-loop](http://serverfault.com/questions/612690/tomcat7-nginx-ssl-causes-redirect-loop)
 * Best regards.
 *  Thread Starter [anfieldleung](https://wordpress.org/support/users/anfieldleung/)
 * (@anfieldleung)
 * [9 years, 12 months ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568481)
 * It looks like our proxy or DNS cached. It is working now without any changes.
   
   Thanks.

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘Nginx compatibility’ is closed to new replies.

 * ![](https://ps.w.org/wp-cassify/assets/icon-256x256.png?rev=3112582)
 * [WP Cassify](https://wordpress.org/plugins/wp-cassify/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-cassify/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-cassify/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-cassify/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-cassify/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-cassify/reviews/)

## Tags

 * [compatibility](https://wordpress.org/support/topic-tag/compatibility/)
 * [nginx](https://wordpress.org/support/topic-tag/nginx/)

 * 10 replies
 * 2 participants
 * Last reply from: [anfieldleung](https://wordpress.org/support/users/anfieldleung/)
 * Last activity: [9 years, 12 months ago](https://wordpress.org/support/topic/nginx-compatibility-3/#post-7568481)
 * Status: resolved