Как вам требуется 8-значный пароль при вводе
<input type="password" name="password" minlength="8" required>
<!-- Here minlength ensures that the number
of inputs is greater than or equals to 8 -->
Code Rabbi