Skip to content

wolfsshd: reject passwords containing a NUL byte - #1329

Open
ejohnstown wants to merge 1 commit into
wolfSSL:masterfrom
ejohnstown:pwchk
Open

ejohnstown wants to merge 1 commit into
wolfSSL:masterfrom
ejohnstown:pwchk

Conversation

@ejohnstown

Copy link
Copy Markdown
Contributor

wolfsshd refuses a password containing a NUL byte. The backends check
the password as a C string, so "\0junk" passed PermitEmptyPasswords no
and logged in to an account with an empty password.

  • RequestAuthentication rejects the NUL before the policy check; the
    new test covers a NUL first, last and mid-password.

Issue: F-16096

The password backends check the password as a C string, so "\0junk"
was checked as "" while its nonzero length passed the
PermitEmptyPasswords check. RequestAuthentication now refuses any
password with a NUL before the policy check and the backends.

- test_RequestAuth_embeddedNulPasswordRejected puts the NUL first,
  last and mid-password, and checks the fake crypt still runs

Issue: F-16096
Copilot AI balanced review requested due to automatic review settings October 19, 2026 23:21

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@wolfSSL-Fenrir-bot wolfSSL-Fenrir-bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fenrir Automated Review — PR #1329

Scan targets checked: wolfssh-src, wolfssh-bugs
Coverage: 1 of 2 in-scope changed file(s) opened by the reviewer; not opened: apps/wolfsshd/test/test_configuration.c

Fenrir result: Approved ✅

No new issues found in the changed files.

Advisory only — this automated result does not count as a GitHub approval.

Review tier: Lite

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants