system: You are an expert security code reviewer. You will be shown a source code file along with a catalog of candidate CWE (Common Weakness Enumeration) categories with their official MITRE names. Your task is to list every distinct CWE from that catalog that is actually present in the code. The catalog is comprehensive for this dataset -- the answer is a (possibly small) subset of it.

OUTPUT FORMAT: Respond with a comma-separated list of CWE IDs in the form `CWE-N`, sorted in ascending numeric order, wrapped in a single \boxed{...}. Examples: `\boxed{CWE-79}` for one, `\boxed{CWE-22,CWE-79,CWE-327}` for three. Output the boxed answer ONLY -- no explanation, no other text.

user: ```python
"""Module for generating names for Turing machine conditions"""

import itertools
import re
import string


class AlphabetError(Exception):
    """Base exception class for this module"""

    pass


class NotAllowedName(AlphabetError):
    """Raise this exception when the name is
    starting with numbers or special symbols,
    not with a latin letter"""

    def __init__(self, name):
        self.name = name
        super().__init__(self.__str__())

    def __str__(self):
        msg = "Disallowed name: {!r}"
        return msg.format(self.name)


class NameTemplate:
    """Class for generating new condition name based on
    a given symbol.

    Example:
        given 'q32' generated item will be q33
        given 'q' generated item will be q1
    """

    reg = re.compile(r'([a-zA-z]+)([0-9]*)')

    def __init__(self, name):
        match = re.match(self.reg, name)
        if match:
            count = match.group(2)
            self.counter = int(count) if count else 0
            self.letter = match.group(1)
        else:
            raise NotAllowedName(name)
        self.it = self.iterate()

    def __eq__(self, other):
        return all((
            self.counter == other.counter,
            self.letter == other.letter
            ))

    def __repr__(self):
        s = "NameTemplate(\nCounter: \n{}\nLetter: \n{}\n)"

        return s.format(self.counter, self.letter)

    __str__ = __repr__

    def iterate(self):
        while True:
            self.counter += 1
            yield self.letter + str(self.counter)

    def get_reserved(self):
        for i in range(self.counter + 1):
            yield self.letter + str(i)
        yield self.letter


class AlphabetGenerator:
    """Class for generating short, unique condition strings
    to work with in a TuringMachineMacro"""

    def __init__(self, alphabet=None, gen=None):
        if alphabet is None:
            self.alphabet = string.ascii_lowercase + string.digits
        else:
            self.alphabet = alphabet

        self.it = self._get_letter()

        self.templates = {}
        self.reserved = set()
        if gen is not None:
            self.set_template(gen)
        else:
            self.it = self._get_letter()

    def __eq__(self, other):
        return all((
            self.reserved == other.reserved,
            self.templates == other.templates,
            self.alphabet == other.alphabet
            ))

    def __repr__(self):
        s = "AlphabetGenerator(\nAlphabet: \n{}\nReserved: \n{}\nTemplates: \n{}\n)"
        return s.format(self.alphabet, self.reserved, self.templates)

    __str__ = __repr__

    def set_template(self, name):
        """Set a new template, or continue if
        it already exists"""

        temp = NameTemplate(name)
        name = temp.letter

        if name not in self.templates:
            self.templates[name] = temp

        self.it = self.templates[name].iterate()
        self.reserved.update(set(temp.get_reserved()))

    def del_template(self):
        """Set template to default generator"""

        self.it = self._get_letter()

    cur_template = property(None, set_template, del_template)

    def _get_letter(self):
        """Generate all possible products of all possible symbols,
        that doesn't start with a number
        """

        for i in range(1, len(self.alphabet)):  # error with the same names
            for elem in map(
                    lambda x: ''.join(x),
                    filter(
                        lambda x: x[0] not in string.digits,
                        itertools.product(self.alphabet, repeat=i)
                        )
                    ):
                    yield elem

    def pop(self):
        while True:
            res = next(self.it)
            if res not in self.reserved:
                self.reserved.add(res)
                return res

```

Candidate CWE catalog (every CWE that appears anywhere in this dataset):
  - CWE-20: Improper Input Validation
  - CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
  - CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')
  - CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
  - CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
  - CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')
  - CWE-94: Improper Control of Generation of Code ('Code Injection')
  - CWE-113: Improper Neutralization of CRLF Sequences in HTTP Headers ('HTTP Request/Response Splitting')
  - CWE-116: Improper Encoding or Escaping of Output
  - CWE-117: Improper Output Neutralization for Logs
  - CWE-200: Exposure of Sensitive Information to an Unauthorized Actor
  - CWE-209: Generation of Error Message Containing Sensitive Information
  - CWE-215: Insertion of Sensitive Information Into Debugging Code
  - CWE-295: Improper Certificate Validation
  - CWE-312: Cleartext Storage of Sensitive Information
  - CWE-326: Inadequate Encryption Strength
  - CWE-327: Use of a Broken or Risky Cryptographic Algorithm
  - CWE-377: Insecure Temporary File
  - CWE-502: Deserialization of Untrusted Data
  - CWE-601: URL Redirection to Untrusted Site ('Open Redirect')
  - CWE-611: Improper Restriction of XML External Entity Reference
  - CWE-614: Sensitive Cookie in HTTPS Session Without 'Secure' Attribute
  - CWE-643: Improper Neutralization of Data within XPath Expressions ('XPath Injection')
  - CWE-730: OWASP Top Ten 2004 Category A9 - Denial of Service
  - CWE-732: Incorrect Permission Assignment for Critical Resource
  - CWE-776: Improper Restriction of Recursive Entity References in DTDs ('XML Entity Expansion')
  - CWE-918: Server-Side Request Forgery (SSRF)
  - CWE-943: Improper Neutralization of Special Elements in Data Query Logic
  - CWE-1004: Sensitive Cookie Without 'HttpOnly' Flag
  - CWE-1333: Inefficient Regular Expression Complexity

List every distinct CWE from the catalog above that is actually present in this code.
Answer: CWE-20