def create_data(
    indicator: Dict[str, Union[str, int, List[Any], Dict[str, Any]]],
    indicator_type: str,
) -> Optional[Dict[str, Union[str, int, List[Any]]]]:
    """
    Create a data dictionary based on the given indicator and its type.

    Parameters:
    indicator (Dict[str, Union[str, int, List[Any], Dict[str, Any]]]): A
    dictionary containing indicator information.
    indicator_type (str): A string indicating the type of the indicator.

    Returns:
    Optional[Dict[str, Union[str, int, List[Any]]]]: A dictionary of data
    corresponding to the given indicator and its type, or None if an error occurs.

    Raises:
    Exception: Any exception thrown during the processing of the data is
    caught and logged.
    """
    try:
        handlers: Dict[str, Callable[[], Dict[str, Union[str, int, List[Any]]]]] = {
            "URL": lambda: {"url": str(indicator.get("indicator_value", ""))},
            "IP": lambda: {
                "networkIPv4": get_network_address(
                    str(indicator.get("indicator_value", ""))
                )
            },
            "MD5": lambda: {
                "fileHashValue": str(indicator.get("indicator_value", "")),
                "fileHashType": "md5",
            },
            "SHA1": lambda: {
                "fileHashValue": str(indicator.get("indicator_value", "")),
                "fileHashType": "sha1",
            },
            "SHA256": lambda: {
                "fileHashValue": str(indicator.get("indicator_value", "")),
                "fileHashType": "sha256",
            },
            "SHA512": lambda: {
                "fileHashValue": str(indicator.get("indicator_value", "")),
                "fileHashType": "sha512",
            },
            "EMAIL": lambda: {
                "emailSenderAddress": str(indicator.get("indicator_value", ""))
            },
            "INCIDENT": lambda: {
                "emailSenderAddress": str(indicator.get("account_login", ""))
            },
            "DOMAIN": lambda: {"domainName": str(indicator.get("indicator_value", ""))},
            "DIR": lambda: {"filePath": str(indicator.get("indicator_value", ""))},
            "File_Size": lambda: {
                "fileSize": str(indicator.get("indicator_value", ""))
            },
            "File_Extension": lambda: {
                "filePath": str(indicator.get("indicator_value", ""))
            },
            "MUTEX": lambda: {
                "fileMutexName": str(indicator.get("indicator_value", ""))
            },
        }

        handler = handlers.get(indicator_type)
        if handler is None:
            logging.warning("No handler for indicator type %s", indicator_type)
            return None

        data = get_static_data(indicator, indicator_type)
        data.update(handler())
        return data

    except KeyError as err:
        logging.error("Missing key in indicator: %s", err)
    except Exception as err:
        logging.error(
            "Unexpected error occurred while creating azure sentinel IOC Format: %s: %s",
            type(err).__name__,
            err,
        )

    return None

    Create a data dictionary based on the given indicator and its type.

    Parameters:
    indicator (Dict[str, Union[str, int, List[Any], Dict[str, Any]]]): A
    dictionary containing indicator information.
    indicator_type (str): A string indicating the type of the indicator.

    Returns:
    Optional[Dict[str, Union[str, int, List[Any]]]]: A dictionary of data
    corresponding to the given indicator and its type, or None if an error occurs.

    Raises:
    Exception: Any exception thrown during the processing of the data is
    caught and logged.
    
Solutions/CognyteLuminar/Data Connectors/CognyteLuminar/main.py