MCPcopy Create free account
hub / github.com/OWASP/SecurityShepherd / isValidUser

Method isValidUser

src/main/java/utils/Validate.java:165–174  ·  view source on GitHub ↗

Used to validate user creation requests @param userName User Name @param passWord User Password @return Boolean value stating weather or not these supplied attributes make a valid user

(String userName, String passWord)

Source from the content-addressed store, hash-verified

163 * @return Boolean value stating weather or not these supplied attributes make a valid user
164 */
165 public static boolean isValidUser(String userName, String passWord)
166 {
167 boolean result = false;
168 result = userName.length() > 2 && passWord.length() > 7 && userName.length() <= 32 && passWord.length() <= 512;
169 if (!result)
170 {
171 log.debug("Invalid Data detected in Validate.isValidUser()");
172 }
173 return result;
174 }
175
176 /**
177 * Used to validate user creation requests

Callers 3

doPostMethod · 0.95
doPostMethod · 0.95
doPostMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected