WP Manifestindependent plugin directory
manifest / media / icons-for-cp

Icons for CP WP Registry grade D+. High-severity findings · 2 findingsWP RegistryHigh-severity findings · 2 findingsOpen the reportD+

ClassicPress plugin that allows to use SVG icons in post and pages.

★ 1stars
521release downloads
≈30active sites
v1.3.6latest · 1 year ago

Install

Download icons-for-cp-v1.3.6.zip From the v1.3.6 release on GitHub, Jul 17, 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/xxsimoxx/icons-for-cp/releases/download/v1.3.6/icons-for-cp-v1.3.6.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

Logo

Icons for CP

This plugin allows to use SVG icons in post and pages.

Add new icons

Just use the "Icons" menu in "Appearance" menu. Add your own icons or any from FontAwesome to the theme.

Put the name of the icon as the title (use something like my-brand-icon) and the SVG as the post.

Note: if you uninstall the plugin your icons get lost. To keep them add define('KEEP_ICONS_FOR_CP', true); to wp-config.php.

Shortcode and MCE menu

[ifcp-icon icon='paw' size='16' color='#FF0000' class='my-wonderful-class']

Size (width, default 16px), color and class are optional.

It also adds a menu to TinyMCE (v. 4 and v.5) to choose the icon and insert the shortcode for you.

Integrations

This plugin integrates with Canuck CP theme, that is no more available. Your icons are added to those present in the theme, and those present in the theme are available.

WP CLI

It is supported. Use wp help icons or wp help icons add to see usage instructions. You can bulk import a folder with a simple script like

for icon in *.svg; do
    wp icons add "$icon";
done

Releases

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

Tag
Published
Assets
Downloads
v1.3.6 latest
Jul 17, 2025 1 year ago
icons-for-cp-v1.3.6.zip
31
May 10, 2023 3 years ago
icons-for-cp-1.3.5.zip
185
Mar 29, 2023 3 years ago
icons-for-cp-1.3.4.zip
17
Aug 31, 2022 4 years ago
icons-for-cp-1.3.3.zip
64
May 26, 2022 4 years ago
icons-for-cp-1.3.2.zip
32
May 25, 2022 4 years ago
icons-for-cp-1.3.0.zip
9
Nov 19, 2021 4 years ago
icons-for-cp-1.2.0.zip
52
Apr 1, 2021 5 years ago
icons-for-cp-1.1.1.zip
52
Feb 21, 2021 5 years ago
icons-for-cp-1.1.0.zip
7
Jan 20, 2021 5 years ago
icons-for-cp-1.0.0.zip
6
Jan 15, 2021 5 years ago
icons-for-cp-1.0.0-rc1.zip
4
Jan 8, 2021 5 years ago
icons-for-cp-0.2.1.zip
4
Jan 7, 2021 5 years ago
icons-for-cp-0.2.0.zip
5
Jan 6, 2021 5 years ago
icons-for-cp-0.1.0.zip
10
Jan 5, 2021 5 years ago
icons-for-canuck-cp-0.0.7.zip
3
Jan 5, 2021 5 years ago
icons-for-canuck-cp-0.0.6.zip
3
Dec 30, 2020 5 years ago
icons-for-canuck-cp-0.0.5.zip
5
Dec 28, 2020 5 years ago
icons-for-canuck-cp-0.0.4.zip
3
Nov 25, 2020 5 years ago
icons-for-canuck-cp-0.0.3.zip
9
Nov 20, 2020 5 years ago
icons-for-canuck-cp-0.0.2.zip
9
Nov 19, 2020 5 years ago
icons-for-canuck-cp-0.0.1.zip
11

Active-site estimate ≈30 comes from the median of recent superseded releases. Method.

D+ grade

Security

Icons for CP 1.3.6 · audited by WP Registry

High-severity findings.

1 high 1 medium
Audited release
1.3.6
Findings
2
Worst severity
high
Content hash
36f1ccd7c7e57efbb4ced7ce…

Findings

  • high Stored XSS via unsanitized [ifcp-icon] class attribute (Contributor+)

    xss_stored

    process_shortcode() takes the shortcode class attribute from shortcode_atts and concatenates it directly into a frontend HTML attribute: ' class="'.$p['class'].'"' then '<span'.$p['class'].'>'. There is no esc_attr(), sanitize_html_class(), or kses on that value. WordPress shortcode_parse_atts preserves a single-quoted value that itself contains double quotes, so a Contributor or Author (edit_posts, no unfiltered_html required) can store [ifcp-icon class='x" onmouseover="alert(document.domain)'] or [ifcp-icon class='x" autofocus onfocus="alert(document.domain)']. do_shortcode on the_content then emits <span class="x" onmouseover="alert(document.domain)">…</span> for every visitor of that post. wp_kses_post strips HTML tags inside post content but does not parse shortcode attributes, so the quote breakout survives the Contributor kses pass. The payload does not need a valid icon name: a missing icon makes get_svg() return empty and the injected span still renders. size/color are passed through DOMDocument::setAttribute (entity-encoded) and are not this bug. Observable: published post HTML contains attacker event handlers in the site origin; a logged-in administrator viewing the post (or preview) can have their session used for plugin install / new-user creation.

    icons-for-cp.php:453-464

    Recommendation

    Escape the class token with esc_attr() (or better, sanitize_html_class() / a strict [A-Za-z0-9_-]+ allowlist) before interpolating it into HTML. Do not concatenate raw shortcode attributes into markup. Keep size/color on setAttribute or likewise escape them if the SVG path changes.

  • medium Authenticated SVG import uses wp_remote_get on an arbitrary URL and returns the body (full-read SSRF)

    ssrf

    wp_ajax_ifcp → ajax_callback() case 'import' passes esc_url_raw($_REQUEST['remote_url']) into fetch_svg(), which calls wp_remote_get($remote_url) and returns ['bad'=>false,'icon'=>$response['body']]. wp_remote_get does not apply wp_http_validate_url, so localhost, RFC1918, and link-local targets including http://169.254.169.254/ (cloud instance metadata) are fetched by the WordPress server; the full body is JSON-encoded back to the browser. posteditor.js writes that body into CodeMirror and, on change, jQuery('#ifcp-pw-inner').html(...), so a non-SVG HTML response also executes in wp-admin. The handler verifies nonce ifcp-ajax-nonce but never calls current_user_can('manage_options') (or edit_posts). In default configuration that nonce is only localized on the icons-for-cp editor, whose CPT caps are manage_options, so Subscriber/Author cannot mint it — this is Administrator-reachable SSRF, not unauthenticated. There is no host allowlist (the UI default is a GitHub Font Awesome URL, but any http/https URL is accepted). Observable: an Administrator POST to admin-ajax.php?action=ifcp&req=import&remote_url=http://169.254.169.254/latest/meta-data/ with the editor nonce receives instance-role credentials in the JSON icon field.

    icons-for-cp.php:210-296

    Recommendation

    Replace wp_remote_get with wp_safe_remote_get, allowlist hosts (e.g. raw.githubusercontent.com) or schemes/paths expected for SVG import, and refuse private/link-local addresses. Add current_user_can('manage_options') next to the nonce check. Do not assign the fetched body to innerHTML; treat it as text until it is confirmed safe SVG.

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.