How to get expiry date from cookies?

I am trying tp parse the cookies from a website set by the Set-Cookie header for their expiry period. I am using the requests library and this is how far I've progressed:

import requests

req = requests.get(url, headers=headers)
if req.cookies:
for cook in req.cookies:
if cook.expires: # checking the expires flag
print(‘Cookie Expiry Time: %s’ % (cook.expires))

However, cook.expires returns a value incomprehendible, something like 2181183994 and 1550035594. What needs to be done next to get the exact date time value from the expires flag?

#python

3 Likes1.85 GEEK