def METHOD_NAME(resource, stack_name: str):
    name = resource.get("Properties", {}).get("Name")
    if not name:
        # not actually correct. Given the LogicalResourceId "MySecret",
        # an example for the generated name would be "MySecret-krxoxgcznYdq-sQNsqO"
        resource["Properties"]["Name"] = generate_default_name(
            stack_name, resource["LogicalResourceId"]
        )