Make WordPress Core


Ignore:
Timestamp:
01/27/2021 07:03:42 PM (4 years ago)
Author:
TimothyBlynJacobs
Message:

App Passwords: Improve validation and sanitization of the application name.

Application names are now required to be unique and cannot contain solely whitespace characters. Additionally, invalid characters are now stripped from the application name using sanitize_text_field().

Props Boniu91, hellofromTonya, engahmeds3ed, xkon, francina.
Fixes #51941.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/rest-api/rest-application-passwords-controller.php

    r49752 r50030  
    539539    /**
    540540     * @ticket 51583
     541     * @ticket 51941
    541542     */
    542543    public function test_update_item_cannot_overwrite_app_id() {
     
    555556            self::$admin,
    556557            array(
    557                 'name'   => 'App',
     558                'name'   => 'App 2',
    558559                'app_id' => $app_id,
    559560            )
Note: See TracChangeset for help on using the changeset viewer.