JWT Authentication for WP REST API

Extends the WP REST API using JSON Web Tokens Authentication as an authentication method.

v1.5.0tmeisterUpdated Added 60k+ installs88% rating
84
Score
27
Errors
41
Warnings
+0
Change

Category Scores

Security84
Repo94
Performance100
Maintainability70

Issues to Review

Prioritized issue groups from the latest Plugin Check scan

68 findings

Maintainability

53

11 issue groups

I18n

10

2 issue groups

Security

4

2 issue groups

Repo Compliance

1

1 issue group

ERRORMaintainabilitywp function not compatible with requires wpFunction "register_rest_route()" requires WordPress 4.4.0, but your plugin minimum supported version is WordPress 4.2.0.17
Category
Maintainability
Occurrences
17
Severity
error

Sample message

Function "register_rest_route()" requires WordPress 4.4.0, but your plugin minimum supported version is WordPress 4.2.0.

ERRORI18nText Domain MismatchMismatched text domain. Expected 'jwt-authentication-for-wp-rest-api' but got 'jwt-auth'.9
Category
I18n
Occurrences
9
Severity
error

Sample message

Mismatched text domain. Expected 'jwt-authentication-for-wp-rest-api' but got 'jwt-auth'.

WARNINGMaintainabilityNon-prefixed functionFunctions declared in the global namespace by a theme/plugin should start with the theme/plugin prefix. Found: "activate_jwt_auth".8
Category
Maintainability
Occurrences
8
Severity
warning

Sample message

Functions declared in the global namespace by a theme/plugin should start with the theme/plugin prefix. Found: "activate_jwt_auth".

WARNINGMaintainabilityNon-prefixed hook nameHook names invoked by a theme/plugin should start with the theme/plugin prefix. Found: "jwt_auth_algorithm".7
Category
Maintainability
Occurrences
7
Severity
warning

Sample message

Hook names invoked by a theme/plugin should start with the theme/plugin prefix. Found: "jwt_auth_algorithm".

WARNINGMaintainabilityNon-prefixed classClasses declared by a theme/plugin should start with the theme/plugin prefix. Found: "Jwt_Auth".6
Category
Maintainability
Occurrences
6
Severity
warning

Sample message

Classes declared by a theme/plugin should start with the theme/plugin prefix. Found: "Jwt_Auth".

WARNINGMaintainabilityerror log error logerror_log() found. Debug code should not normally be used in production.6
Category
Maintainability
Occurrences
6
Severity
warning

Sample message

error_log() found. Debug code should not normally be used in production.

WARNINGSecurityRequest data is not unslashed$_SERVER['HTTP_AUTHORIZATION'] not unslashed before sanitization. Use wp_unslash() or similar3
Category
Security
Occurrences
3
Severity
warning

Sample message

$_SERVER['HTTP_AUTHORIZATION'] not unslashed before sanitization. Use wp_unslash() or similar

WARNINGMaintainabilitytrademarked termThe plugin name includes a restricted term. Your chosen plugin name - "JWT Authentication for WP REST API" - contains the restricted term "wp" which cannot be used at all in your plugin name.3
Category
Maintainability
Occurrences
3
Severity
warning

Sample message

The plugin name includes a restricted term. Your chosen plugin name - "JWT Authentication for WP REST API" - contains the restricted term "wp" which cannot be used at all in your plugin name.

WARNINGMaintainabilityMissing VersionResource version not set in call to wp_enqueue_script(). This means new versions of the script may not always be loaded due to browser caching.2
Category
Maintainability
Occurrences
2
Severity
warning

Sample message

Resource version not set in call to wp_enqueue_script(). This means new versions of the script may not always be loaded due to browser caching.

WARNINGMaintainabilityDirect QueryUse of a direct database call is discouraged.1
Category
Maintainability
Occurrences
1
Severity
warning

Sample message

Use of a direct database call is discouraged.

Show 6 more
WARNINGMaintainabilityNo Caching1
Category
Maintainability
Occurrences
1
Severity
warning

Sample message

Direct database call without caching detected. Consider using wp_cache_get() / wp_cache_set() or wp_cache_delete().

WARNINGMaintainabilityerror log print r1
Category
Maintainability
Occurrences
1
Severity
warning

Sample message

print_r() found. Debug code should not normally be used in production.

WARNINGSecurityInput is not validated1
Category
Security
Occurrences
1
Severity
warning

Sample message

Detected usage of a possibly undefined superglobal array index: $_SERVER['REQUEST_URI']. Check that the array index exists before using it.

WARNINGMaintainabilitymismatched plugin name1
Category
Maintainability
Occurrences
1
Severity
warning

Sample message

Plugin name "JWT Authentication for WP REST API" is different from the name declared in plugin header "JWT Authentication for WP-API".

ERRORRepo Complianceoutdated tested upto header1
Category
Repo Compliance
Occurrences
1
Severity
error

Sample message

Tested up to: 6.9 < 7.0. The "Tested up to" value in your plugin is not set to the current version of WordPress. This means your plugin will not show up in searches, as we require plugins to be compatible and documented as tested up to the most recent version of WordPress.

WARNINGI18ntextdomain mismatch1
Category
I18n
Occurrences
1
Severity
warning

Sample message

The "Text Domain" header in the plugin file does not match the slug. Found "jwt-auth", expected "jwt-authentication-for-wp-rest-api".

External Connections

Not analyzed yet.

Score History

First score snapshot

v1.5.0

84

Latest

Findings
68
Errors
27
Warnings
41
Check
2.0.0

Relationship Map

Author, categories, issues, domains, and nearby plugins.

29 nodes

Related Plugins

Firebase Authentication

500 active installs

100
Logged-in-only

700 active installs

100
SEO Meta Description Updater

500 active installs

99
CoCart CORS Support

400 active installs

98
Automatik Blog

1k+ active installs

97