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

comments are added to search index without checking access

$
0
0

From search.test:

<?php
 
function testSearchResultsComment() {
   
$comment_body = $this->randomName(5);

   
// Allow anonymous users to search content.
   
$edit = array(
     
DRUPAL_ANONYMOUS_RID . '[search content]'=> 1,
     
// @todo Comments are added to search index without checking first whether
      //   anonymous users are allowed to access comments.
     
DRUPAL_ANONYMOUS_RID . '[access comments]'=> 1,
     
// @todo Without this permission, "Login or register to post comments" is
      //   added to the search index.  Comment.module is not guilty; that text
      //   seems to be added via node links.
     
DRUPAL_ANONYMOUS_RID . '[post comments]'=> 1,
    );
   
$this->drupalPost('admin/config/people/permissions', $edit, t('Save permissions'));
?>

Viewing all articles
Browse latest Browse all 295117

Trending Articles



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