สามารถกำหนดนโยบายรหัสผ่านใน Windows 11/10 ได้ เช่น ความยาวขั้นต่ำ ต้องมีตัวพิมพ์ใหญ่/เล็ก/ตัวเลข/สัญลักษณ์ อายุการใช้งานรหัสผ่าน ฯลฯ ผ่าน 2 วิธี:
6 ตัวเลือกนโยบายรหัสผ่านที่ปรับได้
- Enforce Password History (จำนวนรหัสผ่านเก่าที่ห้ามซ้ำ 0-24)
- Maximum password age (อายุสูงสุด 1-999 วัน หรือ 0 = ไม่หมดอายุ)
- Minimum password age (อายุขั้นต่ำก่อนเปลี่ยนได้ 0-998 วัน)
- Minimum password length (ความยาวขั้นต่ำ 0-14 ตัวอักษร)
- Password must meet complexity requirements (ต้องมี 3 ใน 4 ประเภท: ตัวใหญ่, ตัวเล็ก, ตัวเลข, สัญลักษณ์)
- Store password using reversible encryption (ไม่แนะนำ ยกเว้นแอปบังคับ)
วิธี 1: ใช้ Local Security Policy (สำหรับ Pro/Enterprise)
- ค้นหา Local Security Policy ใน Start Menu
- ไปที่ Account Policies > Password Policy
- ดับเบิลคลิกแต่ละรายการเพื่อแก้ไขค่า > OK
วิธี 2: ใช้ Command Prompt (Admin) - ใช้ได้ทุก Edition
เปิด CMD as Administrator รันคำสั่ง:
net accounts /minpwlen:ความยาว(0-14)net accounts /maxpwage:วัน(1-999 หรือ unlimited)net accounts /minpwage:วัน(0-998)net accounts /uniquepw:จำนวน(1-24)
ตรวจสอบการตั้งค่าปัจจุบันด้วยคำสั่ง net accounts