def generate_frc(device_id):
    cookies = json.dumps({'ApplicationName': APP_NAME, 'ApplicationVersion': APP_VERSION, 'DeviceLanguage': 'en', 'DeviceName': DEVICE_NAME, 'DeviceOSVersion': OS_VERSION, 'IpAddress': requests.get('https://api.ipify.org').text, 'ScreenHeightPixels': '1920', 'ScreenWidthPixels': '1280', 'TimeZone': '00:00'})
    compressed = gzip.compress(cookies.encode())
    key = PBKDF2(device_id, b'AES/CBC/PKCS7Padding')
    iv = secrets.token_bytes(16)
    cipher = AES.new(key, AES.MODE_CBC, iv)
    ciphertext = cipher.encrypt(pkcs7_pad(compressed))
    hmac_ = hmac.new(PBKDF2(device_id, b'HmacSHA256'), (iv + ciphertext), hashlib.sha256).digest()
    return base64.b64encode((((b'\x00' + hmac_[:8]) + iv) + ciphertext)).decode()
def generate_frc(device_id):
    cookies = json.dumps({'ApplicationName': APP_NAME, 'ApplicationVersion': APP_VERSION, 'DeviceLanguage': 'en', 'DeviceName': DEVICE_NAME, 'DeviceOSVersion': OS_VERSION, 'IpAddress': requests.get('https://api.ipify.org').text, 'ScreenHeightPixels': '1920', 'ScreenWidthPixels': '1280', 'TimeZone': '00:00'})
    compressed = gzip.compress(cookies.encode())
    key = PBKDF2(device_id, b'AES/CBC/PKCS7Padding')
    iv = secrets.token_bytes(16)
    cipher = AES.new(key, AES.MODE_CBC, iv)
    ciphertext = cipher.encrypt(pkcs7_pad(compressed))
    hmac_ = hmac.new(PBKDF2(device_id, b'HmacSHA256'), (iv + ciphertext), hashlib.sha256).digest()
    return base64.b64encode((((b'\x00' + hmac_[:8]) + iv) + ciphertext)).decode()