Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 292829

Replace use of whitelist/blacklist in \Drupal\Core\Template classes and their tests

$
0
0

Problem/Motivation

Lets remove usage of "blacklist" and "whitelist" in \Drupal\Core\Template classes and their tests.

They are:

  • An historic bad labelling of people
  • Provide no context: "what is listed in them"?

Proposed resolution

TBD

Remaining tasks

  1. Decide if we need BC.
  2. Decide if we need to touch core/lib/Drupal/Core/Template/Attribute.php too. Only 'black-cat' and 'white-cat' and friends. Seems we could leave those.
  3. Fix everything:
    • core/lib/Drupal/Core/Template/Loader/StringLoader.php - Comment only. See #3
    • core/lib/Drupal/Core/Template/TwigSandboxPolicy.php - Full of "whitelist":
        protected $whitelisted_methods;
        protected $whitelisted_prefixes;
        protected $whitelisted_classes;
      
  4. Reviews.
  5. RTBC.

User interface changes

None

API changes

None, only renaming some protected members.

Data model changes

@todo

Release notes snippet

@todo


Viewing all articles
Browse latest Browse all 292829

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>