See http://api.drupal.org/api/drupal/includes%21common.inc/function/format_u...

Return value

An unsanitized string with the username to display. The code receiving this result must ensure that check_plain() is called on it before it is printed to the page.

This issue is safe to be reported in public since this module has no official public release and only a dev release. This issue should block a stable release of this module because if this is not fixed then this requires an official security announcement to fix.

Comments

dave reid’s picture

Status: Active » Needs review
Issue tags: +D7 stable release blocker
StatusFileSize
new2.33 KB
sun’s picture

Status: Needs review » Reviewed & tested by the community

wow.

All other format_* functions return a sanitized string: http://api.drupal.org/api/search/7/format_

Let's pretty please open an at least major bug against Drupal core to fix that format_username() mess/confusion.

dave reid’s picture

Well really we should be getting rid of format_username() calls and people should be calling entity_label('user', $account) or $entity->label instead. Both of those should be assumed to be unsanitized output like the rest of entity properties.

dave reid’s picture

jody lynn’s picture

Status: Reviewed & tested by the community » Fixed

Committed.

Automatically closed -- issue fixed for 2 weeks with no activity.