[DigitalPoint] App for Cloudflare®

[DigitalPoint] App for Cloudflare® 1.5.6

No permission to download
IMPORTANT for existing users: A change to Crawler Hint API calls requires a new API permission to be able to set it. You can go to your Cloudflare API Tokens, edit the token you have and add the following permissions:
  • Zone.Zone: Edit
You should have a total of 15 permissions for your API token at this point. If you don't have 15, you can check what you should have under XF Admin -> Options -> External service providers -> Cloudflare authentication
  • Fix for change to Crawler Hint API calls (needed to change Crawler Hints setting)
  • Updated parameters for Network error logging when doing "Easy config"
  • Normalize path when getting a list of multiple objects
  • Add support for getting listings of directories inside buckets in R2 adapter (a little tricky because R2 it not a file system in the traditional sense as there are no actual directories). Should make it so exporting styles with attached assets should work if those assets are stored in R2.
Hate pushing quick versions out (sorry)... but a necessary fix for media uploads which are handled slightly differently than other uploaded content (like avatars and attachments).
Not sure why this is the case, but it seems XenForo's class autoloading system works slightly differently when in the context of auto-run jobs (within job.php). Oddly, changing the order of PHP classes within 3 files seems to have solved it (and allows the autoloader to properly "see" the classes either way).


Fixes a problem where a class couldn't be found if it was running as a cron job (a scheduled task to delete a firewall)
  • Like
Reactions: thumped
  • Added "Easy config" button to settings page to automatically optimize some settings for XenForo (currently it sets 22 Cloudflare settings in one go that work well for XenForo)
  • Don't use getContentUrl() method since it's only in XenForo 2.2
  • Force path and type keys when getting Metadata via R2 API
  • Better handling of non-existent R2 objects trying to be read by internal processes (throw FileNotFoundException)
  • Don't assume R2 bucket still exists when getting usage stats for buckets (in case someone deleted the bucket they are currently using)
  • Fixed issue when trying to configure R2 for the first time, but Cloudflare account does not have R2 enabled yet
  • Added sanity check for external data URL option in case addon somehow got partially (but not fully) installed
  • If using guest page caching and purge cache API call fails when a new post is created, edited or deleted, fail silently
  • Automatically remove cached account ID if it's invalid (Cloudflare account changed for site)
  • Don't assume template method is callable (fixes issue where XenForo addon installation process would give a temporary error when template modifications were enabled but class extensions are not yet)
Fixed issue with method compatibility on some versions of PHP
  • Fixed issue where the "Registration & contact forms are an overlay" option wouldn't always work
  • Fixed issue with guest page caching where the first request made after a browser restart would return a cached page vs. logged in user
  • Added support for config of R2 for XFMG via UI (it was possible before, but only through config.php edit)
  • Internally caching Cloudflare zone ID (less API requests needed and faster for the requests we are making)
  • Automatically reset cached zone ID cache if it's invalid (if site's domain changes for example)
  • If using guest page caching, the cache for the first 2 and last 2 pages in a thread is purged when a post in the thread is added, edited or deleted (doing first 2 and last 2 helps with threads that have hundreds or thousands of pages so they don't run into API problems with so many individual page purge requests)
  • Fixed issue with creating new admin access policies (change to Cloudflare API required an API parameter update)
  • Removed usage/dependency on Stripe's UUID generator
  • Fixed issue with country blocking firewall rule where sometimes the first country selected wouldn't show as selected when going back to edit
  • Fixed issue where the function to add public subdomain and Cache Rule to an existing R2 bucket wouldn't work
  • Removed dependency on third-party library to get list of countries for firewall blocking
  • Changed how guest page caching updates tokens in GET request URLs
  • Only cache guest pages if the visitor is using the default language and style
  • More tuning of logic for when to do guest page caching
  • Made change so other addons that are also extending the filesystem mount class are able to do so with backward compatibility
  • Fixed cosmetic issue with overflow of R2 logs in overlay window
  • Prevent users from using the same bucket for public and private areas (prevent users from exposing internal-data as a public bucket)
  • Added note about style, language and advanced cookie consent in XF 2.2.12+ to known limitations for guest page caching
  • Made some minor changes to the logic of when to serve cached pages or not (Guest page caching)
  • If a session is empty (like when a user logs out), go ahead and fully expunge it
  • Made some changes to R2 adapter so it could be configured for extra directories via config.php
  • Added some code to work around XenForo not updating CSRF token in URLs (this bug report)