def account_from_role_arn(role_arn):
    """
    Returns the AWS account ID portion of the given IAM role ARN.
    """
    parts = role_arn.split(':')
    if len(parts) == 6:
        return parts[4]
    return '-'