def get_permission(user_id, app, perm_category):
    """
    Get the permission type for a specific user, app, and permission category.

    Args:
        user_id (str): The ID of the user.
        app (str): The name of the app.
        perm_category (str): The category of the permission (exec, data, collab).

    Returns:
        str: The type of permission if exists, otherwise None.

    """
    permissions = read_permissions_from_file()
    app_permissions = permissions.get(user_id, {}).get(app)
    if app_permissions:
        return app_permissions.get(perm_category)
    return None

    Get the permission type for a specific user, app, and permission category.

    Args:
        user_id (str): The ID of the user.
        app (str): The name of the app.
        perm_category (str): The category of the permission (exec, data, collab).

    Returns:
        str: The type of permission if exists, otherwise None.

    
llama-index-packs/llama-index-packs-secgpt/llama_index/packs/secgpt/permission.py