import hashlib

def i2osp(integer: int, size: int = 4) -> str:
    return b"".join([chr((integer >> (8 * i)) & 0xFF).encode() for i in reversed(range(size))])

def mgf1(input_str: bytes, length: int, hash_func=hashlib.sha1) -> str:
    counter = 0
    output = b""
    while len(output) < length:
        C = i2osp(counter, 4)
        output += hash_func(input_str + C).digest()
        counter += 1
    return output[:length]
37c005859704756937951bc70c2e2d4b5c38d44a
<mask token>

<mask token>


def mgf1(input_str: bytes, length: int, hash_func=hashlib.sha1) ->str:
    counter = 0
    output = b''
    while len(output) < length:
        C = i2osp(counter, 4)
        output += hash_func(input_str + C).digest()
        counter += 1
    return output[:length]

<mask token>


def i2osp(integer: int, size: int=4) ->str:
    return b''.join([chr(integer >> 8 * i & 255).encode() for i in reversed
        (range(size))])


def mgf1(input_str: bytes, length: int, hash_func=hashlib.sha1) ->str:
    counter = 0
    output = b''
    while len(output) < length:
        C = i2osp(counter, 4)
        output += hash_func(input_str + C).digest()
        counter += 1
    return output[:length]

import hashlib


def i2osp(integer: int, size: int=4) ->str:
    return b''.join([chr(integer >> 8 * i & 255).encode() for i in reversed
        (range(size))])


def mgf1(input_str: bytes, length: int, hash_func=hashlib.sha1) ->str:
    counter = 0
    output = b''
    while len(output) < length:
        C = i2osp(counter, 4)
        output += hash_func(input_str + C).digest()
        counter += 1
    return output[:length]

import hashlib

def i2osp(integer: int, size: int = 4) -> str:
    return b"".join([chr((integer >> (8 * i)) & 0xFF).encode() for i in reversed(range(size))])

def mgf1(input_str: bytes, length: int, hash_func=hashlib.sha1) -> str:
    counter = 0
    output = b""
    while len(output) < length:
        C = i2osp(counter, 4)
        output += hash_func(input_str + C).digest()
        counter += 1
    return output[:length]