controlpasswordrule.java

来自「一个agent 工具包,可以开发移动设备应用,考虑了安全措施」· Java 代码 · 共 37 行

JAVA
37
字号
package SOMA.security.utility;

/* This interface contain the name of the 6
 * roles to accept a password;
 * the user can use that to select the rules
 * to applicate in the ControlPassword class.
 */

public interface ControlPasswordRule {
    // Role 1
    //   the password must contain at least eight character
    public static final int PASSWORD_LENGTH = 1;

    // Role 2
    //   the password must contain at least one uppercase letter
    public static final int UPPERCASE_LETTER = 2;

    // Role 3
    //   the password must contain at least one lowercase letter
    public static final int LOWERCASE_LETTER = 4;

    // Role 4
    //  the password must contain at least one number
    public static final int NUMBER_IN_PASSWORD = 8;

    // Role 5
    //   the password cannot contain many occurrences of the same character
    public static final int SAME_CHARACTER = 16;

    // Role 6
    //   the password cannot contain a lengthy part of your profile name.
    //   Parameter:  password: the profile password;
    //               profileName: the profile file name.
    public static final int PROFILENAME_IN_PASSWORD = 32;


}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?