19.01.2023, 08:46
Try this:
Using script that simulates user interaction with a login page is not a stable solution. The page format and parameters can change at any time and the script will stop working.
Code:
cookies = '...'
cookies = cookies:gsub('Expires=%w+, ', 'Expires=')
cookies = cookies:split(', ')
for i, cookie in ipairs(cookies) do
cookies[i] = cookie:split(';')[1]
end
cookies = table.concat(cookies, '; ')
Using script that simulates user interaction with a login page is not a stable solution. The page format and parameters can change at any time and the script will stop working.