Skip to content

Instantly share code, notes, and snippets.

View pstoute's full-sized avatar

Paul Stoute pstoute

View GitHub Profile
@pstoute
pstoute / wpumbrella-http-context.conf
Created November 17, 2023 21:01
This is the http context file that you need to add to whitelist the IP addresses for WP-Umbrella
geo $wpumbrella_ips {
default 0;
2001:41d0:306:1702::/64 1;
141.95.192.2 1;
}
@pstoute
pstoute / mysql-script.txt
Created September 29, 2023 18:28
How to get the size of each database in your MySQL install in GB
SELECT table_schema "DB Name",
ROUND(SUM(data_length + index_length) / 1024 / 1024 / 1024, 1) "DB Size in GB"
FROM information_schema.tables
GROUP BY table_schema;
@pstoute
pstoute / fortress-ebridge-jitterbit-overrides_APAC-region.php
Created July 18, 2023 15:29
Add this to your /wp-content/mu-plugins/ directory to allow the eBridge or JitterBit connections to your Fortress Secured WordPress site.
<?php
/**
* Plugin Name: GridPane Fortress - Overrrides for eBridge/JitterBit connections | APAC Region
* Description: Companion plugin to the Fortress Security module to whitelist eBridge/JitterBit connections.
* Author: Stoute Web Solutions
* Author URI: https://stoutewebsolutions.com
* Version: 1.0
*/
// This is a replication of the original whitelisted module for ManageWP found here: https://github.com/snicco/fortress/blob/beta/docs/modules/session/sudo-mode.md#skipping-the-sudo-mode-check-for-request-from-managewp
@pstoute
pstoute / fortress-ebridge-jitterbit-overrides_EMEA-region.php
Last active July 18, 2023 15:22
Add this to your /wp-content/mu-plugins/ directory to allow the eBridge or JitterBit connections to your Fortress Secured WordPress site.
<?php
/**
* Plugin Name: GridPane Fortress - Overrrides for eBridge/JitterBit connections | EMEA Region
* Description: Companion plugin to the Fortress Security module to whitelist eBridge/JitterBit connections.
* Author: Stoute Web Solutions
* Author URI: https://stoutewebsolutions.com
* Version: 1.0
*/
// This is a replication of the original whitelisted module for ManageWP found here: https://github.com/snicco/fortress/blob/beta/docs/modules/session/sudo-mode.md#skipping-the-sudo-mode-check-for-request-from-managewp
@pstoute
pstoute / fortress-ebridge-jitterbit-overrides_NA-region.php
Last active July 18, 2023 15:23
Add this to your /wp-content/mu-plugins/ directory to allow the eBridge or JitterBit connections to your Fortress Secured WordPress site.
<?php
/**
* Plugin Name: GridPane Fortress - Overrrides for eBridge/JitterBit connections | NA Region
* Description: Companion plugin to the Fortress Security module to whitelist eBridge/JitterBit connections.
* Author: Stoute Web Solutions
* Author URI: https://stoutewebsolutions.com
* Version: 1.0
*/
// This is a replication of the original whitelisted module for ManageWP found here: https://github.com/snicco/fortress/blob/beta/docs/modules/session/sudo-mode.md#skipping-the-sudo-mode-check-for-request-from-managewp
@pstoute
pstoute / fortress-aws-alloy-override.php
Last active July 17, 2023 19:06
Use this plugin as a must use plugin for any Fortress secured site where you are using AWS Alloy to manage your connections with Amazon Buy with Prime buttons.
<?php
/**
* Plugin Name: GridPane Fortress - Skip the check for a session being in sudo-mode for AWS Alloy connections.
* Description: Companion plugin to the Fortress Security module to whitelist AWS Alloy connections.
* Author: Stoute Web Solutions
* Author URI: https://stoutewebsolutions.com
* Version: 1.0
*/
@pstoute
pstoute / fortress-uabb-gf-override.php
Created June 28, 2023 20:01
This must use plugin gets added to the /wp-content/mu-plugins directory and requires no configuration to allow the fortress 2fa pages to display all by setting the gravity forms force hooks js output to false on pages including /snicco-fortress
<?php
/**
* Plugin Name: GridPane Fortress - UABB Gravity Forms Styler Override
* Description: This must use plugin overrides the Ultimate Addons forced filter to return false on fortress related pages.
* Version: 1.0
* Author: Stoute Web Solutions
* Author URI: https://stoutewebsolutions.com/
* Plugin URI: https://community.gridpane.com/t/ultimate-addons-for-beaver-builder-breaks-fortress-2fa-page-third-party/3333/80
*/
@pstoute
pstoute / fortress-logging.php
Last active June 18, 2023 15:02
Enable logging for Fortress by Snicco. This has not been tested on any hosting environment other than GridPane.
<?php
/**
* Plugin Name: Fortress Logging - Only activate when actively troubleshooting
* Description: Enables a logging of the response event (other actions need to be made in order to have this work since fortress does not expose the response by default.
* Version: 0.0.1
*/
use Snicco\Bundle\HttpRouting\Event\ResponseSent;
add_action(ResponseSent::class, function (ResponseSent $event) {
@pstoute
pstoute / mu-stop-update-emails.php
Last active June 8, 2023 17:38
This snippet is used to prevent the emails that are sent when things are auto updated within WordPress
<?php
/**
* Disable Auto Update Emails
*
* Plugin Name: Disable Auto Update Emails
* Description: Disable the emails that are sent when plugins, themes, and WP Core are auto updated.
* Version: 0.1.0
* Author: Paul Stoute
* Author URI: https://stoute.co
* License: GPL-2.0+
@pstoute
pstoute / fortress-celigo-whitelist.php
Last active June 6, 2023 14:39
Fortress whitelist for Celigo connector IPs
<?php
/**
* Plugin Name: GridPane Fortress - Skip the check for a session being in sudo-mode for Celigo connections.
* Description: Companion plugin to the Fortress Security module to whitelist Celigo connections.
* Author: Company
*
* Version: 1.0',
' */
// This is a replication of the original whitelisted module for ManageWP found here: https://github.com/snicco/fortress/blob/beta/docs/modules/session/sudo-mode.md#skipping-the-sudo-mode-check-for-request-from-managewp