Posted: June 27, 2016 at 8:42 am
|
If using WP-Engine, you will NOT be able to use event espresso because they explicitly restrict sessions due to security vulnerabilities and state that you need to use javascript instead. EVENTESPRESSO TEAM: Please revise your code and make this more secure. Thank you. For now, I’ve purchased something that is completely useless to me due to the lack of security measures taken during development. Here’s their response to this issue: COOKIES AND PHP SESSIONS On this page: This article explains in-depth how PHP sessions and cookies work on the WP Engine platform. Cookies and PHP session variables are used by many plugins and themes for WordPress. Tags: cookies, php Updated: April 26th, 2016 Cookies and PHP $_SESSION variables are used by many plugins and themes for WordPress. While we don’t currently prevent cookies or sessions, they may not work as you expect on our servers. Caching WP Engine implements Page caching as a primary method of speeding up the sites that we host. Here’s a rough overview of how page caching works: Visitor 1 views your site. There are certain special cases, where caching is disabled. One such case is when the website visitor logs into WordPress. WordPress sets cookies related to that login, and our system is set up to recognize those WordPress login cookies. When those cookies are found and are valid, then page caching is disabled. Another special case where caching needs to be disabled is for eCommerce sites. Sections of the site, such as product pages, the cart, and the checkout page, need to be un-cached for all visitors. Because these settings can vary from site to site, we currently require you to open a 24/7 Live Chat, which you can do from within your User Portal. Cookies Cookies can still be used with page caching. However, they need to be handled predominantly with Javascript instead of PHP. If you try to use PHP to read cookies, it will likely only display an empty cookie array. This does not mean that you cannot use PHP at all with cookies. If you want to use PHP, then you will need to use Ajax to make requests to the server and run PHP code. WordPress has native support for Ajax functionality, and also makes that functionality extensible. For more information on using Ajax with WordPress, see the Codex entries for Ajax and Ajax in Plugins. PHP Sessions We do not currently recommend using $_SESSION variables at all. This is for a number of reasons: While WordPress itself supports the use of $_SESSION, WordPress is stateless and does not natively use $_SESSION. The proper way to work with WordPress is using cookies. |
Hi I’m Event Espresso’s Lead dev and would like to address your claim that our code is insecure. You are correct that PHP session variables and cookies are insecure… which is why we don’t use them! We do not use any Session variables other than the PHP Session ID itself which can NOT be changed or altered in any way. We then “salt” the Session ID and use that as a key for storing data in the database. An attacker can not access any of that info, unless of course they have access to your database, in which case, you are complete toast, because they have already bypassed all of your security via some other means. Caching only works for static content, meaning content that does NOT change, such as an “About Us” page. The server says “Oh you want the About US page? Well here’s a cached copy of that page instead of reprocessing that request.” eCommerce sites, which is what your site becomes when you start selling tickets via Event Espresso, are dynamic, meaning the content is constantly changing due to sales and orders etc. The reason you are getting the “Nothing in your Event Queue” error is because your customers are trying to submit an order, but the caching system on your server says “Oh, we already have a cached copy for the page that processes orders… let’s just return that instead of reprocessing this new order.” Hopefully you can see how that will not work. You can not serve a cached copy of an order that was already processed. So anyways, what happens is that the cached copy of a previous order does not match up with the key (the one created with your PHP Session ID) that is used for storing your data in database, and therefore it appears that there is nothing in the Event Queue because your “REAL” order was ignored by the server, so that it could bypass handling that request. Other Support staff can possibly point you to documentation regarding fixing the caching problem on your server, or help explain what needs to be done. Thank you. |
|
You can follow the documentation outlined here: https://eventespresso.com/wiki/setup-wpengine-hosting-event-espresso/ |
|
The support post ‘Cookies and Nothing in your Event Queue ERRORS during registration’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.