The Drupal superuser account (uid 1) should be covered by password expiration by default. Having the superuser password expire mitigates password compromise. Exempting the superuser from expiration does not, so is an insecure default.

This change would only affect new installations. Existing installations would retain the existing setting so there is no unexpected change in behavior.

Comments

aohrvetpv’s picture

This may be the default to prevent administrators from locking themselves out of their sites. However, it is worse for an attacker to compromise the superuser account than administrator lock-out, the latter of which should always be remediable without any harm to website users.

aohrvetpv’s picture

Status: Active » Needs review
StatusFileSize
new2.87 KB

This patch changes the default to expire the superuser (uid 1) password if it is covered by an expiration policy.

The default value should be set in one place, not three, but that is perhaps a separate problem.

nancydru’s picture

Looks okay to me.

aohrvetpv’s picture

Retesting patch to check that newly committed test methods work as expected.

There should be failures because the new methods expect "Admin (UID = 1) expires" to be unchecked by default.

aohrvetpv’s picture

The tests passed (unexpected). It looks like I missed changing the default in one place.

This patch will hopefully fail testing.

Status: Needs review » Needs work
aohrvetpv’s picture

Status: Needs work » Needs review
StatusFileSize
new4.7 KB

Updated test methods per change in default.

Status: Needs review » Needs work
aohrvetpv’s picture

Status: Needs work » Needs review
StatusFileSize
new5.27 KB

Fixed mistake in test method changes (hopefully).

aohrvetpv’s picture

Removed redundant sentence from hook_update_N() comment.

  • AohRveTPV committed e16c8d5 on 7.x-1.x
    Issue #2476113 by AohRveTPV: Exempting uid 1 from expiration is insecure...
aohrvetpv’s picture

Version: 7.x-1.x-dev » 6.x-1.x-dev
Status: Needs review » Patch (to be ported)
aohrvetpv’s picture

Status: Patch (to be ported) » Closed (won't fix)

6.x-1.x is no longer supported.