tvaultapi/src/main/java/com/tmobile/cso/vault/api/controller/ControllerUtil.java
public static boolean areSafeUserInputsValid(SafeUser safeUser) {
		log.debug(JSONUtil.getJSON(ImmutableMap.<String, String>builder().
				put(LogMessage.USER, ThreadLocalContext.getCurrentMap().get(LogMessage.USER)).
				put(LogMessage.ACTION, "areSafeUserInputsValid").
				put(LogMessage.MESSAGE,"Start validating input parameteres").
				put(LogMessage.APIURL, ThreadLocalContext.getCurrentMap().get(LogMessage.APIURL)).
				build()));
		if (ObjectUtils.isEmpty(safeUser)) {
			return false;
		}
		if (ObjectUtils.isEmpty(safeUser.getUsername())
				|| ObjectUtils.isEmpty(safeUser.getAccess())
				|| ObjectUtils.isEmpty(safeUser.getPath())
				) {
			return false;
		}
		String path = safeUser.getPath();
		if (!isPathValid(path)) {
			return false;
		}
		String access = safeUser.getAccess();
		if (!ArrayUtils.contains(permissions, access)) {
			return false;
		}
		log.debug(JSONUtil.getJSON(ImmutableMap.<String, String>builder().
				put(LogMessage.USER, ThreadLocalContext.getCurrentMap().get(LogMessage.USER)).
				put(LogMessage.ACTION, "areSafeUserInputsValid").
				put(LogMessage.MESSAGE,"Input parameter validation completed").
				put(LogMessage.APIURL, ThreadLocalContext.getCurrentMap().get(LogMessage.APIURL)).
				build()));
		return true;
	}
/**
	 * Validates Safe User inputs
	 * @param safeUser
	 * @return
	 */
Validates Safe User inputs
@param safeUser
@return
Validates Safe User inputs @param safeUser @return
public static boolean areSafeUserInputsValid(SafeUser safeUser) {
		log.debug(JSONUtil.getJSON(ImmutableMap.<String, String>builder().
				put(LogMessage.USER, ThreadLocalContext.getCurrentMap().get(LogMessage.USER)).
				put(LogMessage.ACTION, "areSafeUserInputsValid").
				put(LogMessage.MESSAGE,"Start validating input parameteres").
				put(LogMessage.APIURL, ThreadLocalContext.getCurrentMap().get(LogMessage.APIURL)).
				build()));
		if (ObjectUtils.isEmpty(safeUser)) {
			return false;
		}
		if (ObjectUtils.isEmpty(safeUser.getUsername())
				|| ObjectUtils.isEmpty(safeUser.getAccess())
				|| ObjectUtils.isEmpty(safeUser.getPath())
				) {
			return false;
		}
		String path = safeUser.getPath();
		if (!isPathValid(path)) {
			return false;
		}
		String access = safeUser.getAccess();
		if (!ArrayUtils.contains(permissions, access)) {
			return false;
		}
		log.debug(JSONUtil.getJSON(ImmutableMap.<String, String>builder().
				put(LogMessage.USER, ThreadLocalContext.getCurrentMap().get(LogMessage.USER)).
				put(LogMessage.ACTION, "areSafeUserInputsValid").
				put(LogMessage.MESSAGE,"Input parameter validation completed").
				put(LogMessage.APIURL, ThreadLocalContext.getCurrentMap().get(LogMessage.APIURL)).
				build()));
		return true;
	}
public static boolean areSafeUserInputsValid ( SafeUser safeUser ) { log . debug ( JSONUtil . getJSON ( ImmutableMap . < String , String > builder ( ) . put ( LogMessage . USER , ThreadLocalContext . getCurrentMap ( ) . get ( LogMessage . USER ) ) . put ( LogMessage . ACTION , "areSafeUserInputsValid" ) . put ( LogMessage . MESSAGE , "Start validating input parameteres" ) . put ( LogMessage . APIURL , ThreadLocalContext . getCurrentMap ( ) . get ( LogMessage . APIURL ) ) . build ( ) ) ) ; if ( ObjectUtils . isEmpty ( safeUser ) ) { return false ; } if ( ObjectUtils . isEmpty ( safeUser . getUsername ( ) ) || ObjectUtils . isEmpty ( safeUser . getAccess ( ) ) || ObjectUtils . isEmpty ( safeUser . getPath ( ) ) ) { return false ; } String path = safeUser . getPath ( ) ; if ( ! isPathValid ( path ) ) { return false ; } String access = safeUser . getAccess ( ) ; if ( ! ArrayUtils . contains ( permissions , access ) ) { return false ; } log . debug ( JSONUtil . getJSON ( ImmutableMap . < String , String > builder ( ) . put ( LogMessage . USER , ThreadLocalContext . getCurrentMap ( ) . get ( LogMessage . USER ) ) . put ( LogMessage . ACTION , "areSafeUserInputsValid" ) . put ( LogMessage . MESSAGE , "Input parameter validation completed" ) . put ( LogMessage . APIURL , ThreadLocalContext . getCurrentMap ( ) . get ( LogMessage . APIURL ) ) . build ( ) ) ) ; return true ; }
Validates Safe User inputs
 @param safeUser
 @return
Validates Safe User inputs @param safeUser @return