[VPAT-27] chore(security): disable autocomplete on sensitive input fields #8517

Disable autocomplete on authentication and security-related forms to prevent
browsers from storing sensitive credentials. This affects sign-in, password
reset, account security, and onboarding forms across admin, web, and space apps.

Modified components:
- Auth forms (email, password, unique code, forgot/reset/set password)
- Account security pages
- Instance setup and profile onboarding
- Shared UI components (auth-input, password-input)
This commit is contained in:
Prateek Shourya 2026-02-17 00:43:35 +05:30 committed by GitHub
parent d3c6e5ec94
commit e9b011896d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
20 changed files with 52 additions and 40 deletions

View file

@ -13,7 +13,6 @@ export interface InputProps extends React.InputHTMLAttributes<HTMLInputElement>
inputSize?: "xs" | "sm" | "md";
hasError?: boolean;
className?: string;
autoComplete?: "on" | "off";
}
const Input = React.forwardRef(function Input(props: InputProps, ref: React.ForwardedRef<HTMLInputElement>) {

View file

@ -5,11 +5,11 @@
*/
import { Eye, EyeClosed } from "lucide-react";
import React, { useState } from "react";
import { useState } from "react";
import { Tooltip } from "@plane/propel/tooltip";
import { cn } from "@plane/utils";
interface PasswordInputProps {
type TPasswordInputProps = {
id: string;
value: string;
onChange: (value: string) => void;
@ -17,7 +17,8 @@ interface PasswordInputProps {
className?: string;
showToggle?: boolean;
error?: boolean;
}
autoComplete?: React.HTMLInputAutoCompleteAttribute;
};
export function PasswordInput({
id,
@ -27,7 +28,8 @@ export function PasswordInput({
className,
showToggle = true,
error = false,
}: PasswordInputProps) {
autoComplete = "off",
}: TPasswordInputProps) {
const [showPassword, setShowPassword] = useState(false);
return (
<div className="relative">
@ -45,6 +47,7 @@ export function PasswordInput({
className
)}
placeholder={placeholder}
autoComplete={autoComplete}
/>
{showToggle && (
<Tooltip tooltipContent={showPassword ? "Hide password" : "Show password"} position="top">