Skip to content

Commit 21850ba

Browse files
authored
Merge pull request #171 from Next-Room/feature/password
[CHORE] ๋น„๋ฐ€๋ฒˆํ˜ธ ์กฐ๊ฑด ๋ณ€๊ฒฝ
2 parents 754dbb7 + 7288b77 commit 21850ba

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

โ€Žsrc/main/java/com/nextroom/nextRoomServer/dto/AuthDto.javaโ€Ž

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ public class AuthDto {
2828
private static final String PASSWORD_CONDITION_UPPER_CASE_REGEX = ".*[A-Z].*";
2929
private static final String PASSWORD_CONDITION_NUMBER_REGEX = ".*[0-9].*";
3030
private static final String PASSWORD_CONDITION_SPECIAL_CHARACTER_REGEX = ".*[!@#$%^&*()].*";
31+
private static final String PASSWORD_CONDITION_NUMBER_OR_SPECIAL_CHAR_REGEX = ".*[0-9!@#$%^&*()+=?-].*";
32+
3133
private static final String NO_NAME = "์˜คํ”ˆ ์˜ˆ์ • ๋งค์žฅ";
3234

3335
@Getter
@@ -41,10 +43,7 @@ public static class SignUpRequestDto {
4143
@Setter
4244
@NotEmpty(message = "๋น„๋ฐ€๋ฒˆํ˜ธ๋ฅผ ์ž…๋ ฅํ•ด ์ฃผ์„ธ์š”.")
4345
@Pattern(regexp = PASSWORD_CONDITION_MIN_LENGTH_REGEX, message = "๋น„๋ฐ€๋ฒˆํ˜ธ๋Š” ์ตœ์†Œ 8์ž๋ฆฌ ์ด์ƒ์ด์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.")
44-
@Pattern(regexp = PASSWORD_CONDITION_LOWER_CASE_REGEX, message = "๋น„๋ฐ€๋ฒˆํ˜ธ์— ์˜๋ฌธ ์†Œ๋ฌธ์ž๋ฅผ ์ตœ์†Œ 1๊ฐœ ์ด์ƒ ํฌํ•จํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.")
45-
@Pattern(regexp = PASSWORD_CONDITION_UPPER_CASE_REGEX, message = "๋น„๋ฐ€๋ฒˆํ˜ธ์— ์˜๋ฌธ ๋Œ€๋ฌธ์ž๋ฅผ ์ตœ์†Œ 1๊ฐœ ์ด์ƒ ํฌํ•จํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.")
46-
@Pattern(regexp = PASSWORD_CONDITION_NUMBER_REGEX, message = "๋น„๋ฐ€๋ฒˆํ˜ธ์— ์ˆซ์ž(0-9)๋ฅผ ์ตœ์†Œ 1๊ฐœ ์ด์ƒ ํฌํ•จํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.")
47-
@Pattern(regexp = PASSWORD_CONDITION_SPECIAL_CHARACTER_REGEX, message = "๋น„๋ฐ€๋ฒˆํ˜ธ์— ํŠน์ˆ˜๋ฌธ์ž(!, @, #, $, %, ^, &, *, (, ))๋ฅผ ์ตœ์†Œ 1๊ฐœ ์ด์ƒ ํฌํ•จํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.")
46+
@Pattern(regexp = PASSWORD_CONDITION_NUMBER_OR_SPECIAL_CHAR_REGEX, message = "๋น„๋ฐ€๋ฒˆํ˜ธ์— ์ˆซ์ž(0-9) ํ˜น์€ ํŠน์ˆ˜๋ฌธ์ž(!, @, #, $, %, ^, &, *, (, ), +, =, ?, -)๋ฅผ ์ตœ์†Œ 1๊ฐœ ์ด์ƒ ํฌํ•จํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.")
4847
private String password;
4948
@NotBlank(message = "์—…์ฒด๋ช…์„ ์ž…๋ ฅํ•ด ์ฃผ์„ธ์š”.")
5049
private String name;

0 commit comments

Comments
ย (0)