def read_null_terminated_string(data: bytes, offset: int, encoding: str = 'ascii') -> str:
    """
    Returns a null terminated string starting from the given offset
    into the given data.

    :param data: a continous sequence of bytes
    :param offset: offset to start looking
    :param encoding: an encoding to interpret the string

    :return: the found string
    """
    start = offset
    current = offset
    while data[current] != 0:
        current += 1

    return data[start:current].decode(encoding)