I have disabled "Display post information" on all node types for not showing usernames to the public. Nevertheless it is disabled in nodes, it's shown in the RSS feeds. This isn't the intention of disabling the post information.

Usernames shouldn't be shown anywhere if disabled.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

hass’s picture

Title: Post information displayed in RSS feeds » Username nevertheless displayed in RSS feeds if disabled for privacy reasons
hass’s picture

Title: Username nevertheless displayed in RSS feeds if disabled for privacy reasons » Creator nevertheless displayed in RSS feeds if disabled for privacy reasons
Version: 6.10 » 7.x-dev
Status: Active » Needs review
FileSize
1.09 KB
2.5 KB

This patch removes the creator name from RSS feeds if author and date output has been disabled for a node type in the global theme settings at "admin/build/themes/settings". This patch therefore fixes an inconsistency bug between node and rss output.

This patch stops displaying internal usernames to the public world!

hass’s picture

The D6 patch also fixes some trailing space bugs... if I should role this again, let me know, but my editor automatically removes them and this is why it's inside. The D7 file have many trailing space bugs too, but I've disabled the removal for patch generation.

hass’s picture

For not holding things back, new D6 patch that keeps all trailing space bugs in D6 as is. I keep it up for the maintainer to decide.

Status: Needs review » Needs work

The last submitted patch failed testing.

drupal_was_my_past’s picture

Version: 7.x-dev » 8.x-dev
Component: base system » node system
Status: Needs work » Needs review
FileSize
2.46 KB
1.6 KB

Moved this to node system and 8.x. Attached re-rolled patch from #4 with tests.

webchick’s picture

Status: Needs review » Needs work

Just a couple of things:

+++ b/modules/node/node.test
@@ -814,6 +814,42 @@ class NodeRSSContentTestCase extends DrupalWebTestCase {
+   * Create a new node and ensure that the author's name appears when the post
+   * information is set to be displayed.

Minor nit-pick: All comments should wrap at 80 characters.

+++ b/modules/node/node.test
@@ -814,6 +814,42 @@ class NodeRSSContentTestCase extends DrupalWebTestCase {
+  function testNodeRSSNotPostInfo() {

Since these tests are both so closely related, I'd lump them under the same testX() function. There's a performance impact in that each of these testX() functions means a new reinstall of Drupal and that takes time.

webchick’s picture

This is why I shouldn't review issues and be on IRC at the same time. :) By "All comments should wrap at 80 characters." I meant "Function descriptions should be restricted to 80 characters. Anything longer than that ends up being on another "paragraph" below, e.g.:

/**
 * Foos the bar of bazzles.
 *
 * The foo is an integral part of the bazzle bars. Bizzley boo!
 */
function foo_bazzle_bar() {
}
drupal_was_my_past’s picture

Status: Needs work » Needs review
FileSize
2.15 KB
1.29 KB

Got it! Thanks for the review webchick. Here's another patch with the changes requested.

drupal_was_my_past’s picture

drupal_was_my_past’s picture

Assigned: Unassigned » drupal_was_my_past
saltednut’s picture

Version: 8.x-dev » 9.x-dev
Status: Needs review » Needs work

Looks like this needs reworked as it no longer applies to HEAD - probably does not fit in for 8.x either. :(

@@ -2477,10 +2477,13 @@ function node_feed($nids = FALSE, $channel = array()) {
diff --git a/core/modules/node/node.test b/core/modules/node/node.test

The test needs rebuilt: core/modules/node/node.test no longer exists.

Additionally, I was able to apply the first hunk but it doesn't seem to give the desired result and I'm still seeing the author in RSS feeds.

dawehner’s picture

We should consider whether this issue actually still makes sense in Drupal, as rss.xml is a view now.

hass’s picture

Version: 9.x-dev » 8.x-dev
Priority: Normal » Major
Issue tags: +Security, +Access Bypass
hass’s picture

a

hass’s picture

Title: Creator nevertheless displayed in RSS feeds if disabled for privacy reasons » Creator nevertheless displayed in RSS feeds/search_result if disabled for privacy reasons
hass’s picture

Title: Creator nevertheless displayed in RSS feeds/search_result if disabled for privacy reasons » Author nevertheless displayed in RSS feeds/search_result if disabled for privacy reasons
tim.plunkett’s picture

Rerolled. If you actually think this is a security bug, please file one appropriately.

hass’s picture

Should we combine these two issues?

hass’s picture

Status: Needs work » Needs review
tim.plunkett’s picture

That is a d7 issue. You'll notice I am using the getUsername method, and not label(). This is fine as is.

Status: Needs review » Needs work

The last submitted patch, 18: node-421586-18.patch, failed testing.

jhodgdon’s picture

Title: Author nevertheless displayed in RSS feeds/search_result if disabled for privacy reasons » Author nevertheless displayed in RSS feeds if disabled for privacy reasons
Related issues: +#70722: Search results should respect the content type's "Display author and date information." option

There is a separate issue covering this for search results. Please do not mix them together, as they have separate causes.
#70722: Search results should respect the content type's "Display author and date information." option

Version: 8.0.x-dev » 8.1.x-dev

Drupal 8.0.6 was released on April 6 and is the final bugfix release for the Drupal 8.0.x series. Drupal 8.0.x will not receive any further development aside from security fixes. Drupal 8.1.0-rc1 is now available and sites should prepare to update to 8.1.0.

Bug reports should be targeted against the 8.1.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.2.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.1.x-dev » 8.2.x-dev

Drupal 8.1.9 was released on September 7 and is the final bugfix release for the Drupal 8.1.x series. Drupal 8.1.x will not receive any further development aside from security fixes. Drupal 8.2.0-rc1 is now available and sites should prepare to upgrade to 8.2.0.

Bug reports should be targeted against the 8.2.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.3.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.2.x-dev » 8.3.x-dev

Drupal 8.2.6 was released on February 1, 2017 and is the final full bugfix release for the Drupal 8.2.x series. Drupal 8.2.x will not receive any further development aside from critical and security fixes. Sites should prepare to update to 8.3.0 on April 5, 2017. (Drupal 8.3.0-alpha1 is available for testing.)

Bug reports should be targeted against the 8.3.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.4.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.3.x-dev » 8.4.x-dev

Drupal 8.3.6 was released on August 2, 2017 and is the final full bugfix release for the Drupal 8.3.x series. Drupal 8.3.x will not receive any further development aside from critical and security fixes. Sites should prepare to update to 8.4.0 on October 4, 2017. (Drupal 8.4.0-alpha1 is available for testing.)

Bug reports should be targeted against the 8.4.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.5.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.4.x-dev » 8.5.x-dev

Drupal 8.4.4 was released on January 3, 2018 and is the final full bugfix release for the Drupal 8.4.x series. Drupal 8.4.x will not receive any further development aside from critical and security fixes. Sites should prepare to update to 8.5.0 on March 7, 2018. (Drupal 8.5.0-alpha1 is available for testing.)

Bug reports should be targeted against the 8.5.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.6.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.5.x-dev » 8.6.x-dev

Drupal 8.5.6 was released on August 1, 2018 and is the final bugfix release for the Drupal 8.5.x series. Drupal 8.5.x will not receive any further development aside from security fixes. Sites should prepare to update to 8.6.0 on September 5, 2018. (Drupal 8.6.0-rc1 is available for testing.)

Bug reports should be targeted against the 8.6.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.7.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Delphine Lepers’s picture

Status: Needs work » Needs review
marsigny’s picture

Status: Needs review » Reviewed & tested by the community

I reviewed the patch for version 7.x and it works fine for me

larowlan’s picture

Version: 8.6.x-dev » 8.8.x-dev
Status: Reviewed & tested by the community » Needs work
Issue tags: +Needs tests

Thanks folks, we still need tests for the D8 patch here

albapb’s picture

Patch in #31 also worked for me in drupal 7

Version: 8.8.x-dev » 8.9.x-dev

Drupal 8.8.0-alpha1 will be released the week of October 14th, 2019, which means new developments and disruptive changes should now be targeted against the 8.9.x-dev branch. (Any changes to 8.9.x will also be committed to 9.0.x in preparation for Drupal 9’s release, but some changes like significant feature additions will be deferred to 9.1.x.). For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 8.9.x-dev » 9.1.x-dev

Drupal 8.9.0-beta1 was released on March 20, 2020. 8.9.x is the final, long-term support (LTS) minor release of Drupal 8, which means new developments and disruptive changes should now be targeted against the 9.1.x-dev branch. For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 9.1.x-dev » 9.2.x-dev

Drupal 9.1.0-alpha1 will be released the week of October 19, 2020, which means new developments and disruptive changes should now be targeted for the 9.2.x-dev branch. For more information see the Drupal 9 minor version schedule and the Allowed changes during the Drupal 9 release cycle.

Version: 9.2.x-dev » 9.3.x-dev

Drupal 9.2.0-alpha1 will be released the week of May 3, 2021, which means new developments and disruptive changes should now be targeted for the 9.3.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

tedbow’s picture

So now in D8 this is "Display author and date information". If this is unchecked do we think that the information should not be shown anywhere?

If this is the case it not be returned in JSON API and REST? correct? But this would break peoples APIs.

This seems the same as the RSS feed they are both machine readable formats. Removing this from the RSS feed just seems to give the site owner a false sense they actually implemented access control over the field values, which they have not.

Maybe we should instead just update the description in the UI to explain this is just for the display in the 1 context.

paulocs’s picture

Status: Needs work » Needs review
Issue tags: -Needs tests
FileSize
1.43 KB
2.66 KB

Adding tests to it.

The last submitted patch, 41: 421586-TEST-ONLY-PATCH.patch, failed testing. View results

paulocs’s picture

@tedbow sorry that I didn't read your comment before I attached the patch... As no issue status was updated with your comment I could upload the patch with my page outdated.

Anyway your point makes sense and we should investigate the main reason why this option was created and where it must effect the author field display.

quietone’s picture

Issue tags: +Bug Smash Initiative

This current text, was committed in Nov 2009 to Drupal 7 in #614324: Node UI text improvements to author display settings. Here is the bit from that patch. This issue was created before the other one which changed the text was even created.

   $form['display']['node_submitted'] = array(
     '#type' => 'checkbox',
-    '#title' => t('Display post information'),
+    '#title' => t('Display author and date information.'),
     '#default_value' => variable_get('node_submitted_' . $type->type, TRUE),
-    '#description' => t('Enable the <em>submitted by Username on date</em> text.'),
+    '#description' => t('Author username and publish date will be displayed.'),
   );

The original text was not explicit in the description that action only applied to the display. Now it does make it clear that it is only for display and thus unlikely that someone would expect RSS or other output formats to be changed.

Anyone wanting to tweak the RSS feed output can do a search and find ways to do that using Views.

Therefor I think this can be closed as outdated.

tedbow’s picture

Status: Needs review » Closed (outdated)
Related issues: +#2353867: [META] Expose Title and other base fields in Manage Display

@paulocs no problem about the patch

re

Anyway your point makes sense and we should investigate the main reason why this option was created and where it must effect the author field display.

I think it works as intended now but I think the intention is not great UX.

I think in general the author and date fields should be on Manage Display instead like other fields. There is an existing meta for this #2353867: [META] Expose Title and other base fields in Manage Display

@quietone I agree. closing as outdated

paulocs’s picture

👍