magento / magento/security-package

Replace autocomplete="off" with autocomplete="one-time-code" on auth

Open
#332 1 comment 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Progress: ready for grooming
Dominant language
PHP
Stars
75
Forks
73
PR merge metrics
No merged PRs in 30d

Description

Hi,

https://web.dev/sms-otp-form/ recommends that autocomplete="off" is replaced with autocomplete="one-time-code" so that the browser doesn't ask the user if they want to replace their current password with the autocomplete.

See also https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete#values

For example,

https://github.com/magento/security-package/blob/develop/TwoFactorAuth/view/adminhtml/web/template/google/auth.html#L25

Can submit a PR myself with "fixes" if requested.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with TwoFactorAuth/view/adminhtml/web/template/google/auth.html at the referenced autocomplete attribute, then read the linked web.dev SMS OTP guidance and MDN autocomplete values. Done means the authentication autocomplete value is changed as requested and the affected template no longer uses autocomplete="off" for this case.

Written by the indexing model from the issue text.

Assessment

Tech stack
html, php
Domain
authentication
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.