WP Manifestindependent plugin directory
manifest / updates / custom-update-request-modifier

Custom Update Request Modifier WP Registry grade A. No security issues foundWP RegistryNo security issues foundOpen the reportA

Modifies the user-agent string in HTTP requests for theme, plugin, core, and other WordPress API requests. Allows custom API URL configuration, logs request details including headers and body, and excludes non-WordPress.org plugins from update checks.

★ 11stars
15release downloads
1.0.1latest · 1 year ago

Install

Download custom-update-request-modifier.zip From the 1.0.1 release on GitHub, Feb 4, 2025

Upload it under Plugins → Add New Plugin → Upload Plugin, then activate.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/robertdevore/custom-update-request-modifier/releases/download/1.0.1/custom-update-request-modifier.zip
Updates itself. It ships its own updater (Plugin Update Checker), so new versions appear under Dashboard → Updates.

This free plugin for WordPress® modifies HTTP request user-agent strings for themes, plugins, core updates, and other WordPress API requests.

It offers custom API URL configuration, logs request details including headers and body, and excludes plugins and themes with a custom Update URI in their headers from update checks.

Features

  • Modify user-agent strings for specific HTTP requests to replace the site URL with WordPress.org.
  • Configure custom API URLs for monitoring HTTP requests.
  • Log request headers, body, and response status codes in a custom database table.
  • Exclude plugins and themes with a specified Update URI header from update checks.
  • Supports separate update checks for plugins and themes.

Installation

  1. Clone or download the plugin to your wp-content/plugins directory.
  2. Activate the plugin through the WordPress admin dashboard under Plugins.
  3. Upon activation, the plugin creates a custom logging table in the database for tracking requests and schedules daily log clearing.

Usage

Request Modification

Once activated, the plugin intercepts HTTP requests to specific WordPress API endpoints and modifies the user-agent header by replacing the site's URL with wordpress.org. This modified header allows certain requests to appear as if they are originating from WordPress.org.

Exclusion of Plugins and Themes

The plugin inspects the HTTP request body for plugin and theme update checks and automatically excludes items with a specified Update URI header. This can be useful for avoiding update checks for plugins or themes hosted outside the WordPress.org repository.

API URL Monitoring

The plugin allows you to add custom API URLs in the settings for monitoring. Requests to these URLs will be logged, enabling detailed monitoring of specific update requests.

Settings

Access the plugin settings under Settings > Custom URM in the WordPress admin dashboard. The settings page has two tabs:

  1. API URLs: Add or remove custom API URLs for request monitoring. Each entry here is a URL that, when matched in a request, will trigger logging.
  2. Logs: View logs of monitored HTTP requests, including details like headers and request bodies.

Adding API URLs

  • Add new URLs in the API URLs tab to monitor additional endpoints.
  • URLs added here will be automatically checked against each HTTP request.

Clearing Logs

  • The logs tab allows clearing of log data, which can be done manually or will automatically clear daily.

Filters

The plugin includes filters to customize various aspects of its functionality.

User-Agent String Replacement

  • custom_urm_user_agent_string_replace: Modifies the replacement value in the user-agent string.

Example usage:

add_filter( 'custom_urm_user_agent_string_replace', function() {
    return 'notmatt.press';
} );

Core Parameters for Update Checks

  • custom_urm_allowed_core_params: Customizes the list of allowed parameters in the WordPress core update request.

Example usage:

add_filter( 'custom_urm_allowed_core_params', function( $params ) {
    // Add a new parameter.
    $params[] = 'new_param';

    // Remove an existing parameter.
    $params = array_diff( $params, [ 'mysql' ] );

    return $params;
} );

Use custom_urm_allowed_core_params to control which parameters are included in the core update check request, allowing for fine-grained customization.

Releases

2 releases. Each count is every asset in that release; expand a row for the breakdown.

Tag
Published
Assets
Downloads
1.0.1 latest
Feb 4, 2025 1 year ago
custom-update-request-modifier.zip
15
Nov 8, 2024 1 year ago
tag only
—
A grade

Security

Custom Update Request Modifier 1.0.0 · audited by WP Registry

No security issues found.

Audited release
1.0.0
Findings
none
Worst severity
—
Content hash
ad33d42854a6adc7d3dd4b68…

WP Registry hashes the installable build and reports on that exact bytes-for-bytes copy. Embargoed findings are withheld until they are disclosed, so a clean verdict means nothing public is outstanding. WP Manifest does not audit code itself.