private boolean validateToken(String authHeader) throws MSF4JSecurityException {
  String accessToken=extractAccessToken(authHeader);
  String responseStr=getValidatedTokenResponse(accessToken);
  Map<String,String> responseData=getResponseDataMap(responseStr);
  if (!Boolean.parseBoolean(responseData.get(IntrospectionResponse.ACTIVE))) {
    throw new MSF4JSecurityException(SecurityErrorCode.AUTHENTICATION_FAILURE,"Invalid Access token.");
  }
  return true;
}

private boolean validateToken ( String authHeader ) throws MSF4JSecurityException { String accessToken = extractAccessToken ( authHeader ) ; String responseStr = getValidatedTokenResponse ( accessToken ) ; Map < String , String > responseData = getResponseDataMap ( responseStr ) ; if ( ! Boolean . parseBoolean ( responseData . get ( IntrospectionResponse . ACTIVE ) ) ) { throw new MSF4JSecurityException ( SecurityErrorCode . AUTHENTICATION_FAILURE , "Invalid Access token." ) ; } return true ; }
extract the accesstoken from the give authorization header value and validates the accesstoken with an external key manager .
